FRIHOSTFORUMSSEARCHFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

Simple CSS Question (Urgent Help)

 


imagefree
Please tell me how can i define style for all the the "a" tags that are inside strong tags (or all a tags that have strong tag inside it).

What i want is that defalt style for my pages is that all a tags are underlined. All a:hover are not underlined.

In case of BOLD (Strong) a tags, i want it not to underline the simple a tag (neither the a:hover).

How can i do this?
Please tell me a solution that works for all browsers.

Thanks
Bengt
Make a separate style for your pieces that are bold+a. Define it as a name you choose yourself and 'connect' to the right pieces. And that's it ?
imagefree
Bengt wrote:
Make a separate style for your pieces that are bold+a. Define it as a name you choose yourself and 'connect' to the right pieces. And that's it ?


I want to define a tag style that will be effective all over the page (even inside other styles).
jylan
To style all <a> tags contained withing <strong> or <b> tags use the following format:
Code:
strong a:link, b a:link {}
.

By default all links are underlined but to take away the underline from a:hover use the code below:
Code:
a:hover { text-decoration:none; }


Don't forget to use the correct link order, it can be remembered by saying LoVe HA. a:link 1st, a:visited 2nd, a:hover 3rd and a:active 4th.
sonam
Maybe I didn't understand your question but if you need strong a tag (different then a) then just define a tags (a:link, a:visited, a:hover and a:active) and create one new css definition e.g.

Code:
.strong { 
font-weight : bold
}


and call this class in html.

Code:
<a class="strong" href="somepage.html">orange</a>


In that case a tag will have all style before defined for a tags and it will get bold from strong defintion.

Sonam
blueray
Please try this :

html:

Code:

<strong><a></a></strong>



css:

Code:

a {
text-decoration: underline;
}

a:hover {
text-decoration: none;
}

strong a, strong a:hover {
text-decoration: none;
}
JayBee
or for "strong" tags in "a" just switch "a" and "strong" so the full declaration shoul look like
Code:

strong a, strong a:hover, a strong, a:hover strong {
text-decoration: none;
}
Related topics
What is DirectAdmin Account? - Urgent Help Needed
Need urgent help - Joomla got hacked
HTML tables with irregular rows and/or columns
CSS Question Aid Please
CSS Quotation Help
extra line from css in drop down menu
rollovers in CSS
CSS Help needed : Table emulation with divs
Problems with CSS- 2 different Link Styles
AJAX tutorial [2nd part now updated]
URGENT! Problem with chmod files.
Sending simple emails using PERL - Help required
Very Urgent....!!! Help...
Re Alcholic Help
CSS and layout help
CSS tools
simple php problem, please help...
css question
Urgent Help > Serious Virus Infection
php, css question (wordpress)
hiding css from netscape
urgent help
Simple(?) probability question
CSS problem - very simple css dont work in Firefox/Opera.
Reply to topic    Frihost Forum Index -> Scripting -> Html, CSS and Javascript

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.