Suppose i have a website of 10 pages..I am moving from one page to another in more than 2 to 3 pages.. How can i keep track so that when it comes to 2nd page which i have navigated,it will will go to first page. my logic is working for 3 pages i am sending first page info to second page and first and second page info to 3rd page..so that when it redirects from i check whether it has subsequent more than one page and redirects to first page from second page..this logic fails if i am navigating to 4 pages as this time i will have to keep track of more than 1 or 2 pages which is not sufficient way please help
Asked
Active
Viewed 32 times
0
-
Huh? I'm not clear what you are trying to do. Can you provide some code please, either code behind of JS? – Dean.DePue May 21 '14 at 11:45
-
i can start from any page in website and can move to many pages one by one .Any page can be called from any other page..i need keep track so that when i hit back button of application it should go to proper page – Mayur May 21 '14 at 11:49
-
Have a look at this: http://stackoverflow.com/questions/10413530/how-to-control-the-browser-buttons-using-java-script – Dean.DePue May 21 '14 at 11:52
-
But you want to control where the back button takes the user?? It is appropriate... – Dean.DePue May 21 '14 at 11:59
-
suppose i move from 2nd to 3rd page initially...when i navigate from 3rd page to 4th page after hitting back button of website it will go to 3rd page..from 3rd page when i hit back button where it will go to 2nd page or 4th page..i want to go on 2nd page – Mayur May 21 '14 at 12:07
-
That is as clear as mud. If the user goes page1 -> page2 -> page3 -> page4 then clicks back they will go page4 -> page 3 then back page3 -> page2 then back page2 -> page1. I don't understand the problem. – Dean.DePue May 21 '14 at 12:13