Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Sep 3rd, 2013, 1:43 AM   #1
acegreen
Newbie
 
Join Date: Aug 2013
Posts: 17
Rep Power: 0 acegreen is on a distinguished road
css problem

Question: the following <style> works for me:

<style type="text/css">
.slide1 a:link { text-decoration: none; color: black;}
.slide1 a:visited {text-decoration: none}
.slide1 a:active {text-decoration: none}
.slide1 a:hover {text-decoration: underline; color: black;}
</style>

But when I use it externally as slide1.css
.slide1 {
a:link { text-decoration: none; color: black;}
a:visited {text-decoration: none}
a:active {text-decoration: none}
a:hover {text-decoration: underline; color: black;}
}

and then link with:
<link rel="stylesheet" type="text/css" href="css/slide1.css" />

I get just the generic (blue and static) hyperlink.

Any thoughts?
acegreen is offline   Reply With Quote
Old Sep 3rd, 2013, 4:27 AM   #2
pritaeas
mod_pritaeas
 
Join Date: May 2009
Location: The Netherlands
Posts: 251
Rep Power: 8 pritaeas is on a distinguished road
Re: css problem

Because you can't nest styles like that. You can put it in an external stylesheet, but the layout still has to be the same as before.
pritaeas is offline   Reply With Quote
Old Sep 3rd, 2013, 11:31 AM   #3
Proxi
Programmer
 
Proxi's Avatar
 
Join Date: Aug 2013
Location: Netherlands
Posts: 39
Rep Power: 0 Proxi is on a distinguished road
Re: css problem

Oh never mind. >.> My explanation was the same as pritaeas.
Proxi is offline   Reply With Quote
Old Nov 6th, 2013, 1:40 AM   #4
mostofa62
Always Dummies
 
Join Date: Jul 2013
Location: Dhaka,Bangladesh
Posts: 19
Rep Power: 0 mostofa62 is on a distinguished road
Send a message via Skype™ to mostofa62
Talking Re: css problem

do same you have done in the style sheet,
means also same code in external stylesheet

in style1.css do this

slide1 a:link { text-decoration: none; color: black;}
.slide1 a:visited {text-decoration: none}
.slide1 a:active {text-decoration: none}
.slide1 a:hover {text-decoration: underline; color: black;}

hope it will work
__________________
Nothing Can End
mostofa62 is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
problem with css in ie9 Cole001 HTML / XHTML / CSS 2 Sep 30th, 2012 2:25 AM
CSS Position Problem blakec HTML / XHTML / CSS 9 Oct 27th, 2011 5:41 AM
Help with CSS Problem TheDJ HTML / XHTML / CSS 3 Mar 2nd, 2011 5:18 PM
CSS template problem with Joomla, please help josh305 HTML / XHTML / CSS 0 Dec 29th, 2010 3:59 PM
problem in css desperateboy HTML / XHTML / CSS 2 Oct 27th, 2007 7:29 AM




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 10:03 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC