读书人

PHP检查文件是否在不同域名上的存在情

发布时间: 2012-09-19 13:43:54 作者: rapoo

PHP检查文件是否在不同域名下的存在情况

Earlier today I needed to find out if a file exists on a different domain. Initially I used the file_exists function, but then when that threw back an error I remembered that file_exists only checks whether a file or directory exists on the same server as the script.

After I played around with various functions, I came up with a few lines of code that actually works:

How to check if file exists on a different domain

?

?

读书人网 >PHP

热点推荐