Some Useful Tips For CSS Beginers

Mar 12, 2013, by admin

Here I Have Given Some Useful Tips for CSS beginners were given below i hope it will be usefull

 

  • Proper class names: 
  • If you’re developping a stylesheet for a client or for some sort of public distribution, I forbid you to call your classes and IDs generic, non-descript names like .t121-2. Use proper names like .sidebar-container
  •  Class and ID
  • These two selectors often confuse beginners. In CSS, class is represented by a dot “.” whileid is a hash ‘#”. In a nutshell id is used on style that is unique and don’t repeat itself, classon the other side, can be re-use.

  • User reset.csc
  • When it comes to rendering CSS styles, browsers like Firefox and Internet Explorer have different ways of handling them. reset.css resets all fundamental styles, so you starts with a real blank new stylesheets.

  • Forget <Table>, Try <Div>
  • One of the greatest advantage of CSS is the use of <div> to achieve total flexibility in terms of styling. <div> are unlike <table>, where contents are ‘locked’ within a <td>‘s cell. It’s safe to say most <table> layouts are achievable with the use of <div> and proper styling, well maybe except massive tabular contents.

    • CSS Debugging Tools

      It’s always good to get instant preview of the layout while tweaking the CSS, it helps understanding and debugging CSS styles better. Here are some free CSS debugging tools you can install on your browser: FireFox Web DeveloperDOM InspectorInternet Explorer Developer Toolbar, and Firebug.

       

       

      I hope that the above tips will be useful see you in next post