Why Style sheet isnt working

This is a discussion on "Why Style sheet isnt working" within the Web Page Design section. This forum, and the thread "Why Style sheet isnt working are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Dec 10th, 2007, 13:44
kaz kaz is offline
Up'n'Coming Member
Join Date: Feb 2005
Location: Accra
Age: 42
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to kaz
Why Style sheet isnt working

Hi,

can someone tell me why my style sheet(below) isnt working?

thanx
Code: Select all
body {
    background-color: #fffafa;
    }
    .ictdnews{font-family:Arial;font-weight:bold;font-size:x-large;text-transformation:uppercase;
    }
.ictdmain{width:400;background-color: #00ff00;

}
    
.online{color:#000000;font-family:Arial;font-weight:none;font-size:16;text-transformation:Capitalize;
}

.onlineregister{{color:#000000;font-family:Arial;font-weight:none;font-size:12;text-transformation:none;
}

Last edited by welshstew; Dec 10th, 2007 at 13:46. Reason: add tags
Reply With Quote

  #2 (permalink)  
Old Dec 10th, 2007, 13:47
welshstew's Avatar
Lead Administrator

SuperMember
Join Date: May 2007
Location: inside the outside
Posts: 1,388
Blog Entries: 13
Thanks: 1
Thanked 17 Times in 15 Posts
Re: Why Style sheet isnt working

are you able to post a link to your page, or put up your full css and html for us to look at.

Thanks
__________________
WelshStew
Lead Administrator

tierney rides tboard - uk site | xtreme wales - extreme clothing
If you think I've helped, click the "Thanks"
webforumz - facebook | LinkedIn
Last Blog Entry: Web Standards Curriculum Launched (Jul 8th, 2008)
Reply With Quote
  #3 (permalink)  
Old Dec 10th, 2007, 14:02
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

Probably because it's invalid CSS!
Reply With Quote
  #4 (permalink)  
Old Dec 10th, 2007, 22:35
Highly Reputable Member
Join Date: Sep 2007
Age: 15
Posts: 717
Blog Entries: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

Mike's right! Invalid CSS caused a lot of problems...
Last Blog Entry: Windows Vista vs. Mac Leopard (Nov 4th, 2007)
Reply With Quote
  #5 (permalink)  
Old Dec 11th, 2007, 02:39
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Send a message via Yahoo to Monie
Re: Why Style sheet isnt working

check out your .onlineregister style! You got double "{" in it!

Code: Select all
body {
background-color: #fffafa;
}
.ictdnews {
font-family:Arial;
font-weight:bold;
font-size:x-large;
text-transformation:uppercase;
}
.ictdmain {
width:400;
background-color: #00ff00;
}    
.online {
color:#000000;
font-family:Arial;
font-weight:none;
font-size:16;
text-transformation:Capitalize;
}
 .onlineregister {
 {color:#000000;
font-family:Arial;
font-weight:none;
font-size:12;
text-transformation:none;
}
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)

Last edited by Monie; Dec 11th, 2007 at 02:42.
Reply With Quote
  #6 (permalink)  
Old Dec 12th, 2007, 10:49
kaz kaz is offline
Up'n'Coming Member
Join Date: Feb 2005
Location: Accra
Age: 42
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to kaz
Re: Why Style sheet isnt working

I've made the changes, but I'm not getting the desired result. I'm gonna highlight the tags in question, and I'm also going to post the HTML code as well.

body {
background-color : #fffafa;
}
.ictdnews {
font-family : Arial;
font-weight : bold;
font-size : x-large;

}
.ictdmain {
background-color : #00ff00;width:400;

}
.online {
color : #000000;
font-family : Arial;
font-size:16





<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>
<head>
<title>Untitled</title>
<link href="news.css." rel="stylesheet" type="text/css" />
<style type="text/css">
</head>
<body>
<p class="ictdnews">ictd news</p
td width="400"valign="top" class="ictdmain"><h4 class="networking">New online Register to be installed</h4>
thanx
Reply With Quote
  #7 (permalink)  
Old Dec 12th, 2007, 11:18
SuperMember

SuperMember
Join Date: Sep 2006
Location: Pink House
Posts: 3,946
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

What are you trying to accomplish?
Reply With Quote
  #8 (permalink)  
Old Dec 12th, 2007, 13:20
kaz kaz is offline
Up'n'Coming Member
Join Date: Feb 2005
Location: Accra
Age: 42
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to kaz
Re: Why Style sheet isnt working

I want the.ictd news to be in large print and the table to render the background color as shown in the stylesheet. But nothing is happening.
Reply With Quote
  #9 (permalink)  
Old Dec 12th, 2007, 16:37
SuperMember

SuperMember
Join Date: Sep 2006
Location: Pink House
Posts: 3,946
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

Is this the name of your css file(part I highlighted in red)
Code: Select all
 <link href="news.css." rel="stylesheet" type="text/css" />
?

Oh I just noticed.. you have a period after the news.css
Delete that period.
Reply With Quote
  #10 (permalink)  
Old Dec 12th, 2007, 17:32
New Member
Join Date: Dec 2007
Location: Surrey
Age: 32
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

ooh, to add... you haven't closed your .online with }
Reply With Quote
  #11 (permalink)  
Old Dec 12th, 2007, 17:38
karinne's Avatar
SuperMember

SuperMember
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

also ... widths, heights and font-sizes need unit like px or em or %
Reply With Quote
  #12 (permalink)  
Old Dec 12th, 2007, 18:36
New Member
Join Date: Dec 2007
Location: Surrey
Age: 32
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

but apart from that it's really pretty. well done :-)
Reply With Quote
  #13 (permalink)  
Old Dec 12th, 2007, 21:55
Junior Member
Join Date: Jul 2007
Location: Arkansas, USA
Age: 21
Posts: 45
Blog Entries: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to nashultz07 Send a message via MSN to nashultz07
Re: Why Style sheet isnt working

Quote:
Originally Posted by kaz View Post
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>
<head>
<title>Untitled</title>
<link href="news.css." rel="stylesheet" type="text/css" />
<style type="text/css">
</head>
<body>
<p class="ictdnews">ictd news</p
td width="400"valign="top" class="ictdmain"><h4 class="networking">New online Register to be installed</h4>
thanx
Also you have the highlighted code included but no css code or ending to that style before you start the HTML code. Try correcting this and see if that corrects the problem.
Last Blog Entry: First Post! (Apr 18th, 2008)
Reply With Quote
  #14 (permalink)  
Old Dec 17th, 2007, 16:21
kaz kaz is offline
Up'n'Coming Member
Join Date: Feb 2005
Location: Accra
Age: 42
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to kaz
Re: Why Style sheet isnt working

Hi, I've made the changes you've suggested. However, the background color for the main table(t.ictdmain) is not showing. I'm at my wits end. here is the style sheet and html with the tag in question highlighted.
Code: Select all
body {
background-color : #00ffff;
}
.ictdnews {
font-family : Arial;
font-weight : bold;
font-size : x-large;}
t.ictdmain{width:400px;background-color:#ffffff;border:solid,thin,#000000

;}
.network{font-family:Arial;font-weight:bold;font-size:16px; 

text-transform:capitalize;}
HTML: Select all
<html>
<head>
<title>Untitled</title>
<link href="news.css" rel="stylesheet" type="text/css" />
</style>
</head>
<body>
<p class="ictdnews">ictd news</p>
<div class="ictmain"width="400px"valign="top"
<h4 class="network">New online Register to be installed</h4>

</div>
</body>
</html>

Last edited by welshstew; Dec 17th, 2007 at 17:23. Reason: add tags
Reply With Quote
  #15 (permalink)  
Old Dec 17th, 2007, 16:54
karinne's Avatar
SuperMember

SuperMember
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

Please provide a link ... there may be something else fudging this.
Reply With Quote
  #16 (permalink)  
Old Dec 17th, 2007, 17:26
welshstew's Avatar
Lead Administrator

SuperMember
Join Date: May 2007
Location: inside the outside
Posts: 1,388
Blog Entries: 13
Thanks: 1
Thanked 17 Times in 15 Posts
Re: Why Style sheet isnt working

your css still isn't validating.

you need to remove the commas within the border style for .ictdnews so that it reads
border:solid thin #000000;

not

border:solid,thin,#000000;
__________________
WelshStew
Lead Administrator

tierney rides tboard - uk site | xtreme wales - extreme clothing
If you think I've helped, click the "Thanks"
webforumz - facebook | LinkedIn
Last Blog Entry: Web Standards Curriculum Launched (Jul 8th, 2008)
Reply With Quote
  #17 (permalink)  
Old Dec 18th, 2007, 01:40
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Send a message via Yahoo to Monie
Re: Why Style sheet isnt working

Looks like you guys have sharper eyes than me
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
Reply With Quote
  #18 (permalink)  
Old Dec 20th, 2007, 10:05
kaz kaz is offline
Up'n'Coming Member
Join Date: Feb 2005
Location: Accra
Age: 42
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to kaz
Re: Why Style sheet isnt working

Quote:
Originally Posted by karinne View Post
Please provide a link ... there may be something else fudging this.
hi karinne

the link for the page is:http://kazmania.110mb.com/indexx.htm

css link is :http://kazmania.110mb.com/newss.htm

Last edited by kaz; Dec 20th, 2007 at 10:29. Reason: missing letter in URL
Reply With Quote
  #19 (permalink)  
Old Dec 20th, 2007, 10:12
SuperMember

SuperMember
Join Date: Jun 2007
Location: uk
Posts: 459
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why Style sheet isnt working

links not working for me.
Reply With Quote
  #20 (permalink)  
Old Dec 21st, 2007, 01:10
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Send a message via Yahoo to Monie
Re: Why Style sheet isnt working

not for me too, DEAD link.
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
Reply With Quote
Reply

Thread Tools

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
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding a style sheet to an RSS feed problem Andrew1986 Other Programming Languages 5 Feb 19th, 2008 10:31
CSS Print Style Sheet Problem bennyboy7 Web Page Design 1 Aug 14th, 2007 08:58
new to css: what's the best way to insert image using the external style sheet? mad samuel Web Page Design 14 Aug 10th, 2007 17:52
How to tell IE7 to use a pariticular style in a single style sheet figo2476 Web Page Design 5 May 25th, 2007 14:23
Linking to an external style sheet ahm531 Web Page Design 6 Aug 31st, 2006 13:23


All times are GMT. The time now is 02:50.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43