now with added Masterweb and IB Geek Girl

spider web Ecanus•net :: Code Snippets

My favourite code snippets

These are just some of the code snippets I couldn't live without. Okay, so maybe, I could live without them – they're not like air or food or anything, but they're the code snippets I use most often, and the ones that make life easier for me. I've tried to group them into logical groups – HTML (and XHTML), CSS, and PHP. I hope you find them useful.

These are just a few of my favourite ones. I'll be adding more as soon as I get a chance. Click the links below to see the snippets.

CSS

Starting off with a level playing field

CSS: *, body { margin: 0; padding: 0; border: 0; height:101%; font-size:100.01%; }

Placed right at the beginning of the stylesheet, this style rule removes the default margins, padding, and borders added by browsers, and ensures that badly behaved browsers play nice.