简体   繁体   中英

Simple HTML internal link question

Weired, simple HTML stuff didn't work as expected. On page 1, a Railo script named page1.cfm, it has the following line: <a href="page2.html#part2">Go To Page 2, Part 2</a> so, we expect the link would bring the user to the page2.html page's Part 2 section and yes this section and the internal link tag exists on page2.html.

But tested with Firefox 3.6.x, the link simply goes to the page2.html instead of the pag2.html's Part 2 section. How come?

What am I missing here?

Thanks.

这可能只是页面长度的问题,如果页面可以滚动,则查看端口只能滚动以具有#part2节。

There might be some issue with lower/uppercase, if the whole DOM is evaluated a duplicate entry named "part2" might lead to a similar error (check name -attribute as well as id ). To get a better understanding of the problem, the exact code would be needed.

It would be helpful if you were able to post a small section of code that demonstrates the problem. Outside of that, there's a few general things you can try:

  • Try to see if you can reproduce the bug that you're currently experiencing in FF with just straight HTML & Javascript. (I'm going to guess - 'No')
  • Try to reproduce the bug using the smallest possible test case with your .CFM files.
  • Check any/all of your Javascript with JSLint .
  • Check FireFox's Bugzilla for any known .cfm issues.

Often, just starting to isolate the issue can highlight little unseen problems that allow you to solve it quickly. If the bug persists, let us know, and we can go from there....

Cheers.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM