www.webdeveloper.com
Results 1 to 3 of 3

Thread: Scroll div and site position

Hybrid View

  1. #1
    Join Date
    Jun 2010
    Posts
    5

    Scroll div and site position

    Hi,

    I have scroll div on the buttom of my page. This div is autoloaded after pressing link via AJAX technology. Everything is ok except position of the web. Right after I press link the view of the page is going to the top. How I could set the view on the div after AJAX content is loaded.

    Krystian.

  2. #2
    Join Date
    Dec 2003
    Location
    Bucharest, ROMANIA
    Posts
    15,428
    Probably you have not prevented the HTML action of a link with a JavaScript return false, thus the click provokes a scrolling to an nonexistent hash anchor, that means top, by default. Try something like this:
    Code:
    <a href="#" onclick="yourAJAXfunction();return false">call AJAX</a>

  3. #3
    Join Date
    Jun 2010
    Posts
    5
    it is working fine,

    thanks a lot !

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

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



Recent Articles