Fix failed MNGs imagesize detection (existing basename-matching GIF expected)
authorshort <>
Sun, 21 Apr 2002 00:54:49 +0000 (00:54 +0000)
committershort <>
Sun, 21 Apr 2002 00:54:49 +0000 (00:54 +0000)
common.php

index 3691b89..7644141 100644 (file)
@@ -182,7 +182,7 @@ function img_size($width,$height)
 
 function img($file,$alt,$attrs="")
 {
-       list($width,$height)=getimagesize($file);
+       list($width,$height)=getimagesize(ereg_replace("\\.mng",".gif",$file));
        $alt=htmlspecialchars($alt);
        return("<img src=\"$file\" alt=\"$alt\" title=\"$alt\" ".img_size($width,$height)
                        .($attrs=="" ? "" : " ".$attrs)." />");