Created
February 15, 2013 01:04
-
-
Save bryhal/4957856 to your computer and use it in GitHub Desktop.
Workaround for file_exist() on remote server when checking if an image exists
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function image_exists($uid) { | |
$url= getimagesize('http://269.354.158.245/images/someimage.jpg'); | |
if (is_array($url)) { | |
$path = 'http://269.354.158.245/images/someimage.jpg'; | |
} else { | |
return FALSE; | |
} | |
return $path; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment