Sponsored by Dragon Age: Origins
Follow the Dragon Age: Origins development team on Twitter view!
twitter.com/DragonAge - EA presents BioWare's new dark fantasy epic Dragon Age: Origins. '9/10' from Game Informer.
89 Comments
- phosphor112, on 02/19/2009, -5/+43# 1 - 5
Don't use Dreamweaver. - AlanFang, on 02/19/2009, -4/+40This will be the only comment not adding tips #6, 7, 8, 9 etc.
- tgc1, on 02/19/2009, -1/+34As both a designer and developer, i'm sure most in the industry would agree that the single biggest pain in the ass browser is ALWAYS Internet Exploder... 'er I mean Explorer. ***** thing sucks!
- TwinHelix, on 02/19/2009, -7/+396. Don't be afraid of seperate IE6 & IE7 stylesheets
7. Take 5 minute breaks every half-hour
8. Practice
9. Make Mistakes
10. Turn mistakes into lessons
11. Innovate- Less cookie cutter, more cookie mix. - Dysl3xicDog, on 02/19/2009, -1/+186. Learn how to use all of firebug.
- Nouman6, on 02/19/2009, -1/+18CSS is actually really easy for anyone scared to jump in.
some people do go overboard with comments and organization which is why I just do it my way, and CSS/HTML Tidy later. - MelvinSchlubman, on 02/19/2009, -0/+15Are you also immune to the laws of physics?
- kurrent, on 02/19/2009, -3/+172. Alphabetize......really? Most elements have what...4 or 5 declarations on average? 4 declarations is too much that it needs to be sorted so you can find it faster?
10-15 declarations, okay maybe i could live with that. And if you have more than 20 declarations in a style, then i encourage you to lookup "css shorthand". - Dysl3xicDog, on 02/19/2009, -2/+15Actually I build some pretty complex sites and don't use any IE hacks to do it. If coded properly your site should look very similar in all browsers.
- PhairOh, on 02/19/2009, -1/+14This may be true for simple public web pages, but for complex corporate web applications, this is just false.
- dullnation, on 02/19/2009, -2/+14Internet explorer is *not* a very accommodating browser. When everything looks perfect in Firefox, it generally looks like ass in IE without hacks coming out of your ass.
- magneteye, on 02/18/2009, -13/+246. cocaine
but really, some good points. thx. - alpha88, on 02/19/2009, -1/+11"they just go too far. I feel like you end up resetting everything, and then redefining a lot of properties on the elements"
Uh.. yeah. That's the point, hence the name "reset". You reset everything then define what you WANT. That's why it prevents errors. - prodigitalson, on 02/19/2009, -0/+9Ritalin or Adderall are better than coke if you need to bust out a marathon session. More focus, less craziness - and you dont have to keep going back for more to maintain the stimulus. A little harder to find though. I also find about 300-500mg of a caffeine/guarana mixture have roughly the same effect for 3-4 hours.
The importance of cigarettes cannot be overstated. - Recoil, on 02/19/2009, -1/+10I disagree with his idea of alphabetizing, I'd much rather order things after their context. That way you know that the most important things are usually found at the beginning, and if you're looking for anything related to graphics you'll find them all neatly stuck together in one place. I'll definitely look into this "reset" concept more, though.
- flexyournoggin, on 02/19/2009, -1/+9I think the best #6 would be to validate everything
- woofers07, on 02/19/2009, -3/+11Actually with at least intermediate knowledge, Dreamweaver can sometimes increase productivity. But if you're not proficient they yeah, stay the hell away.
- louiebaur, on 02/18/2009, -0/+7Cocaine?
- dalectrics, on 02/18/2009, -0/+7Hmmm Cocaine and CSS, dangerous!
- tablelegs, on 02/19/2009, -1/+8Meh, underwhelming. Honestly, how do you write CSS on one line? That would drive me nuts.
- pimperj, on 02/19/2009, -1/+7There is no "correct" way, everyone should use whatever suits their needs
- Oddish, on 02/19/2009, -2/+8Actually I thought that tip made no sense. "You can’t tell me that Example 2 isn’t faster."
Actually, I found the margin-right property in about the same time in each of the examples, so the first example wins, since you save time by not alphabetizing the properties. Lame tip. - WildTang3nt, on 02/19/2009, -0/+5No. You can declare one value and overwrite it later. Whichever is loaded last takes precedence.
- emecks, on 02/18/2009, -11/+16I'd never even considered alphabetising my CSS, makes so much sense though!
- Dysl3xicDog, on 02/19/2009, -1/+5I agree the alphabetize deal is just being grammar nazish. I work on 1000+ line stylesheets and don't have problems finding what I need, FIREBUG TELLS YOU WHAT LINE THE RULE STARTS ON...
- arbulus, on 02/19/2009, -0/+4Tables are for dinner.
- cmallinson, on 02/19/2009, -1/+5Sorry, I'd love to live in that world, but it simply is not the case. If the two choices are split up some of the css or compromise your design, then the choice should be obvious.
- Baryn, on 02/19/2009, -3/+7Alphabetizing is wrong.
Correct:
- Display (none, block, etc) should come first so you know immediately how this element is being handled.
- Box model properties (position, margin, padding, border, width, height) should all sit together so you can get a complete grasp of the element.
- Then, content formatting (color, fonts).
- Finally, seldom-used elements (overflow, z-index). - emptyo, on 02/19/2009, -1/+4I didn't know ANYTHING about "resetting". Glad I read that article...great idea.
Oh, and CSSEdit rules. - Hilyin, on 02/19/2009, -0/+3Learn best practices ;)
- MelvinSchlubman, on 02/19/2009, -0/+3Barack
- WildTang3nt, on 02/19/2009, -0/+3Or so you'd think...
What? Why are you all looking at me like that? - pnunn, on 02/19/2009, -0/+2On a budget, working for clients, trying to keep turnaround time short- why would you not take the 5 minutes (if even) to write a sheet for ie and a statement to load the alternate styles? 5 minutes vs. possibly 2 weeks in limbo (depending on the nature of the client and whether or not you are responding to a committee of any sort) trying to coerce a client with some sort of web purism aesthetic as opposed to the approved design? I wouldn't necessarily categorize markup that specifies browser specific styles a hack on the levels of the other things I assume you are eluding to either. Build it- get it off your desk and out to the programmer- design the next one- repeat- continue working.
- urothane, on 02/19/2009, -1/+3It would be better if I could alpha it after I write it, because I don't think alpha when setting my code and sometimes need to finagle the settings.
- betobonix, on 02/19/2009, -0/+2Alphabetizing is realy a personal style, but if you have any consideration for someone else that will edit your code in the future then keep "width" before "height", that way you keep the universal convension for declaring WIDTH x HEIGHT.
Also I consider as a good practice to keep properties for the same thing toguether in groups, such as:
font, font-weight and line-height;
position:absolute, z-index, top and left - xeomage, on 02/19/2009, -0/+2I agree, but I would note that "very similar" isn't "exactly the same".
"Exactly the same" will almost always require either a simple site (no pretty or fanciness) or at best a few "<!--[if lte IE 6]>" entries. - PReitz, on 02/19/2009, -0/+2I'm surprised no one mentioned this (and it's probably a personal preference thing), but I put different groups of styles into different files, then import them into a main file. That way if I wanted to, for example, edit the style for the navigation I would open navigation.css. This makes it real easy to find what I'm looking for. (I also have a separate folder for all the style sheets).
- Asvetic, on 02/19/2009, -0/+2This might be commonsense for most coders, but as a newbie I found this pretty insightful.
It'll definitely be easier for me to form useful habits now, versus trying to change ones that are comfortably bad and sorely ingrained. - picpak, on 02/19/2009, -0/+2Digg uses seperate stylesheets.
- norbiu, on 02/19/2009, -1/+3I can see why: http://digg.com/users/RBrenner14/gallery/6619429/p ...
Sorry dude, we can't all be both handsome and successful ... or just handsome. - FredFredrickson, on 02/19/2009, -0/+2Cocaine is a hell of a drug...
- phosphor112, on 02/20/2009, -0/+1@ woofers07
I can garuntee you most (if not all) professional web designers will not use Dreamweaver. It is a horrible program. Very little consistency when trying to edit even the slightest thing. It's like trying to use Office 07 formatting in an Office 03 program..except...for dreamweaver..its all in 1 program that you get that kind of effect. - archaxis, on 03/13/2009, -0/+1CSS is awesome but I don't get all crazy and use it like most folks do. I used to be a software tester and never enjoyed doing browser compatibility testing when all it takes is restricting yourself from using the latest and greatest version of CSS or whatever. That's why I still use Tables as my primary layout structure and then I put in CSS, my websites look the same on all browsers and I was tired of having style sheets that were larger 1000 + lines. Thank goodness for Firebug but seriously tables solve a ton of the IE problems everyone cries about.
- arbulus, on 02/19/2009, -0/+1I don't use the "design" tab. I just use the code tab and preview in browser when I need to.
And auto complete in Dreamweaver is the awesome-est thing ever. - betobonix, on 02/19/2009, -0/+1Dreamweaver destroy your HTML indent after 1 or 2 edits. If you go Dreamweaver then use the "design" tab only for visual reference and type your code in "code" tab.
- Asvetic, on 02/19/2009, -0/+1Anyone using Stylizer? http://www.skybound.ca/ Wondering if it's a worth-while PC-based CSS editor or not?
- ajcates, on 02/19/2009, -0/+1Most people keep a production and a development copy. My development copy is not neat, has comments everywhere, I use both single and multiple line decelerations etc. But when css tidy time comes around I magically follow all of the rules in the article.
- arbulus, on 02/19/2009, -0/+1CSS on one line is maddening to read. I can't stand it when people do that.
- 7aji, on 02/19/2009, -0/+1Isn't #3 conflicting with #2 ? I mean that example for #2 didn't make any sense since the margin-right property was on the same line, and then comes #3 telling you to group stuff together.
Also, what's up with big images in between every note??! - findhostcoupons, on 03/22/2009, -0/+1thanks jaybol for all top 5 tips provided in the story you submitted
-
Show 51 - 92 of 92 discussions



What is Digg?
Browsing Digg on your phone just got easier with our enhancements to the