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.

Link to comment
Share on other sites

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

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.