Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

history.go('url')

Status
Not open for further replies.

azatiko

IS-IT--Management
Apr 11, 2007
2
CA
Hello,

i use <a href="javascript:history.go('test.php')">.
test.php has paging numbers, someone knows how to history back to the exact paging number of test.php?
this code only brings me 1 page of test.php even i want to history.back 7 page of test.php.

Please help me
 
someone knows how to history back to the exact paging number of test.php?
Yes, pass the exact URL of the page you are after to the history.go method.

Never be afraid to share your dreams with the world.
There's nothing the world loves more than the taste of really sweet dreams.

Enable Apps
 
The exact url is the test.php because we are using post values for paging.
 
I'm pretty sure I understand this correctly, I believe you would have to use the php command

$_PAGING->set_custom_url

to make distinct urls for each "page" of test.php. I think the php forum is the best place for this question (question being how can I assign a unique URL for each page in a php file that uses paging).

clip of what I found:
Code:
    // Is used to set a custom URL. Should be used in combination with mod_rewrite. 
    // Please note that you must use {var:page} and {var:perpage} in the URL 
    // for it to work correctly 
    $_PAGING->set_custom_url ('[paging-name]', '[URL unfurl="true"]http://www.example.com/articles/{var:page}/{var:perpage}/');[/URL]

[monkey][snake] <.
 
Wait wait, I take all that back, your url should have a query string appended onto the end of it which has the page number on it.

Code:
test.php[!]?page=7[/!]

Type all that in your history.go() method.

[monkey][snake] <.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top