Jump to content

GetimageSize function doesn't work with url imagefile ending on .jpg&size=40x30


vanleurth

Recommended Posts

Hello happy codes,

 

I have an image as such;

http://storage.canoe.ca/v1/dynamic_resize/?src=http://www.torontosun.com/specialsections/2011/03/10/248x186_mb.jpg&size=40x30

 

getimagesize doesn't work with this image.

 

Any ideas or links? I have looked through this site and can't find anyone having this problem. Am I missing something?

 

Thank you,

 

V.

Works fine for me:

<?php
$x = 'http://storage.canoe.ca/v1/dynamic_resize/?src=http://www.torontosun.com/specialsections/2011/03/10/248x186_mb.jpg&size=40x30';
$i = getimagesize($x);
echo '<pre>' . print_r($i,true) . '</pre>';
?>

yeilds:

Array
(
    [0] => 40
    [1] => 30
    [2] => 2
    [3] => width="40" height="30"
    [bits] => 8
    [channels] => 3
    [mime] => image/jpeg
)

 

Why do you say it doesn't work?

 

Ken

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.