Solved

Speeding up scrolling to bookmark

Posted on 2008-09-29
5
136 Views
Last Modified: 2012-05-05
Hello,

We have a framed page. In the main page, there is a list of categories.

If you click on a category, a request is to made to the server, and the frame then contains the list of categories, and the subcategories for the category clicked on. The link also includes a #bookmark so that it can jump down to the category selected.

The problem is, there is a brief delay where you see the heading of the frame before it gets down to the bookmark. It just looks jumpy.

Is there a way one can speed that up?

The syntax looks like:

<a href="?F=1&cid=1#1" target="main" >

Thanks in advance,

Steve
0
Comment
Question by:skbohler
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 5

Expert Comment

by:mverschoof
ID: 22597120
I don't think this is possible. The page first loads and then jumps to the position. This is how the browser works.

And a small tip. Don't use frames. It's disapproved by almost everybody, including w3c. With CSS positioning and 3 div's you don't even need it.
0
 

Author Comment

by:skbohler
ID: 22597225
Thanks.

It's an old framework that would require a ton of work to remove them.
0
 
LVL 44

Expert Comment

by:scrathcyboy
ID: 22600022
"If you click on a category, a request is to made to the server, and the frame then contains the list of categories, and the subcategories for the category clicked on. "

That is where your delay is -- a server request.  Why do you need to do this on the server?  Why can't you put the lists for each page going into a frame within that page, with accompanying javascript to go to it.

Or else, just have the links for each page include the bookmark --

A href = "thispage.html#bookmark"

Although frames are old coding now, you don't have to redo the whole page to get this faster, unless I am missing something.
0
 

Author Comment

by:skbohler
ID: 22600076
We could download the subcategories and hide them with div. But, if you then click on a subcategory and click on the back button, it doesn't remember the div state (showing instead of hiding, that is).

Or am I misunderstanding you?

Can you elaborate on what you mean by "have the links for each page include the bookmark"?

Steve
0
 
LVL 44

Accepted Solution

by:
scrathcyboy earned 250 total points
ID: 22600285
"click on the back button, it doesn't remember the div state "

Clicking the back button is an entirely different issue.  In IE, the history only includes separate pages, it does not consider going from index.html to index.html#bookmark1 to be a different page, it is the SAME page, just a different position.  So in most cases IE won't show a series of in-page anchors in the back history.

In each HTML page that is going into a frame, are the links in that page (as well as anchors) to where if someone clicks on a link (top contents list) the page itself jumps to this in-page anchor.  If you can answer that, we can go from there.  But if the table of contents links is NOT in the HTML page, but has to be delivered from the server FIRST, before the frame shows it -- then you won't get rid of the delay.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question