在浏览器的后单击上,转到主页 [英] On back click of browser, go to home page
本文介绍了在浏览器的后单击上,转到主页的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,
我想将用户重定向到主页,一旦他们到达浏览器上的单击确认页面,我该怎么办?
这样做的网站太多了,所以这应该是不可能的.
请帮帮我.
在此先感谢!
Hi All,
I want to redirect the user to home page once they have reached confirmation page on browser back click, how can I do it?
There are so many sites doing that, so it shouldn''t be impossible.
Please help me.
Thanks in advance!
推荐答案
^ ]是StackOverflow中询问的类似问题,答案看起来像它应该为您工作.要点是,在确认页面上设置一个标志,并在前面的页面中检查该标志;如果设置了该标志,则将用户重定向到首页使用header(''Location:...'');.
This[^] is similar question asked in StackOverflow and the answer looks like it should work for you. The gist of that is, set a flag on confirmation page and check for that flag in the previous pages; If that flag is set, redirect the user to home "using header(''Location: ...'');".
这篇关于在浏览器的后单击上,转到主页的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文