Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Global CSS and Local CSS

Status
Not open for further replies.

GDX

Programmer
Jun 4, 2000
186
US
Guys I have a problem!!!

I have an asp site, on all the pages generated it attaches the following:

<link rel=&quot;stylesheet&quot; href=&quot;/css/main.css&quot; type=&quot;text/css&quot;>

Now within this css file it has an a class for links (of course) but i seem to be having a problem

now within the generated page i have a table that contains links, but i want to change the way these links are layed out (color,size,etc...) i dont want it to be like the other links (from the css file) how do i go about doing this? I tried everything but the settings are being inherited by the main.css file instead of the style:

<style>
#articlelink { font-family: Verdana; font-size: 9px; font-style: normal; line-height: normal; font-weight: normal; font-variant: small-caps; text-transform: lowercase}
</style>

i also have a <div id=&quot;articlelink&quot;><table html here></table></div> on the page

Please any help would be greatly appreciated! Gordon R. Durgha
gd@vslink.net
 
Hi gdx,

You have several options:

1. Use style settings inside your a href tag

e.g. <A HREF=&quot;#&quot; style=&quot;FONT-SIZE: 50px;&quot;>You're text</A>

2. After you included your external css file you can define a new style for the link element:
e.g.
<style>
<!--
a {
text-decoration : underline;
COLOR: #FFA400;
FONT-FAMILY: Arial;
FONT-SIZE: 50px;

}
-->
</style>


3. Use several link 'styles':

e.g. in your css file use:

a.general {color:#FFFFFF;}
a.linktable {color:#FFFF00;}
....

Depending on the page you use the style

e.g. <a href=&quot;&quot; class=&quot;linktable&quot;>

I hope this has helped you out

Greetz
Bram
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top