• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

'a href' in firefox

 
Maggie Taylor
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I'm using this code..




I have a few people names in alphabetical order list from A to Z. When I click on an alphabet I expect it to go firstname starting with that alphabet.

I have defined <a name ="A">A</a> <a name="B">B</a> , etc. (all the alphabets) appropriately for the names starting with that alphabet on the html page.

This is working perfectly fine in Internet Explorer, but not in Firefox. What might be the problem ?

thanks
[ April 06, 2006: Message edited by: Maggie Taylor ]
 
Linda Walters
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You will need to put an anchor tag <a> around the letter(s) to which you want to go. For examle:


<a href="#W">W</a>
...
...
<a name="W">W</a>

The first anchor tag is what you click on to get to the second anchor tag.
 
Linda Walters
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oops, I only got part of that in....

I tried this this with Firefox 1.5 and it works fine.
Here is a snippet of the HTML:


<html>
<body>
<a href="#W">go to W</a>
<br />
....
....

<a name="W">W</a>
...
...
 
Maggie Taylor
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for helping...but it's still not working i'm using Mozilla 1.5 as well.
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
try

<a name="W" id="W">W</a>

or

<a name="W" id="W"></a>W

or even

<a name="W" id="W" href="#W">W</a>

One of those will hopefully work. To busy to test.

Eric
 
Linda Walters
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maggie,

The following HTML works in IE 6.0, Firefox 1.5.01, Mozilla 1.7.12, Netscape 8.0.3.3 and even in Opera 8.5. Note that all of the <br /> tag are here to make the page long enough to acutally see it goto the letter.

<html>
<body>
<a href="#W">Go To W</a><br /><br />
<a name="A">A</a>
<br /><br /><br /><br />
<a name="B">B</a>
<br /><br /><br /><br />
<a name="C">C</a>
<br /><br /><br /><br />
<a name="D">D</a>
<br /><br /><br /><br />
<a name="E">E</a>
<br /><br /><br /><br />
<a name="F">F</a>
<br /><br /><br /><br />
<a name="G">G</a>
<br /><br /><br /><br />
<a name="H">H</a>
<br /><br /><br /><br />
<a name="I">I</a>
<br /><br /><br /><br />
<a name="J">J</a>
<br /><br /><br /><br />
<a name="K">K</a>
<br /><br /><br /><br />
<a name="L">L</a>
<br /><br /><br /><br />
<a name="M">M</a>
<br /><br /><br /><br />
<a name="N">N</a>
<br /><br /><br /><br />
<a name="O">O</a>
<br /><br /><br /><br />
<a name="P">P</a>
<br /><br /><br /><br />
<a name="Q">Q</a>
<br /><br /><br /><br />
<a name="R">R</a>
<br /><br /><br /><br />
<a name="S">S</a>
<br /><br /><br /><br />
<a name="T">T</a>
<br /><br /><br /><br />
<a name="U">U</a>
<br /><br /><br /><br />
<a name="V">V</a>
<br /><br /><br /><br />
<a name="W">W</a>
<br /><br /><br /><br />
<a name="X">X</a>
<br /><br /><br /><br />
<a name="Y">Y</a>
<br /><br /><br /><br />
<a name="Z">Z</a>
</body>
</html>
 
Maggie Taylor
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks once again. I got it working now.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic