SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Sep 2002
    Posts
    71
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    reload the page with a different variable

    hi there,

    I have a website where results for pictures are displayed (split) into several pages (just like u see on site point [previous page] 1 2 3 [next page])
    now what i am trying to do is have a box just like site point where u can enter the page number and jump to it. and I noticed that most sites use javascript to do that (just like sitepoint)
    here is my url
    http://mysite.com/Display.php?ID=59&page=2

    Now i want to be able to reload the page by entering a number is a textbox and then hit ok to go to that page (example page 4)

    how do we do that since i have no experience in javascript

  2. #2
    SitePoint Addict jtrelfa's Avatar
    Join Date
    Oct 2004
    Location
    Troy, Mi
    Posts
    231
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the javascript command is:
    Code:
    document.location.href = "url?var=1&var2=blah...";
    if you're in a frameset and want to change the whole page, substitute "document" with "top".


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •