Authored by 郝肖肖

防止多次调用getImageUrl

... ... @@ -66,6 +66,11 @@ class Images
*/
public static function getImageUrl($fileName, $width, $height, $mode = 2, $bucket = 'goodsimg')
{
if (substr($fileName, 0, 2) === '//') {
//防止多次调用getImageUrl
$fileName = 'http:' . $fileName;
}
if (!is_string($fileName)) {
return self::template(self::$default_image, $bucket, $mode);
}
... ...