Jump to content

[SOLVED] History Header


Hagbard

Recommended Posts

is there any way in the header file to have the page go back two pages

 

header ("location: index.php");  - will take you back to index and I know if I make an input button it can go back a page

 

<input type=button value=\"Go Back to List\" onClick=\"history.go(-1)\"> | ";

 

but is there any way to combine the two so that it will automatically go back a page?

Link to comment
https://forums.phpfreaks.com/topic/102728-solved-history-header/
Share on other sites

I do have a sessions script already running. However if that came to it I could just create a separate process page for each and point it to the page I'm looking for.

 

I have

 

post 1

post 2

post 3

post 4

 

I could just create a process page for each one that points to its respected page.

<body onload="javascript: history.go(-2)">

 

That'll send them back two pages in their history, which might not be too reliable (they may have visited other pages in between)...You should store the page before the page in a session variable and redirect them like that.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.