Tuesday, September 30, 2008

Re: page refresh?

just implmemented it works. lol
cool :) i ended up doing a md5 on time() :)

On Sep 30, 11:30 am, rocket <justin...@gmail.com> wrote:
> interesting fix. thanks
>
> On Sep 29, 5:15 pm, "3lancer.eu" <kilc...@gmail.com> wrote:
>
> > Hi,
>
> > > but when you change the picture, the old picture is still stuck in the
> > > cache, so to see the new pic the user needs to push F5... I can't
> > > figure out how to "refresh" the page automatically.
>
> > > any ideas?
>
> > Simplest way is to add some random query string at the end of the url,
> > likehttp://example.com/images/some_profile_image.jpg?andThisIsSomeHash
>
> > It would be good to utilize the browser cache the proper way, so you
> > can try to set 'andThisIsSomeHash' to something like
> > md5($myModel['MyModel']['modified']) or md5(filemtime('images/
> > some_profile_image.jpg'));
>
> > Regards,
> > Piotr
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: