| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
| DesignersTalk > Inline css changing the properties of the links |
|
LinkBack | Thread Tools | Search this Thread |
|
|
#1 (permalink) |
|
Registered User
Join Date: Mar 2008
Posts: 36
|
Inline css changing the properties of the links
How can I use inline CSS but change the properties of a link i.e visited, active etc <p style='font-family:verdana, arial;font-size:0.65em;color: #ffffff;padding-left:30px;padding-right:30px;'><a href="javascript:collapse2.slideit ()">Open/Close</a></p> Thats my current inline settings, it cannot be put into a div because otherwise the javascript doesnt work correctly. THANKS! |
|
|
|
|
|
#3 (permalink) |
|
Everything is fine.
|
As a side note and pointer, you really should be using CSS externally as opposed to inline. The main benefit is that you can apply a style to a class or specific element throughout your entire site and when the time comes to change any stylistic information for it (such as a:visited etc.) you only need to edit the external CSS file once and the change will be reflected across your entire site instantly. No more searching through every document for every instance you need to change for you! If you want more information on best practices, such as the one mentioned above, then do a quick search on this forum or indeed Google and you will be rewarded with a wealth of information! - Mike Mike Mackay: Web Developer - LinkedIn
|
|
|
|
#4 (permalink) |
|
Registered User
Join Date: Mar 2008
Posts: 36
|
I have been using external css, of course I know that. Infact I know external more than I do internal. It was because the piece of javascript which was used to "open and close" the content couldnt be with in the div, else it would close that text aswell. So applying the styles to that HAD to be internal, I then thought about it and changed some of the external stylesheet. |
|
![]() |