SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Wizard
    Join Date
    Jan 2005
    Location
    blahblahblah
    Posts
    1,447
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    coming to CSS after an 18 months pause. What has changed?

    Hi,

    I'm back on using CSS and I would like to know as far as "best practice" what prevails nowadays.

    1. Do people still use hacks? I guess yes, but when I left there were discussions about dropping ie5 hacks.

    2. How has cross-browser designed evolved?

    3. What is the current best approach to multiple cols layouts? Still floats?

    4. What "best practice advice" would you give to someone like me, who knows the "language", but who must comes back into the game?

    Regards,

    -jj

  2. #2
    SitePoint Wizard wonshikee's Avatar
    Join Date
    Jan 2007
    Posts
    1,223
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    ie7 improved the standards abit, but still sux. That is all..

  3. #3
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,281
    Mentioned
    179 Post(s)
    Tagged
    6 Thread(s)
    Hi,

    1) In answer to question 1 then the answer is that most people are using a more structured approach to hacks and hack management. However the only browser that needs hacking for is IE really as that is the only browser that can be reliably targeted by hacks.

    All other browsers should not be hacked for and seldom need it anyway. Any problems can usually be overcome with a small change in design.

    Conditional comments can be used for IE to provide a 100% safe hack management system. However you should keep the hacks to a bare minimum and once "haslayout" is understood there are very few hacks needed. IE7 is much better than ie6 but does have a few haslayout issues still but it is a big improvement on ie6.

    Most of the hacks people used are because of their bad coding and mis-understanding how css works. using the right code at the right time will result in minimum use of hacks.

    2)Good designers use a more professional approach and check their designs as they code in at least 4 browsers during each stage of development (safari,IE,Firefox,opera). It is no good designing for one browser then expecting it to be perfect in others as it is often then too late. You must check each step of the way and then you don't build on a feature that doesn't exist in other browsers.

    I have 4 browsers open all the time and check the page at every stage. It only takes a couple of seconds but saves hours in the long run.

    3) Floats are still the best option for columnar layouts and work well There are advanced techniques using negative margins that can create some very complex and interesting layouts but the concepts need to be understood fully.

    4)If you are coming back after a layout them make sure you understand how css works and understand which property you need to use and why you are using it.

    CSS professionals must understand the tools of the trade just like learning any language. Learning the language also means learning the bad language and catering for browser shortcomings is simply part and parcel of the job.

    Best practices these days include global reset techniques.Using semantic html instead of just using divs and spans when other more semantic elements are available. Using a structured and logical approach to stylesheets and hack management.

    Basically all the things that people should have been doing from the start

  4. #4
    SitePoint Enthusiast
    Join Date
    Oct 2007
    Posts
    42
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Paul O'B View Post
    ...There are advanced techniques using negative margins that can create some very complex and interesting layouts but the concepts need to be understood fully...
    What are these advanced techniques? Are they described anywhere?

    Thanks
    Rasmus

  5. #5
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,281
    Mentioned
    179 Post(s)
    Tagged
    6 Thread(s)
    Quote Originally Posted by Rasmus
    What are these advanced techniques? Are they described anywhere?
    Yes here


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •