Qbasicnews.com

Full Version: PHP file permission question
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Yes...I don't think they get very big in GIF form, though.
And one thing, Oracle: How do I check if the GD library is installed? Or can I install it on my webserver?
Dynamic images shouldn't be cached, but IE6 caches them.

Call phpinfo() to check if the gd extension is installed.
Quote:GD Support enabled
GD Version bundled (2.0.15 compatible)
FreeType Support enabled
FreeType Linkage with freetype
GIF Read Support enabled
JPG Support enabled
PNG Support enabled
WBMP Support enabled
XBM Support enabled
That's what it says about gd in the phpinfo() function..that sound right?
Yep.
Er...problem.
With this code:
Code:
<?
Header("Content-Type: image/gif");
$im = ImageCreate(500, 75);
$red = ImageColorAllocate($im, 255, 0, 0);
ImageFill($im, 100, 100, $red);
ImageGIF($im);
?>
I get an error:Fatal error: Call to undefined function: imagegif() in /home/virtual/site171/fst/var/www/html/img.php on line 6.
What's wrong? Apparently, according to the tut I'm reading, I should see a red rectangle...
Oh whoops, I just noticed...lol dumb me Big Grin

GIF is disabled in your PHP version due to Unisys's stranglation license. Use PNG instead. Smile
Won't that be...a lot bigger? And will it be compatible with all OSes and browsers?
GIF uses LZW compression...PNG uses LZ77. LZ77 is vastly better, LZW is simply faster. And it depends on whether or not you're using 24 bit images, images with a lot of color coherance, etc etc etc many variables involved. And PNG is specifically designed for networks, hence the name Portable Network Graphics...any browser in this day and age that doesn't have at least basic PNG support is not even worth caring about.
Excellent. Muchos Thanksos :rotfl: (my sister insisted that I include that icon in this message Tongue )
Quote:...any browser in this day and age that doesn't have at least basic PNG support is not even worth caring about.

Like IE6? :rotfl:

(well, it can't handle transparency, that's important...)

Better to make either png's or jpegs...
Pages: 1 2 3