Results 1 to 4 of 4

Thread: Unable to resolve the problem of javascript:history.back()

  1. #1
    Join Date
    Oct 2008
    Posts
    115

    Unable to resolve the problem of javascript:history.back()

    I am having trouble with using the history command javascript:history.back() in frames. does anyone have any suggestions for how to fix this? Is there any difference between javascript: history.back() and history.go(-1). The button uses javascript:history.back() to go back to the previous page. The link opens a website in a new window. The button when clicked takes me back to the original page and the DTA entered is intact.

  2. #2
    Join Date
    Oct 2008
    Posts
    129

    Re: Unable to resolve the problem of javascript:history.back()

    I had a similar problem using frames in Netscape 6, so posted here and was given two alternatives to try. Both worked..here they are give them a try, No difference: history.back(), history.back(1) and history.go(-1) brings the same result. Declaring a javascript function in the HTML makes no difference. In HTML/PHP all works fine...

    Hope it helps.

    <FORM><INPUT type=button value=" Back " onClick="history.back();"> /FORM>

    <FORM><INPUT type=button value=" Back " onClick="parent.history.back(); return false;"></FORM>

  3. #3
    Join Date
    Oct 2008
    Posts
    55

    Re: Unable to resolve the problem of javascript:history.back()

    In both cases (back or forward), a history must exist. You can also enter a url instead of a relative history number. To clarify, what happens is that when you have a button in your flash that calls getURL("javascript:history.back();") or getURL("javascript:history.go(-1);"), you have to click the button twice in IE for it to work. As far as I'm aware, history.back() doesn't use a numbering systems to navigate with. It simply keeps going back through the browsers history, like a browsers <- back button. I think you should use this in your page,
    Code:
     <a href="javascript: window.history.go(-2)">Go Back 2 pages</a>

  4. #4
    Join Date
    Feb 2006
    Posts
    126

    Re: Unable to resolve the problem of javascript:history.back()

    The second thing he's referring to is someone's suggestion that you call something like getURL("javascript:historyBack();") and then define a historyBack() function in the HTML that calls history.back(). This also does not solve the problem.I don't know why but I can never remember the exact syntax of this command, though I do use it fairly often.

Similar Threads

  1. Unable to resolve hostname via ssh
    By Hipolit in forum Networking & Security
    Replies: 2
    Last Post: 10-09-2011, 10:37 PM
  2. History Object In JavaScript
    By ramsun in forum Software Development
    Replies: 5
    Last Post: 29-01-2010, 10:17 AM
  3. javascript history back - Make it go previous page
    By Orton in forum Software Development
    Replies: 3
    Last Post: 14-04-2009, 12:09 PM
  4. javascript "innerHTML" cannot resolve
    By Pikachoo in forum Software Development
    Replies: 3
    Last Post: 05-03-2009, 10:06 AM
  5. DNS unable to resolve IP address, help
    By Donald in forum Networking & Security
    Replies: 4
    Last Post: 30-09-2008, 05:52 PM

Tags for this Thread

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
  •  
Page generated in 1,713,568,682.46801 seconds with 17 queries