Well, I tryed to include this code, but I was unsuggessful.
Here is the basic script:
#!/usr/bin/perl
use Image::Size;
print "Content-type: text/html\n\r\n\r";
# Get the size of globe.gif
($globe_x, $globe_y) = imgsize("test.gif");
# Assume X=60 and Y=40 for remaining examples
print "X: $globe_x, Y: $globe_y";
use Image::Size;
# Get the size of globe.gif
($globe_x, $globe_y) = imgsize("test.gif");
# Assume X=60 and Y=40 for remaining examples
print "X: $globe_x, Y: $globe_y";
use Image::Size 'html_imgsize';
# Get the size as 'width="X" height="Y"' for HTML generation
$size = html_imgsize("test.gif");
# $size == 'width="60" height="40"'
print "$size";
use Image::Size 'attr_imgsize';
# Get the size as a list passable to routines in CGI.pm
@attrs = attr_imgsize("test.gif");
# @attrs == ('-width', 60, '-height', 40)
use Image::Size;
# Get the size of an in-memory buffer
($buf_x, $buf_y) = imgsize($buf);
print "X: $buf_x, Y: $buf_y";
exit;
Any idea why this shouldn't work???
----- Original Message -----
From: "fliptop" <[EMAIL PROTECTED]>
To: "Webmaster" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, February 13, 2002 10:26 PM
Subject: Re: Image size
> Webmaster wrote:
>
> > I'll looking for a way to get the image size (jpg or gif). I had a look
around and found some information on it. However, none of these page provide
an example well enough to get an idea how to use it.
>
>
> http://search.cpan.org/search?dist=Image-Size
>
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>