CSS Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignCSS Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 10th, 2003, 02:54 PM
WorldBuilder's Avatar
WorldBuilder WorldBuilder is offline
Big Daddy
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Sep 2003
Location: Boston
Posts: 1,470 WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 3 Days 4 h 53 m 8 sec
Reputation Power: 20
Send a message via AIM to WorldBuilder
CSS questions

Hi all,

I have a site at http://www.geocities.com/early_years_nh/funstuff.html which is working just fine, but there's a small problem. Actually, it's not even a problem, just an annoyance that I can't seem to wrap my brain around... I am FAIRLY new to HTML and CSS, so please bear with me if this sounds simple. It probably is...

Check out the site, and you'll notice that ALL of the links, even the ones in the middle, inherit the same properties from the style sheet. Well, I want the links to the right and left sides of the screen to remain exactly as they are, but I don't want the 3 image links in the middle to use those properties.

For the 3 image links, I set up a class in my CSS specifically for them so they would use it instead of the properties for the other links. In the html, I put those image links in a <div>. First of all, do I even need the <div>? It would seem not. Secondly, looking at the CSS code below, can someone tell me why the classes are being ignored and the image links are getting the same properties as all the other links? I thought that having classes in the CSS allowed for distinguishable characteristics within a page! I've done it before. Is my syntax just wrong? Thanks!

Here's the CSS:
Code:
/* CSS Document */
/* fun.css */

body {
          background-image: url("multiple_heart_background.gif");
}
          
a:link {  font-family: kidtypepaint, Verdana, Geneva, Arial, Helvetica, san-serif;
	  font-weight: normal; 
	  color: #800080; 
	  text-decoration: underline; 
	  font-size: 14px; 
	  text-transform: none; 
}

a:visited {  
          font-family: garamond, Verdana, Geneva, Arial, Helvetica;
	  font-weight: bold; 
	  color: #ff3333; 
	  text-decoration: none; 
	  font-size: 11px; 
	  text-transform: uppercase; 
}

a:hover {  
          font-family: Verdana, Geneva, Arial, Helvetica, san-serif;
	  font-weight: bold; 
	  color: #CD853F; 
	  text-decoration: underline; 
	  font-size: 14px; 
	  text-transform: uppercase; 
}

a:active { font-family: Verdana, Geneva, Arial, Helvetica, san-serif;
	   font-weight: bold; 
	   color: #ffffff; 
	   text-decoration: underline; 
	   font-size: 11px; 
	   text-transform: uppercase; 
}

h2
{
	padding-top: 30px;
        color: #6a5acd;
	padding-bottom: 30px;
	border: 0px;
	font-family: space toaster, kidtypepaint, Verdana, Geneva, Arial, Helvetica;
        font-size: 1em;
	text-align: center;
	text-decoration: underline;
	letter-spacing: .5em;
}

/* Image Links */
.middle
{	  font-family: garamond, Verdana, Geneva, Arial, Helvetica;
	  font-weight: bold; 
	  color: #ff3333; 
	  text-decoration: none; 
	  font-size: 11px; 
	  text-transform: uppercase; 
}


Chris

PS: Oh, before I forget. In addition to all that, can anyone tell me why the background image is not showing up? I have tried putting it in the body tag in html, and in a table! Neither of those methods worked either. Thanks!
__________________
Pop, pop, fizz, fizz, oh what a relief it is!

Reply With Quote
  #2  
Old October 11th, 2003, 03:36 AM
duwgati duwgati is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 98 duwgati User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 h 46 m 58 sec
Reputation Power: 5
Replace the style middle by something like this:

a.middle:active, a.middle:link, a.middle:visited {
font-family: Tahoma, Verdana, Geneva, Arial, Helvetica, sans-serif;
font-size: 8pt;
color: Blue;
text-decoration: none;
}
a.middle:hover {
color: Black;
text-decoration: underline;
}


And change you body tag to:
<body class="body">

That should display the background image.
Success

Reply With Quote
  #3  
Old October 11th, 2003, 04:22 AM
Akh's Avatar
Akh Akh is offline
|<.+#f@#+.&.|
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: Mar 2002
Location: norway
Posts: 2,622 Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level)Akh User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 3 Weeks 6 Days 2 h 17 m 15 sec
Reputation Power: 548
use

.middle a {
/* some style */
}

this will let you set style to the a-tags
within the div .middle


you probably have the wrong url to the background picture, couldn't get any picture when i tried the url.
(http://www.geocities.com/early_year..._background.gif)

Reply With Quote
  #4  
Old October 11th, 2003, 08:14 AM
WorldBuilder's Avatar
WorldBuilder WorldBuilder is offline
Big Daddy
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Sep 2003
Location: Boston
Posts: 1,470 WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 3 Days 4 h 53 m 8 sec
Reputation Power: 20
Send a message via AIM to WorldBuilder
Thanks, guys. I appreciate the responses. I got the background to work. It must have been a typo on my part, but damned if I can find out what the typo was! lol

Anyway, I am still having trouble with the CSS. It is still not working in the middle section. What am I doing wrong here? I applied your suggestions individually. Some had no affect at all, some affected the entire page! I even tried setting up seperate left and right classes for the links on the sides, but that was met with strange results as well. I have changed the CSS back to its original so as not to screw anything up. I have my CSS book handy and am reading away, to no avail. This is driving me crazy! Any more ideas?

Chris

Last edited by cjwsb : October 11th, 2003 at 09:01 AM.

Reply With Quote
  #5  
Old October 11th, 2003, 11:33 AM
duwgati duwgati is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 98 duwgati User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 h 46 m 58 sec
Reputation Power: 5
You now use this code for the links in the middle:
<A href="http://www.geocities.com/early_years_nh/activities.html" ><IMG src=" blablabla

Insert the style class in like this:
<A href="http://www.geocities.com/early_years_nh/activities.html" class="middle"><IMG src=" blablabla

Reply With Quote
  #6  
Old October 11th, 2003, 11:51 AM
WorldBuilder's Avatar
WorldBuilder WorldBuilder is offline
Big Daddy
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Sep 2003
Location: Boston
Posts: 1,470 WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 3 Days 4 h 53 m 8 sec
Reputation Power: 20
Send a message via AIM to WorldBuilder
Ok, leaving the CSS the way it was, I inserted the style class like you said. No difference. Every single link on the page still has all the same attributes. Argh!!! What am I doing wrong? I will make it as easy as I can. For now, I'd be more than happy to just settle for browser defaults on the 3 middle image links. How can I do that?

Chris

Reply With Quote
  #7  
Old October 11th, 2003, 12:22 PM
duwgati duwgati is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 98 duwgati User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 h 46 m 58 sec
Reputation Power: 5
Just have a look here , is this what you want?

Reply With Quote
  #8  
Old October 11th, 2003, 01:28 PM
WorldBuilder's Avatar
WorldBuilder WorldBuilder is offline
Big Daddy
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Sep 2003
Location: Boston
Posts: 1,470 WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level)WorldBuilder User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 3 Days 4 h 53 m 8 sec
Reputation Power: 20
Send a message via AIM to WorldBuilder
EXACTLY! I just looked at the CSS you did and copied it to mine. I SEE IT! Ok, great. Now I understand why it wasn't working. Thanks! That was driving me crazy, but now I am a little smarter


Chris;

Last edited by cjwsb : October 11th, 2003 at 01:33 PM.

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignCSS Help > CSS questions


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway