![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have a document with lots of <a> tags that wrap phrases to make them anchors only (no href attribute). When I display the document, they do not have underline or color in the browser. Is there a way to style these tags with css? |
#3
| |||
| |||
|
|
In article 4b058073-dafb-4a1a-a610-74d273f94efc...oglegroups.com>, Andy <p7eregex (AT) gmail (DOT) com> wrote: I have a document with lots of <a> tags that wrap phrases to make them anchors only (no href attribute). When I display the document, they do not have underline or color in the browser. Is there a way to style these tags with css? a {text-decoration: underline; color: red; background: white;} a:link {text-decoration: none; color: blue; background: white;} a name="here">here</a><br a href="example.com">example.com</a |
#4
| |||
| |||
|
|
a name="here">here</a |
#5
| |||
| |||
|
|
On Tue, 29 Sep 2009 07:23:51 +1000, dorayme wrote: In article 4b058073-dafb-4a1a-a610-74d273f94efc...oglegroups.com>, Andy <p7eregex (AT) gmail (DOT) com> wrote: I have a document with lots of <a> tags that wrap phrases to make them anchors only (no href attribute). When I display the document, they do not have underline or color in the browser. Is there a way to style these tags with css? a {text-decoration: underline; color: red; background: white;} a:link {text-decoration: none; color: blue; background: white;} a name="here">here</a><br a href="example.com">example.com</a Yes, but wait a minute: Is the OP really trying to make non-links look like links (just because he used an <a> element)? Or am I just too tired to think clearly? The code example above makes the real links look like blue regular text, and the non-link anchors look like red links. I think I won't want to visit that page. Or maybe I'm just tired. |
#6
| |||
| |||
|
|
I can see where that might be kind of useful. If you wanted to distinguish between internal and external links, and provide a "bookmark" so a user could clearly tell where an internal link goes. Here's a sample: http://www.cavalcade-of-coding.info/usenet/anchors.html |
#7
| |||
| |||
|
|
Adrienne Boswell wrote: I can see where that might be kind of useful. If you wanted to distinguish between internal and external links, and provide a "bookmark" so a user could clearly tell where an internal link goes. Here's a sample: http://www.cavalcade-of-coding.info/usenet/anchors.html Internal vs. external links is really a different issue (and awkward, since there's really no other working way to distinguish between them except via classes). Indicating "bookmarks" would be useful, but doing it statically with a[name] (and/or a[id] or *[id]) isn't particularly useful. Little does it help to see all the possible destinations for links, when the user would really need to isolate the particular destination he just jumped to. But there's no such way in CSS. |
#8
| |||
| |||
|
|
I agree with you, but it would be kind of nice to see "bookmarks". Opera has a a scrolling thingy, but it doesn't work the way it should. |
![]() |
| Thread Tools | |
| Display Modes | |
| |