Post data and refresh page

前端 未结 4 1811
深忆病人
深忆病人 2020-12-29 17:20

I have an edit-form page to edit my website posts. It uses post method to the same page. If the form is compiled correctly shows up a congrats message.

The p

4条回答
  •  轮回少年
    2020-12-29 17:42

    You should use the PRG pattern already mentioned above! Just for completeness I add the possibility of using javascript history.replaceState if your forms depend on js (e.g. noscript should invalidate the form or something similar...).

    
    

提交回复
热议问题