I have a php script (file.php) that is used to counts banner impressions and returns an image, it end like this:
readfile('http://somedomain.com/banner.jpg');
mysql_close();
exit;
This file is used very much, and sometimes when the image is hosted on external server it load slow.
So to reduce my hosting usage i think to add a max execution time only on this script, for example: if 5-10 seconds are passed, the script closes
i think that is possibile, but how?