Assuming my PHP page does ‘REAL’ actions.
By ‘REAL’ I mean, executing DB actions, writing files, stuff like that, as opposed to just sending HTML.
When I hit the ‘Back’ button to my PHP page, Assuming it is a GET.
-
Does it mean my PHP code will not necessarily run all the time, on all browsers ?
-
If I have an image I would like to refresh every time I ask for that page (especially on ‘Back’), how should I go about that?
Is it just me or having an internal dislike for javascript is normal ? (It always seems to me like a patch for things that couldn’t work in the first place, plus not everyone let javascript work)
I am not picky but is it ok to think that a HTTP level solution would be the best here ?
Thanks
Pages that are loaded via POST will cause the browser to ask the user to resubmit the information to view the page resulting in the actions performed by that page happening again. If the pages is requested via GET and has variables in the querystring the same thing happens but silently (without the user being prompted to d it again).
The best to work around this is to use the POST/REDIRECT/GET pattern. I used it in an example about processing payments that I wrote for Authorize.Net. Hopefully that points you in the right direction.