Reply to Re: [PHP] Image Verification - Problems in Safari, Mac OS X

Your name:

Reply:


Posted by Marek Kilimajer on 05/21/05 00:39

Rahul S. Johari wrote:
> Ave,
>
> On 5/19/05 5:41 PM, "Marek Kilimajer" <lists@kilimajer.net> wrote:
>
>
>>If more then one user is accesing the page, you might overwrite the
>>first one's verify.png image. Simple and sufficient solution is to
>>append a random string to the filename:
>>
>>$image_filename= 'verify_' . md5(rand()) . '.png';
>>ImagePNG($im, $image_filename);
>>?>
>><img src="<?php echo $image_filename; ?>" width="200" height="40">
>><?php
>>
>>Just remember to add some way to remove old images.
>
>
> Solutions works for me too... Gets rid of the multi-user problem. Thanks for
> pointing it out and suggesting the solution.
>
> The other Cache problem still persists. Don't know what to do about it. Is
> just not working out in IE.

The above code should also fix cache problems. The image name will be
different each reload.

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация