0

I have an anchor point set up in a second page, at a random location within the page:

<a id="myanchor"></a>

When I click the link to go to this anchor:

When I use Chrome, it loads the page and then scrolls down to the anchor point. I want it to load the page directly at the anchor point and not doing any scrolling. Is this possible?

jagku
  • 309
  • 3
  • 14
  • (A) It is not Possible with HTML 4. I am not sure whether this is Possible with HTML 5. You have to use JavaScript & Dynamic Page loading to achieve that. (B) Issue is that , the "outer html" has to be loaded to generate the web-page. During this time , the anchor Point content ( maybe Image which is not yet downloaded , maybe empty $
    $ which will be Populated by JavaScipt later , Etc ) is either not available or available Partially. At the time , the web-browser will have to show some output , which is the Starting Point. It will scroll when there is some content to show. [cont]
    – Prem Apr 11 '23 at 10:41
  • [cont] (C) With JavaScript & Dynamic HTML + AJAX : you can capture the target web-page & target anchor on the Server Side , then generate the output for that Part only & send it over. The web-browser will Display that Part only **without scrolling** because that is the whole web-Page ! When user scrolls up or down , use JavaScript to get that content from web-server & add that to the web-Page. – Prem Apr 11 '23 at 10:45

0 Answers0