IIS7 and getimagesize() problem

Posted on 16th Feb 2014 by admin

I have just discovered after hrs of trying to fix a problem where it's coming from. It's to do with the php function getimagesize() and path names.

When using these two different sets of code:

Code: <?php
list($width, $height, $type, $attr) = getimagesize("store_closed.gif");
echo "<img src="store_closed.gif" $attr alt="getimagesize() example" />";
?>

Code: <?php
list($width,$height,$type,$attr)=getimagesize("C:inetpubwwwroothifisquad.comstore_closed.gif");
echo $width;
echo $height;
echo $type;
echo $attr;
?>
However when I try and use this function with a path like this: http://www.myname.com/store_closed.gif
the page errors.

I'm running this system on a Win2008 IIS7 server, is there a setting to enable the above style of path or am I missing something else?

Other forums