lundi 19 décembre 2016

change server value in http get request for one-time show infomation

I need to display some information to logged in users on a website for one time.

To do that, I store a flag in DB. When servicing the get request, I'll show the information if the flag is set, and then clear the flag.

But I was told that get request should be idempotent. Another option I can figure out to do this is send a ajax call to clear the flag after the get request.

My question is which is preferred and why.




Aucun commentaire:

Enregistrer un commentaire