Margin and Padding Shorthand

post-thumb

One of the most common attributes in CSS are margin and padding, while there use isn't that big it certainly helps a website's content look clean and spaced out. Margins create certain amounts of spacing between almost anything on a webpage and can be used to seperate divs. Padding of course is most commonly used to space out divs, paragraphs and general content so everything isn't jumbled up and wrap up within each other so it is clear to the reader. Like many CSS attributes margin and padding have shorthand versions of themselves. In this CSS tricks and tips tutorials you'll learn how you can save time by using shorthand with your margins and padding.

« Read the rest of this post

Optimising CSS code

post-thumb

When coding CSS there are many properties that you can optimise, doing this can also save time on defining attributes that can be optimised within on attribute in the first place, having this knowledge can help you with your CSS as well, saving space on your stylesheets and even in some cases speed up page loading times!

« Read the rest of this post

Removing the annoying bottom scrollbar in a browser

post-thumb

In a browser window you will have two ways of scrolling the webpage content that is produced, using a vertical scroll bar also known as the y-axis scrollbar and the horizontal scrollbar also known as the x-axis (Sort of like the axis on a typical two axis graph) Depending on how a website is designed you may or may not see it, and sometimes it has been forced to appear as maybe that certain website needs it to function properly. But for some of you out there you may think "Ugh whats this annoying scrollbar doing here" and no matter how many widths you change it's determined to stay Well with this CSS Hack/Trick you will be able to hide that annoying horizontal scroll bar with a simple CSS code.

« Read the rest of this post

Common XHTML tags defined in CSS

post-thumb

To make your life alot easier you can define the common XHTML tags you use on your webpages within your Stylesheet, doing this can define a certain tag globally and you'll never have to modify it within your XHTML again! In this tutorial we will show you the XHTML tags you can define in CSS! If your just getting into CSS then this will be perfect knowledge for you later on, as you may already be coding stuff in your XHTML pages when infact you could simply define it in one stylesheet and be done with it!

« Read the rest of this post

CSS Hack: Making div’s appear on the same line

post-thumb

In this tutorial I will show you how you can force two or more div's to be on the same line without any form invalid XHTML/CSS appied. This tutorial is a must if you have features like top bars on your website!

« Read the rest of this post