the "history.back" function

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Food Groupy

    the "history.back" function

    Hi...

    I use a function something like this,

    <a href="javascrip t:history.back( );">Return to original page</a>

    to give people a "back" option sometimes on pages.

    Is there any way of directing them back to a particular named anchor on the
    last page?


    thanks for any advice...

    GB


  • Randy Webb

    #2
    Re: the &quot;history.b ack&quot; function

    Food Groupy wrote:
    [color=blue]
    > Hi...
    >
    > I use a function something like this,
    >
    > <a href="javascrip t:history.back( );">Return to original page</a>[/color]


    [color=blue]
    > to give people a "back" option sometimes on pages.[/color]

    They already have one, conveniently built into the browser, and it
    doesn't suffer from the problem you are asking about next.
    [color=blue]
    > Is there any way of directing them back to a particular named anchor on the
    > last page?[/color]

    How are you even sure that anchor exists in the last page? And, if I
    bookmark the page, reboot, reopen the page with the bookmark, how does
    the .back() work? It doesn't......



    --
    Randy
    Chance Favors The Prepared Mind
    comp.lang.javas cript FAQ - http://jibbering.com/faq/

    Comment

    • Food Groupy

      #3
      Re: the &quot;history.b ack&quot; function

      [color=blue][color=green]
      > > to give people a "back" option sometimes on pages.[/color]
      >
      > They already have one, conveniently built into the browser, and it
      > doesn't suffer from the problem you are asking about next.[/color]

      I understand this about the "back" function being built into the browser.
      My particular example is for a customer who has completed a long form as
      part of a registration process, presses "submit", goes to a payment options
      page where his chosen registration option is displayed. If he discovers he
      has chosen the wrong option, I wanted a "customized " BACK script that would
      take him directly to the specified <SELECT> option, instead of having them
      laboriously scrolling around to find it.

      It was for the customer's convenience.
      My, how we jump to conclusions.
      My, how we love to preach.

      [color=blue]
      >[color=green]
      > > Is there any way of directing them back to a particular named anchor on[/color][/color]
      the[color=blue][color=green]
      > > last page?[/color]
      >
      > How are you even sure that anchor exists in the last page? And, if I
      > bookmark the page, reboot, reopen the page with the bookmark, how does
      > the .back() work? It doesn't......[/color]

      I think my above detail explains that "yes", there is an anchor on the page.
      I suppose I could devise some kind of cookie script that would do the trick.



      Comment

      • Randy Webb

        #4
        Re: the &quot;history.b ack&quot; function

        Food Groupy wrote:[color=blue][color=green][color=darkred]
        >>>to give people a "back" option sometimes on pages.[/color]
        >>
        >>They already have one, conveniently built into the browser, and it
        >>doesn't suffer from the problem you are asking about next.[/color]
        >
        >
        > I understand this about the "back" function being built into the browser.
        > My particular example is for a customer who has completed a long form as
        > part of a registration process, presses "submit", goes to a payment options
        > page where his chosen registration option is displayed. If he discovers he
        > has chosen the wrong option, I wanted a "customized " BACK script that would
        > take him directly to the specified <SELECT> option, instead of having them
        > laboriously scrolling around to find it.[/color]

        Page1 checks for the cookie, if its there, it sets focus on the select
        and then it removes it.
        Page2 sets the cookie, and then does the .back()

        A better solution would be to have the payment method on the second page
        though.
        [color=blue]
        > It was for the customer's convenience.
        > My, how we jump to conclusions.[/color]

        You should read the FAQ, with regards to basic assumptions in this group.
        [color=blue]
        > My, how we love to preach.
        >[/color]

        My, how we love to leave out details that make a difference in the
        possible answer you might recieve.
        [color=blue]
        >[color=green][color=darkred]
        >>>Is there any way of directing them back to a particular named anchor on[/color][/color]
        >
        > the
        >[color=green][color=darkred]
        >>>last page?[/color]
        >>
        >>How are you even sure that anchor exists in the last page? And, if I
        >>bookmark the page, reboot, reopen the page with the bookmark, how does
        >>the .back() work? It doesn't......[/color]
        >
        >
        > I think my above detail explains that "yes", there is an anchor on the page.[/color]

        A <SELECT> isn't an anchor. They are two different things.
        [color=blue]
        > I suppose I could devise some kind of cookie script that would do the trick.[/color]

        See above, and kill the sarcasm, it can go on for weeks and serves no
        purpose.


        --
        Randy
        Chance Favors The Prepared Mind
        comp.lang.javas cript FAQ - http://jibbering.com/faq/

        Comment

        • Food Groupy

          #5
          Re: the &quot;history.b ack&quot; function

          Randy, an honorable 'thank you' for your assistance...

          (my how we love to jump to conclusions about other people jumping to
          conclusions.... )


          "Randy Webb" <hikksnotathome @aol.com> wrote in message
          news:lNSdnXizF4 Mos17d4p2dnA@co mcast.com...[color=blue]
          > Food Groupy wrote:[color=green][color=darkred]
          > >>>to give people a "back" option sometimes on pages.
          > >>
          > >>They already have one, conveniently built into the browser, and it
          > >>doesn't suffer from the problem you are asking about next.[/color]
          > >
          > >
          > > I understand this about the "back" function being built into the[/color][/color]
          browser.[color=blue][color=green]
          > > My particular example is for a customer who has completed a long form as
          > > part of a registration process, presses "submit", goes to a payment[/color][/color]
          options[color=blue][color=green]
          > > page where his chosen registration option is displayed. If he discovers[/color][/color]
          he[color=blue][color=green]
          > > has chosen the wrong option, I wanted a "customized " BACK script that[/color][/color]
          would[color=blue][color=green]
          > > take him directly to the specified <SELECT> option, instead of having[/color][/color]
          them[color=blue][color=green]
          > > laboriously scrolling around to find it.[/color]
          >
          > Page1 checks for the cookie, if its there, it sets focus on the select
          > and then it removes it.
          > Page2 sets the cookie, and then does the .back()
          >
          > A better solution would be to have the payment method on the second page
          > though.
          >[color=green]
          > > It was for the customer's convenience.
          > > My, how we jump to conclusions.[/color]
          >
          > You should read the FAQ, with regards to basic assumptions in this group.
          >[color=green]
          > > My, how we love to preach.
          > >[/color]
          >
          > My, how we love to leave out details that make a difference in the
          > possible answer you might recieve.
          >[color=green]
          > >[color=darkred]
          > >>>Is there any way of directing them back to a particular named anchor on[/color]
          > >
          > > the
          > >[color=darkred]
          > >>>last page?
          > >>
          > >>How are you even sure that anchor exists in the last page? And, if I
          > >>bookmark the page, reboot, reopen the page with the bookmark, how does
          > >>the .back() work? It doesn't......[/color]
          > >
          > >
          > > I think my above detail explains that "yes", there is an anchor on the[/color][/color]
          page.[color=blue]
          >
          > A <SELECT> isn't an anchor. They are two different things.
          >[color=green]
          > > I suppose I could devise some kind of cookie script that would do the[/color][/color]
          trick.[color=blue]
          >
          > See above, and kill the sarcasm, it can go on for weeks and serves no
          > purpose.
          >
          >
          > --
          > Randy
          > Chance Favors The Prepared Mind
          > comp.lang.javas cript FAQ - http://jibbering.com/faq/[/color]


          Comment

          Working...