Jump to content

Retain vertical scroll when going back to search results


htcilt

Recommended Posts

I have a form that when submitted displays the results in rows (search.php)

Each row has a link to more information (detail.php).

 

I have the parameters in a session so that I can get back to search.php from detail.php with parameter, pagination etc intact.

 

However, I need to find a way to put the scroll back to here it was when the user clicked on the 1st link (in detail.php).

The reason for this is they may loose where they were when scrolling through the results.

 

I know the scroll position can be accessed/set with jquery, but I'm not sure passing client information to php is possible.  The scroll position needs to be retrieved when the user clicks on the link to detail.php and ideally put into the session, but I'm not sure how?

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.