Jump to content

not cache imagepng() ?


leeming

Recommended Posts

Are you using imagepng($im, $filename) to write the the image to a file then displaying the resultant file

<img src='filename.png'>

or are you displaying the dynamic image

<img src='myimage.php'>

I was under the impression that if it's the latter it cannot be cached as the image file doesn't exist until it is created on-the-fly.
Link to comment
https://forums.phpfreaks.com/topic/24554-not-cache-imagepng/#findComment-112022
Share on other sites

[quote author=Barand link=topic=112131.msg455136#msg455136 date=1161372394]
Are you using imagepng($im, $filename) to write the the image to a file then displaying the resultant file

<img src='filename.png'>

or are you displaying the dynamic image

<img src='myimage.php'>

I was under the impression that if it's the latter it cannot be cached as the image file doesn't exist until it is created on-the-fly.
[/quote]
its shown as a .png, because it saves load time every time a page is viewed... and the picture is only updated as updates happen
Link to comment
https://forums.phpfreaks.com/topic/24554-not-cache-imagepng/#findComment-112548
Share on other sites

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.