DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 1 of 1

Thread: Change location.hash (1) without history entry, and (2) without scrolling the page

  1. #1
    Join Date
    Mar 2009

    Change location.hash (1) without history entry, and (2) without scrolling the page

    I'm attempting to implement some deep-linking in my simple AJAX application by setting location.hash, and I've run into two problems:

    1) Sometimes setting location.hash seems to send the window on both IE and FF to scroll to the top of the page. I do not want any scrolling to occur. The location.hash change happens in a function which is triggered in an onclick event.

    2) Changing location.hash creates a history entry on FF (not on IE)... that's pretty cool for FF, but in this case I do not want a history entry created. How can this be avoided?

    I found an example which seems to have avoided both these problems, but cannot decipher the pertinent code:,M1

    Any help would be great. Thanks.
    Last edited by abeall; 03-13-2009 at 04:06 PM.

Similar Threads

  1. OVERSEAS Online Data Entry Information
    By jai in forum Careers
    Replies: 0
    Last Post: 02-21-2003, 12:43 AM
  2. Replies: 0
    Last Post: 10-29-2001, 03:55 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center