Forum Moderators: not2easy

Message Too Old, No Replies

Don't want underlined anchor text in table

Trying to get it to work in firefox

         

chopin2256

7:42 pm on Jul 21, 2005 (gmt 0)

10+ Year Member



I want to get rid of underlined anchor text in a specific table (my left border). So, here is the code that works well in IE, but doesn't work well in Firefox. The code is simplified to only show what I want done.

#sborder td
{
.links { text-decoration: none}
}

Can anyone help me get this to work in Firefox as well? Thanks!

D_Blackwell

7:54 pm on Jul 21, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Just declare {text-decoration: none;}as necessary.

#sborder td a {
text-decoration: none;
}

or

.links a {
text-decoration: none;
}

This shouldn't work at all:

#sborder td
{
.links { text-decoration: none}
}

chopin2256

1:23 am on Jul 22, 2005 (gmt 0)

10+ Year Member



Thanks alot. I have one more question. Within a table, I'd like the text to be top-left aligned. I know how to do the left aligned, but what about top aligned? What is the code to do that? Thanks again.

D_Blackwell

1:46 am on Jul 22, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Will vertical-align suit your purpose?
W3c [w3.org]

chopin2256

1:48 am on Jul 22, 2005 (gmt 0)

10+ Year Member



I lied, I have another question to ask! I also want to have a default H1 font in my table cell. For example, instead of font-size: 20pt, I would like something like this:

font-size: H1;

This way, I dont have to manually add the H1 tags every time in that particular cell. Is there a way to do this?

chopin2256

1:52 am on Jul 22, 2005 (gmt 0)

10+ Year Member



Will vertical-align suit your purpose?

Bingo, thats what I was looking for :) Thank you. Maybe you can answer my very last question about the H1. I know that H1 tags are good for seo, and I was just wondering if using CSS can be a substitute...and what would be the code for that. It probably would be something like:

font-size: 200%;

But it didn't quite look like the H1 tag. Not too sure.

tedster

2:17 am on Jul 22, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Using an H1 tag that actually is the main topic is a good SEO practice - and even a good semantic mark-up practice altogether. But it's not that an H1 tag is some kind of magic bullet, and its effectiveness has NOTHING to do with the way the font is rendered in the page's visual display.

If you use css to make a line of text look like an H1 tag, but you don't actually use an H1 tag in the mark-up, then there is no SEO advantage, nor is there any semantic clarity.

g1smd

10:34 am on Jul 25, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I love this little mentioned selector.

If you ever find your self with the same class name being attached to multiple elements over and over again:

<ul>
<li><a class="plain" href="blah.html">blah</a></li>
<li><a class="plain" href="blah.html">blah</a></li>
<li><a class="plain" href="blah.html">blah</a></li>
<li><a class="plain" href="blah.html">blah</a></li>
</ul>

a.plain {text-decoration: none;}

then you need to attach the class to the parent HTML element and then style it like this:

<ul class="plain">
<li><a href="blah.html">blah</a></li>
<li><a href="blah.html">blah</a></li>
<li><a href="blah.html">blah</a></li>
<li><a href="blah.html">blah</a></li>
</ul>

.plain a {text-decoration: none;}

It removes a lot of bloat from the HTML.