Robert Sossomon wrote:
> Chris is quoted as saying on 11/30/2004 2:53 PM:
>> imagesx() requires an image resource , not a file path. so you'd need
>> to use one of the imagecreatefrom* functions to create the resource.
>>
>> But it looks like all you want is the width and height of an image
>
Chris is quoted as saying on 11/30/2004 2:53 PM:
imagesx() requires an image resource , not a file path. so you'd need
to use one of the imagecreatefrom* functions to create the resource.
But it looks like all you want is the width and height of an image
If so use get imagesize() ( which *
Robert Sossomon wrote:
When I run it in the browser, I get:
Fatal error: Call to undefined function: imagesx() in
c:\fourh\spotlight3.php on line 31
when i run it from the command line I get:
C:\fourh>php.exe spotlight3.php
Content-type: text/html
X-Powered-By: PHP/4.3.9
Warning: imagesx(): su
imagesx() requires an image resource , not a file path. so you'd need
to use one of the imagecreatefrom* functions to create the resource.
But it looks like all you want is the width and height of an image
If so use get imagesize() ( which *does* except a pathname, not a resource)
Chris
h
On Tue, 30 Nov 2004 14:43:51 -0500, Robert Sossomon <[EMAIL PROTECTED]> wrote:
> Fatal error: Call to undefined function: imagesx() in c:\fourh\spotlight3.php
> on
> line 31
Do print_r( gd_info() ); to see if your PHP has support for working with images.
--
Greg Donald
Zend Certified Engineer
John Nichel is quoted as saying on 11/30/2004 2:17 PM:
$width = imagesx($path)/4;
$height = imagesy($path)/4;
$width = imagesx($path)/4;
$height = imagesy($path)/4;
When I run it in the browser, I get:
Fatal error: Call to undefined function: imagesx() in c:\fourh\spotlight3.php on
line 31
when
Robert Sossomon wrote:
> // this is the path of your files folder. Change 'pathofile'
> $dir = "images/";
I would make this the path from root, ie...
$dir = "/root/path/images/";
// takes the objects in the array and randomizes them
$arrayobj = array_rand($array);
$random = $array[$arrayobj];
//
Here's the code for the page...
while ($file = readdir($handle))
{
for ($i = 0; $i < count($extensoes); $i++)
{
if (eregi("\.". $extensoes[$i] ."$", $file))
{
$array[] = $file;
}
}
}
closedir($handle);
sort($array);
reset($array);
// takes the objects in the array and randomizes them
$
8 matches
Mail list logo