Why should I validate CSS?

This is a discussion on "Why should I validate CSS?" within the Web Page Design section. This forum, and the thread "Why should I validate CSS? 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 May 7th, 2007, 15:10
spinal007's Avatar
Moderator
Join Date: Mar 2004
Location: Good Ol'London
Age: 22
Posts: 1,620
Blog Entries: 1
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via ICQ to spinal007 Send a message via MSN to spinal007 Send a message via Yahoo to spinal007 Send a message via Skype™ to spinal007
Why should I validate CSS?

Other than the obvious "to make sure I've got the syntax right", I don't see the point. I've just gone through lengths to make sure "non-standard" statements in my CSS files passed the W3C CSS validation. Then I came across some interesting articles on this issue.

One interesting example is the opacity rule. Although it's valid CSS3, some browsers (*cough* IE *cough*) don't support it as they should. Forcing me to do this...
Code: Select all
opacity: .9;  filter: progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=90);
But why should I work around to hide the 'filter' rule when it's simply ignored by other browsers?
Why should the user be forced to download an additional stylesheet?
Why should I separate my code for different browsers when the idea of validation is that your code can be supported by most browsers?

I see the benefits of validating you HTML, but can someone explain why I should bother validating my CSS?
Last Blog Entry: Random String in Javascript (Apr 21st, 2008)

Last edited by spinal007; May 7th, 2007 at 15:12.
Reply With Quote

  #2 (permalink)  
Old May 7th, 2007, 18:28
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why should I validate CSS?

I do it because I'm anal. I just cheat the system and use JavaScript to write the rule. Lol
Reply With Quote
  #3 (permalink)  
Old May 7th, 2007, 19:47
VanessaJW's Avatar
SuperMember

SuperMember
Join Date: Apr 2007
Location: Kent, England
Age: 37
Posts: 560
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why should I validate CSS?

If everybody coded their sites strictly to standard, with everything fully validated, then the browser makers would be forced to make browsers which complied more uniformly, making life so much easier for all web designers/developers. That's why I personally think it's just as important to validate the CSS as the HTML - for the greater good! Just my opinion. (You can remind me that I said this when I post my first site up for critique, complete with validation problems)
Reply With Quote
  #4 (permalink)  
Old May 7th, 2007, 23:15
spinal007's Avatar
Moderator
Join Date: Mar 2004
Location: Good Ol'London
Age: 22
Posts: 1,620
Blog Entries: 1
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via ICQ to spinal007 Send a message via MSN to spinal007 Send a message via Yahoo to spinal007 Send a message via Skype™ to spinal007
Re: Why should I validate CSS?

Quote:
Originally Posted by Ryan Fait View Post
I do it because I'm anal. I just cheat the system and use JavaScript to write the rule. Lol
LOL, I use Javascript to insert all my "non-standard" CSS rules too...
BUT WHY??? I'm not gonna bother anymore... I'm gonna use opacity and filter as much as I want! :P
Last Blog Entry: Random String in Javascript (Apr 21st, 2008)
Reply With Quote
  #5 (permalink)  
Old May 8th, 2007, 03:20
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why should I validate CSS?

Hehe, I understand. If only browsers didn't suck.
Reply With Quote
  #6 (permalink)  
Old May 8th, 2007, 05:05
sannbe's Avatar
SuperMember

SuperMember
Join Date: Dec 2006
Location: San Francisco
Age: 57
Posts: 1,567
Blog Entries: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why should I validate CSS?

Quote:
Originally Posted by Ryan Fait View Post
Hehe, I understand. If only browsers didn't suck.
So we validate all our sites so they are absolutely perfect and force...yes...force browser bigwigs to get off rears and give us some better browsers...
Last Blog Entry: More Sara Blogging (Nov 29th, 2007)

Last edited by sannbe; May 8th, 2007 at 05:06. Reason: soelling 201 correct edit spelling 201 shot self in foot
Reply With Quote
  #7 (permalink)  
Old May 8th, 2007, 14:39
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,761
Blog Entries: 1
Thanks: 0
Thanked 18 Times in 18 Posts
Send a message via AIM to moojoo Send a message via MSN to moojoo Send a message via Yahoo to moojoo
Re: Why should I validate CSS?

This won't validate but works, sometimes you just have to eat an error.

Code: Select all
filter:alpha(opacity=80);
-moz-opacity:.80;
opacity:.80;
__________________
The internet is just a fad.
http://www.mevans76.com
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #8 (permalink)  
Old May 8th, 2007, 19:50
spinal007's Avatar
Moderator
Join Date: Mar 2004
Location: Good Ol'London
Age: 22
Posts: 1,620
Blog Entries: 1
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via ICQ to spinal007 Send a message via MSN to spinal007 Send a message via Yahoo to spinal007 Send a message via Skype™ to spinal007
Re: Why should I validate CSS?

Quote:
Originally Posted by moojoo View Post
This won't validate but works, sometimes you just have to eat an error.

Code: Select all
filter:alpha(opacity=80);
-moz-opacity:.80;
opacity:.80;
opacity/filter is exactly what I'm talking about. It's valid CSS3. Stuff the W3C validation, it works cross-browser and I'm sticking to it!
Last Blog Entry: Random String in Javascript (Apr 21st, 2008)
Reply With Quote
  #9 (permalink)  
Old May 8th, 2007, 20:43
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,761
Blog Entries: 1
Thanks: 0
Thanked 18 Times in 18 Posts
Send a message via AIM to moojoo Send a message via MSN to moojoo Send a message via Yahoo to moojoo
Re: Why should I validate CSS?

well filter is for IE, opacity for everything else. Really if you think about it IE should be updated to the correct opacity handler =)
__________________
The internet is just a fad.
http://www.mevans76.com
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #10 (permalink)  
Old May 9th, 2007, 12:48
spinal007's Avatar
Moderator
Join Date: Mar 2004
Location: Good Ol'London
Age: 22
Posts: 1,620
Blog Entries: 1
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via ICQ to spinal007 Send a message via MSN to spinal007 Send a message via Yahoo to spinal007 Send a message via Skype™ to spinal007
Re: Why should I validate CSS?

But then, what about FF's "-moz-property".
I've got to admit I'm guilty of this one. It's invalid CSS, but soooo handy...
input{ -moz-border-radius:3px }
Last Blog Entry: Random String in Javascript (Apr 21st, 2008)
Reply With Quote
  #11 (permalink)  
Old May 9th, 2007, 15:11
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,761
Blog Entries: 1
Thanks: 0
Thanked 18 Times in 18 Posts
Send a message via AIM to moojoo Send a message via MSN to moojoo Send a message via Yahoo to moojoo
Re: Why should I validate CSS?

css 3 also has corner-radius ugh.. heh. Maybe in 10 years.
__________________
The internet is just a fad.
http://www.mevans76.com
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #12 (permalink)  
Old May 9th, 2007, 18:37
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Why should I validate CSS?

Maybe in ten years Apple will have taken over the world and had every PC and copy of Windows destroyed. That would be nice.
Reply With Quote
  #13 (permalink)  
Old May 11th, 2007, 04:27
Reputable Member
Join Date: Dec 2005
Location: Texas
Age: 19
Posts: 328
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to daygon Send a message via MSN to daygon Send a message via Yahoo to daygon
Re: Why should I validate CSS?

Isnt IE Microsoft? Theres your problem. I hate pc now that ive switched to mac. I wish everone had the money to afford a mac to experience true beauty. We love you Steve Jobs!
Reply With Quote
  #14 (permalink)  
Old May 11th, 2007, 14:24
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,761
Blog Entries: 1
Thanks: 0
Thanked 18 Times in 18 Posts
Send a message via AIM to moojoo Send a message via MSN to moojoo Send a message via Yahoo to moojoo
Re: Why should I validate CSS?

heh, haha, tee hee. Woo! I think one rendering engine should be used. Gecko while good is a bloated beast, IE's engine is bleh, Opera's engine is good but still different from gecko and KHTML, KHTML is good but the same. Heck even different OS X browsers even though mostly they use Webkit display things differently, i.e. Omniweb vs Safari (Although Omniweb is uber fast and pretty.)
__________________
The internet is just a fad.
http://www.mevans76.com
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
Reply

Tags
css, validation, w3c

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
trying to validate css Phixon Web Page Design 12 Oct 2nd, 2007 20:44
Attempt to validate Phixon Web Page Design 11 Jul 24th, 2007 14:25
Why wont it Validate R8515198 Web Page Design 12 Jul 4th, 2007 17:01
Getting flash to validate? newoptical Flash & Multimedia Forum 3 Jun 29th, 2007 21:51
validate form? Nick JavaScript Forum 10 Aug 31st, 2004 07:47


All times are GMT. The time now is 21:24.


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