Update location.hash without adding to history?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Mikey C

    Update location.hash without adding to history?

    Hi Everyone,

    I understand in many cases, adding to history when updating
    window.location .hash is a GOOD thing. In my case, I want to update
    bookmarkability from javascript (post-load), but can't get it to do so
    without adding a record to history. (Firefox 3.0.3)

    I know it's possible to do, because Google is doing it. See this
    URL:
    The most successful business book of the last decade, Reengineering the Corporation is the pioneering work on the most important topic in business today: achieving dramatic performance improvements. This book leads readers through the radical redesign of a company's processes, organization, and culture to achieve a quantum leap in performance.Michael Hammer and James Champy have updated and revised their milestone work for the New Economy they helped to create -- promising to help corporations save hundreds of millions of dollars more, raise their customer satisfaction still higher, and grow ever more nimble in the years to come.


    Note, scrolling up and down changes the hash without adding history
    entries.

    Any idea how this is done? I have been looking for a solution for
    months (on and off, but haven't found anything.)

    Thanks,
    -MIke C
  • David Mark

    #2
    Re: Update location.hash without adding to history?

    On Nov 20, 9:48 pm, Mikey C <mebemik...@gma il.comwrote:
    Hi Everyone,
    >
    I understand in many cases, adding to history when updating
    window.location .hash is a GOOD thing.  In my case, I want to update
    bookmarkability from javascript (post-load), but can't get it to do so
    without adding a record to history.  (Firefox 3.0.3)
    That would be a silly thing to do.
    >
    I know it's possible to do, because Google is doing it.  See this
    There is confirmation.
    URL:http://books.google.com/books?hl=en&...&oi=fnd&pg=PP1...
    >
    Note, scrolling up and down changes the hash without adding history
    entries.
    That is not what the hash is for and there is little chance that
    Google is doing anything right in their script.
    >
    Any idea how this is done?  I have been looking for a solution for
    months (on and off, but haven't found anything.)
    >
    You wasted those months. Now re-think your design.

    Comment

    • Thomas 'PointedEars' Lahn

      #3
      Re: Update location.hash without adding to history?

      Mikey C wrote:
      I understand in many cases, adding to history when updating
      window.location .hash is a GOOD thing. In my case, I want to update
      bookmarkability from javascript (post-load), but can't get it to do so
      without adding a record to history. (Firefox 3.0.3)
      >
      I know it's possible to do, because Google is doing it. See this
      URL:
      The most successful business book of the last decade, Reengineering the Corporation is the pioneering work on the most important topic in business today: achieving dramatic performance improvements. This book leads readers through the radical redesign of a company's processes, organization, and culture to achieve a quantum leap in performance.Michael Hammer and James Champy have updated and revised their milestone work for the New Economy they helped to create -- promising to help corporations save hundreds of millions of dollars more, raise their customer satisfaction still higher, and grow ever more nimble in the years to come.

      >
      Note, scrolling up and down changes the hash without adding history
      entries.
      >
      Any idea how this is done? I have been looking for a solution for
      months (on and off, but haven't found anything.)
      Well, the *location* is being *replace*d ...


      HTH

      PointedEars
      --
      realism: HTML 4.01 Strict
      evangelism: XHTML 1.0 Strict
      madness: XHTML 1.1 as application/xhtml+xml
      -- Bjoern Hoehrmann

      Comment

      • Mikey C

        #4
        Re: Update location.hash without adding to history?

        Thanks so much! Seems pretty darn simple now, but this is huge for
        me.

        I had been setting window.location .hash = "value".
        window.location .replace("value ") works!

        Thanks again!,
        -Mike C


        On Nov 21, 2:58 pm, Thomas 'PointedEars' Lahn <PointedE...@we b.de>
        wrote:
        Mikey C wrote:
        I understand in many cases, adding to history when updating
        window.location .hashis a GOOD thing.  In my case, I want toupdate
        bookmarkability from javascript (post-load), but can't get it to do so
        without adding a record to history.  (Firefox 3.0.3)
        >
        I know it's possible to do, because Google is doing it.  See this
        URL:
        http://books.google.com/books?hl=en&...&oi=fnd&pg=PP1...
        >
        Note, scrolling up and down changes thehashwithout adding history
        entries.
        >
        Any idea how this is done?  I have been looking for a solution for
        months (on and off, but haven't found anything.)
        >
        Well, the *location* is being *replace*d ...
        >
        HTH
        >
        PointedEars
        --
            realism:    HTML 4.01 Strict
            evangelism: XHTML 1.0 Strict
            madness:    XHTML 1.1 as application/xhtml+xml
                                                            -- Bjoern Hoehrmann

        Comment

        • David Mark

          #5
          Re: Update location.hash without adding to history?

          On Nov 21, 5:07 pm, Mikey C <mebemik...@gma il.comwrote:
          Thanks so much!  Seems pretty darn simple now, but this is huge for
          me.
          Still a silly idea, regardless of the perceived simplicity.

          Comment

          Working...