{"id":27,"date":"2010-09-02T15:18:02","date_gmt":"2010-09-02T06:18:02","guid":{"rendered":"http:\/\/santoshkori.com\/blog\/?p=27"},"modified":"2012-08-29T20:57:48","modified_gmt":"2012-08-29T11:57:48","slug":"useful-css-snippets-for-developers","status":"publish","type":"post","link":"https:\/\/www.santoshkori.com\/blog\/useful-css-snippets-for-developers\/","title":{"rendered":"Useful CSS Snippets for Developers"},"content":{"rendered":"<p>CSS is no doubt up there with the most important web languages that we use. While html provides the structure it can be inconsistent and unpredictable across different new and old browsers. Css is where the html is styled though, and where we get creative as well as addressing those\u00a0inconsistencies. Below is a fantastic list of 25 Css snippets that I am sure you will find\u00a0extremely\u00a0useful. Whether you are a veteran web developer, or are just getting your foot in the door of css, they are all well worth checking out.<!--more--><\/p>\n<h2>Hide text with text indent<\/h2>\n<p>This is extremely useful for use for things such as your company logo. More often than not, it\u2019s an image, but you\u2019ll want to display it in h1 tags for SEO as well. Here\u2019s the best way to do so. What we basically do is hide the text far away off the screen, and apply a background image instead.<\/p>\n<div id=\"highlighter_203852\">\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>h<\/code><code>1<\/code> <code>{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>text-indent<\/code><code>:<\/code><code>-9999px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>margin<\/code><code>:<\/code><code>0<\/code> <code>auto<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>width<\/code><code>:<\/code><code>400px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>height<\/code><code>:<\/code><code>100px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>background<\/code><code>:<\/code><code>transparent<\/code> <code>url<\/code><code>(<\/code><code>\"images\/logo.jpg\"<\/code><code>) <\/code><code>no-repeat<\/code> <code>scroll<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>7<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Style links depending on file format<\/h2>\n<p>This snippet is aimed at user experience. Often on the internet we find ourself clicking on links knowing nothing about where we are heading. This snippet can be used and expanded to show small icons next to your links telling the user if it is an external link, an email, a pdf, an image, and so much more.<\/p>\n<div id=\"highlighter_568612\">\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>01<\/code><\/td>\n<td><code>\/* external links *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>02<\/code><\/td>\n<td><code>a[href^=<\/code><code>\"<a href=\"http:\/\/\/\">http:\/\/<\/a>\"<\/code><code>]{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>03<\/code><\/td>\n<td><code>padding-right<\/code><code>: <\/code><code>20px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>04<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>url<\/code><code>(external.gif) <\/code><code>no-repeat<\/code> <code>center<\/code> <code>right<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>05<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>06<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>07<\/code><\/td>\n<td><code>\/* emails *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>08<\/code><\/td>\n<td><code>a[href^=<\/code><code>\"mailto:\"<\/code><code>]{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>09<\/code><\/td>\n<td><code>padding-right<\/code><code>: <\/code><code>20px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>10<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>url<\/code><code>(email.png) <\/code><code>no-repeat<\/code> <code>center<\/code> <code>right<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>11<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>12<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>13<\/code><\/td>\n<td><code>\/* pdfs *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>14<\/code><\/td>\n<td><code>a[href$=<\/code><code>\".pdf\"<\/code><code>]{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>15<\/code><\/td>\n<td><code>padding-right<\/code><code>: <\/code><code>20px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>16<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>url<\/code><code>(pdf.png) <\/code><code>no-repeat<\/code> <code>center<\/code> <code>right<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>17<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Remove textarea scrollbar in IE<\/h2>\n<p>Internet Explorer has an annoying habit of adding scrollbars to textarea\u2019s even when the textarea\u2019s content is not overflowing. You can rectify this flaw with this easy to use snippet.<\/p>\n<div id=\"highlighter_19242\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_19242_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_19242\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_19242_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_19242\" wmode=\"transparent\">\u00a0<\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>textarea{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>overflow<\/code><code>:<\/code><code>auto<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Drop cap<\/h2>\n<p>Commonplace these days in blogs and news sites is the dropcap. You\u2019d be surprised at how easy it is to implement, and how well it degrades for older browsers.<\/p>\n<div id=\"highlighter_814925\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_814925_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_814925\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_814925_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_814925\" wmode=\"transparent\">\u00a0<\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>p:first-letter{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>display<\/code><code>:<\/code><code>block<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>margin<\/code><code>:<\/code><code>5px<\/code> <code>0<\/code> <code>0<\/code> <code>5px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>float<\/code><code>:<\/code><code>left<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>color<\/code><code>:<\/code><code>#FF3366<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>font-size<\/code><code>:<\/code><code>60px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>7<\/code><\/td>\n<td><code>font-family<\/code><code>:Georgia;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>8<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Css Transparency<\/h2>\n<p>Transparency is something that isn\u2019t done the same way across browsers which can be annoying. Here\u2019s how you can target transparency in multiple browsers.<\/p>\n<div id=\"highlighter_170818\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_170818_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_170818\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_170818_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_170818\" wmode=\"transparent\">\u00a0<\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.<\/code><code>transparent<\/code> <code>{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>filter:alpha(opacity=<\/code><code>50<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>-moz-opacity:<\/code><code>0.5<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>-khtml-opacity: <\/code><code>0.5<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>opacity: <\/code><code>0.5<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Css Reset by Eric Meyer<\/h2>\n<p>Eric Meyer\u2019s css reset has become almost standard now days for use at the start of your stylesheet. Having been adopted by some of the most influential designers, you can be sure of its quality.<\/p>\n<div id=\"highlighter_739041\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_739041_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_739041\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_739041_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_739041\" wmode=\"transparent\">\u00a0<\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>01<\/code><\/td>\n<td><code>html, body, div, span, applet, object, iframe,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>02<\/code><\/td>\n<td><code>h<\/code><code>1<\/code><code>, h<\/code><code>2<\/code><code>, h<\/code><code>3<\/code><code>, h<\/code><code>4<\/code><code>, h<\/code><code>5<\/code><code>, h<\/code><code>6<\/code><code>, p, blockquote, <\/code><code>pre<\/code><code>,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>03<\/code><\/td>\n<td><code>a, abbr, acronym, address, big, cite, <\/code><code>code<\/code><code>,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>04<\/code><\/td>\n<td><code>del, dfn, em, font, img, ins, kbd, q, s, samp,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>05<\/code><\/td>\n<td><code>small<\/code><code>, strike, strong, <\/code><code>sub<\/code><code>, sup, tt, var,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>06<\/code><\/td>\n<td><code>b, u, i, <\/code><code>center<\/code><code>,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>07<\/code><\/td>\n<td><code>dl, dt, dd, ol, ul, li,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>08<\/code><\/td>\n<td><code>fieldset, form, label, legend,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>09<\/code><\/td>\n<td><code>table, <\/code><code>caption<\/code><code>, tbody, tfoot, thead, tr, th, td {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>10<\/code><\/td>\n<td><code>margin<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>11<\/code><\/td>\n<td><code>padding<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>12<\/code><\/td>\n<td><code>border<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>13<\/code><\/td>\n<td><code>outline<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>14<\/code><\/td>\n<td><code>font-size<\/code><code>: <\/code><code>100%<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>15<\/code><\/td>\n<td><code>vertical-align<\/code><code>: <\/code><code>baseline<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>16<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>transparent<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>17<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>18<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>19<\/code><\/td>\n<td><code>body {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>20<\/code><\/td>\n<td><code>line-height<\/code><code>: <\/code><code>1<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>21<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>22<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>23<\/code><\/td>\n<td><code>ol, ul {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>24<\/code><\/td>\n<td><code>list-style<\/code><code>: <\/code><code>none<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>25<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>26<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>27<\/code><\/td>\n<td><code>blockquote, q {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>28<\/code><\/td>\n<td><code>quotes<\/code><code>: <\/code><code>none<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>29<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>30<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>31<\/code><\/td>\n<td><code>blockquote:before, blockquote:after,<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>32<\/code><\/td>\n<td><code>q:before, q:after {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>33<\/code><\/td>\n<td><code>content<\/code><code>: <\/code><code>''<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>34<\/code><\/td>\n<td><code>content<\/code><code>: <\/code><code>none<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>35<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>36<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>37<\/code><\/td>\n<td><code>\/* remember to define focus styles! *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>38<\/code><\/td>\n<td><code>:focus {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>39<\/code><\/td>\n<td><code>outline<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>40<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>41<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>42<\/code><\/td>\n<td><code>\/* remember to highlight inserts somehow! *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>43<\/code><\/td>\n<td><code>ins {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>44<\/code><\/td>\n<td><code>text-decoration<\/code><code>: <\/code><code>none<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>45<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>46<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>47<\/code><\/td>\n<td><code>del {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>48<\/code><\/td>\n<td><code>text-decoration<\/code><code>: <\/code><code>line-through<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>49<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>50<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>51<\/code><\/td>\n<td><code>\/* tables still need 'cellspacing=\"0\"' in the markup *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>52<\/code><\/td>\n<td><code>table {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>53<\/code><\/td>\n<td><code>border-collapse<\/code><code>: <\/code><code>collapse<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>54<\/code><\/td>\n<td><code>border-spacing<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>55<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Image preloader<\/h2>\n<p>Sometimes it is useful to pre-load your images so that when a certain element is needed, they\u2019ll already be loaded for you and there wont be any delay or flickering.<\/p>\n<div id=\"highlighter_528271\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_528271_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_528271\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_528271_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_528271\" wmode=\"transparent\">\u00a0<\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>div.loader{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>background<\/code><code>:<\/code><code>url<\/code><code>(images\/hover.gif) <\/code><code>no-repeat<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>background<\/code><code>:<\/code><code>url<\/code><code>(images\/hover<\/code><code>2<\/code><code>.gif) <\/code><code>no-repeat<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>background<\/code><code>:<\/code><code>url<\/code><code>(images\/hover<\/code><code>3<\/code><code>.gif) <\/code><code>no-repeat<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>margin-left<\/code><code>:<\/code><code>-10000px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Basic css sprite button<\/h2>\n<p>Having a button or link with a background image is fairly normal, and nowadays, we require further effects to enhance the user experience. Once of this is an indicator to the user that they are hovering over a button. Using a sprite, we can create this effect by changing the position of the background image down a certain height to show the background to the button on hover. A simple yet effective technique.<\/p>\n<div id=\"highlighter_484589\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_484589_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_484589\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_484589_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_484589\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>01<\/code><\/td>\n<td><code>a {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>02<\/code><\/td>\n<td><code>display<\/code><code>: <\/code><code>block<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>03<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>url<\/code><code>(sprite.png) <\/code><code>no-repeat<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>04<\/code><\/td>\n<td><code>height<\/code><code>: <\/code><code>30px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>05<\/code><\/td>\n<td><code>width<\/code><code>: <\/code><code>250px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>06<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>07<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>08<\/code><\/td>\n<td><code>a:hover {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>09<\/code><\/td>\n<td><code>background-position<\/code><code>: <\/code><code>0<\/code> <code>-30px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>10<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Google Font API<\/h2>\n<p>Google recently released a fantastic resource for web designers allowing them to load new fonts from google for use in our web pages. We can even load different variants of fonts such as bold, italic and so on. While the library of fonts available from google is limited, there is still plenty to use. First include the dynamically written stylesheet by naming the fonts and variants you want, and then use the font names in your css as you normally would! For further info on <a href=\"http:\/\/code.google.com\/apis\/webfonts\/\" target=\"_blank\" rel=\"noopener\">Google Font API, read here.<\/a><\/p>\n<div id=\"highlighter_737593\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_737593_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_737593\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_737593_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_737593\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>&lt;<\/code><code>head<\/code><code>&gt;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>Inconsolata:italic|Droid+Sans\"&gt;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>&lt;\/<\/code><code>head<\/code><code>&gt;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<div id=\"highlighter_664716\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_664716_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_664716\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_664716_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_664716\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>body {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>font-family<\/code><code>: <\/code><code>'Tangerine'<\/code><code>, <\/code><code>'Inconsolata'<\/code><code>, <\/code><code>'Droid Sans'<\/code><code>, <\/code><code>serif<\/code><code>; <\/code><code>font-size<\/code><code>: <\/code><code>48px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Browser specific hacks<\/h2>\n<p>Sometimes it\u2019s useful to target specific browsers to fix their inconsistencies and conditional comments aren\u2019t always the best way to do so. This list of css browser hacks by Chris Coyier is a top-notch list of ways to target browsers with simple css.<\/p>\n<div id=\"highlighter_221843\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_221843_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_221843\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_221843_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_221843\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>01<\/code><\/td>\n<td><code>\/* IE 6 *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>02<\/code><\/td>\n<td><code>* html .yourclass { }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>03<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>04<\/code><\/td>\n<td><code>\/* IE 7 *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>05<\/code><\/td>\n<td><code>*+html .yourclass{ }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>06<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>07<\/code><\/td>\n<td><code>\/* IE 7 and modern browsers *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>08<\/code><\/td>\n<td><code>html&gt;body .yourclass { }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>09<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>10<\/code><\/td>\n<td><code>\/* Modern browsers (not IE 7) *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>11<\/code><\/td>\n<td><code>html&gt;<\/code><code>\/**\/<\/code><code>body .yourclass { }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>12<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>13<\/code><\/td>\n<td><code>\/* Opera 9.27 and below *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>14<\/code><\/td>\n<td><code>html:first-child .yourclass { }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>15<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>16<\/code><\/td>\n<td><code>\/* Safari *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>17<\/code><\/td>\n<td><code>html[xmlns*=<\/code><code>\"\"<\/code><code>] body:last-child .yourclass { }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>18<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>19<\/code><\/td>\n<td><code>\/* Safari 3+, Chrome 1+, Opera 9+, Fx 3.5+ *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>20<\/code><\/td>\n<td><code>body:nth-of-type(<\/code><code>1<\/code><code>) .yourclass { }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>21<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>22<\/code><\/td>\n<td><code>\/* Safari 3+, Chrome 1+, Opera 9+, Fx 3.5+ *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>23<\/code><\/td>\n<td><code>body:first-of-type .yourclass {\u00a0 }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>24<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>25<\/code><\/td>\n<td><code>\/* Safari 3+, Chrome 1+ *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>26<\/code><\/td>\n<td><code>@media <\/code><code>screen<\/code> <code>and (-webkit-min-device-pixel-ratio:<\/code><code>0<\/code><code>) {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>27<\/code><\/td>\n<td><code>.yourclass\u00a0 {\u00a0 }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>28<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Fixed Footer<\/h2>\n<p>You would think creating a footer that sticks to the bottom of the screen would be rather hard, but surprisingly it isn\u2019t if you want to start with a basic footer. There is an IE6 hack we have to use, but apart from that, it\u2019s easy!<\/p>\n<div id=\"highlighter_804670\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_804670_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_804670\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_804670_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_804670\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>01<\/code><\/td>\n<td><code>#footer {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>02<\/code><\/td>\n<td><code>position<\/code><code>:<\/code><code>fixed<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>03<\/code><\/td>\n<td><code>left<\/code><code>:<\/code><code>0px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>04<\/code><\/td>\n<td><code>bottom<\/code><code>:<\/code><code>0px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>05<\/code><\/td>\n<td><code>height<\/code><code>:<\/code><code>30px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>06<\/code><\/td>\n<td><code>width<\/code><code>:<\/code><code>100%<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>07<\/code><\/td>\n<td><code>background<\/code><code>:<\/code><code>#999<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>08<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>09<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>10<\/code><\/td>\n<td><code>\/* IE 6 *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>11<\/code><\/td>\n<td><code>* html #footer {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>12<\/code><\/td>\n<td><code>position<\/code><code>:<\/code><code>absolute<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>13<\/code><\/td>\n<td><code>top<\/code><code>:expression((<\/code><code>0<\/code><code>-(footer.offsetHeight)+(document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body.clientHeight)+(ignoreMe = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop))+<\/code><code>'px'<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>14<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Flip an image<\/h2>\n<p>Flipping an image rather than just loading a new image that is already reversed can be rather useful. Say you want to use only one image for an arrow, but have several on the page going in different directions. Here\u2019s your problem solved.<\/p>\n<div id=\"highlighter_488221\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_488221_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_488221\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_488221_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_488221\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>img.flip {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>-moz-transform: scaleX(<\/code><code>-1<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>-o-transform: scaleX(<\/code><code>-1<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>-webkit-transform: scaleX(<\/code><code>-1<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>transform: scaleX(<\/code><code>-1<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>filter: FlipH;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>7<\/code><\/td>\n<td><code>-ms-filter: <\/code><code>\"FlipH\"<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>8<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Clearfix<\/h2>\n<p>A while back, someone decided it was time to clear floated elements without adding any extra markup to the document. They did this by creating a class that can be applied to the container of floated children to clear it. A fantastic way to do so, and something that is nowadays, widely used.<\/p>\n<div id=\"highlighter_782792\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_782792_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_782792\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_782792_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_782792\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>01<\/code><\/td>\n<td><code>.clearfix:after {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>02<\/code><\/td>\n<td><code>visibility<\/code><code>: <\/code><code>hidden<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>03<\/code><\/td>\n<td><code>display<\/code><code>: <\/code><code>block<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>04<\/code><\/td>\n<td><code>font-size<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>05<\/code><\/td>\n<td><code>content<\/code><code>: <\/code><code>\" \"<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>06<\/code><\/td>\n<td><code>clear<\/code><code>: <\/code><code>both<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>07<\/code><\/td>\n<td><code>height<\/code><code>: <\/code><code>0<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>08<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>09<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>10<\/code><\/td>\n<td><code>.clearfix { <\/code><code>display<\/code><code>: inline-<\/code><code>block<\/code><code>; }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>11<\/code><\/td>\n<td>\u00a0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>12<\/code><\/td>\n<td><code>\/* start commented backslash hack *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>13<\/code><\/td>\n<td><code>* html .clearfix { <\/code><code>height<\/code><code>: <\/code><code>1%<\/code><code>; }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>14<\/code><\/td>\n<td><code>.clearfix { <\/code><code>display<\/code><code>: <\/code><code>block<\/code><code>; }<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>15<\/code><\/td>\n<td><code>\/* close commented backslash hack *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Rounded Corners<\/h2>\n<p>With the slow introduction of css3, rounded corners have been made easily possibly in modern browsers. Sadly we still don\u2019t have css3 support for IE, but it will be available in IE9 whenever that is released.<\/p>\n<div id=\"highlighter_639369\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_639369_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_639369\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_639369_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_639369\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.round{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>-moz-border-radius: <\/code><code>10px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>-webkit-border-radius: <\/code><code>10px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>border-radius: <\/code><code>10px<\/code><code>; <\/code><code>\/* future proofing *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>-khtml-border-radius: <\/code><code>10px<\/code><code>; <\/code><code>\/* for old Konqueror browsers *\/<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Style Overriding<\/h2>\n<p>It still surprises me that some people don\u2019t know about !important in css, because it is such a powerful and useful tool to have. Basically, any rule with !important at the end, will override any of the same rule that is applied to that element wherever it appears in the css file, or in-line html.<\/p>\n<div id=\"highlighter_792497\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_792497_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_792497\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_792497_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_792497\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>p{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>font-size<\/code><code>:<\/code><code>20px<\/code> <code>!important<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Font face<\/h2>\n<p>Font-face didn\u2019t really break through until late last year, but has been around since the days of IE6 being a modern browser! It\u2019s picked up in support a lot now though, and offers a great way to use non web safe fonts in your web projects. While this snippet works, you might as well save your time by using the <a href=\"http:\/\/www.fontsquirrel.com\/fontface\/generator\" target=\"_blank\" rel=\"noopener\">Font Squirrel Font Face Generator.<\/a><\/p>\n<div id=\"highlighter_306316\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_306316_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_306316\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_306316_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_306316\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>@font-face {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>font-family<\/code><code>: <\/code><code>'Graublau Web'<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>src<\/code><code>: <\/code><code>url<\/code><code>(<\/code><code>'GraublauWeb.eot'<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>src<\/code><code>: <\/code><code>local<\/code><code>(<\/code><code>'\u263a'<\/code><code>),<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>url<\/code><code>(<\/code><code>'GraublauWeb.woff'<\/code><code>) <\/code><code>format<\/code><code>(<\/code><code>'woff'<\/code><code>), <\/code><code>url<\/code><code>(<\/code><code>'GraublauWeb.ttf'<\/code><code>) <\/code><code>format<\/code><code>(<\/code><code>'truetype'<\/code><code>);<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Center a website<\/h2>\n<p>A common design trend these days is for your website to center itself in the middle of browser\u2019s viewport horizontally. This is an easily achievable thing to do.<\/p>\n<div id=\"highlighter_672941\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_672941_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_672941\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_672941_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_672941\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.wrapper {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>width<\/code><code>:<\/code><code>960px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>margin<\/code><code>:<\/code><code>0<\/code> <code>auto<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Min-height in IE<\/h2>\n<p>This comes down to fixing a simple, yet annoying bug in IE\u2019s capability of handling min-height. In essence, IE interprets height as min-height, so since IE wont implement the auto height, this snippet will fix all this for us.<\/p>\n<div id=\"highlighter_591462\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_591462_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_591462\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_591462_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_591462\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.box {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>min-height<\/code><code>:<\/code><code>500px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>height<\/code><code>:<\/code><code>auto<\/code> <code>!important<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>height<\/code><code>:<\/code><code>500px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Image loading<\/h2>\n<p>This image loading effects mimics that of an ajax loader, where a loading circle is displayed while content loads. This works especially well for larger, slower loading images, and is css only!<\/p>\n<div id=\"highlighter_227744\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_227744_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_227744\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_227744_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_227744\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>img {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>url<\/code><code>(loader.gif) no\u2212<\/code><code>repeat<\/code> <code>50%<\/code> <code>50%<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Vertical Center<\/h2>\n<p>This short snippet allows you to vertically center the contents of a container without any extra markup by simply displaying it as a table cell which then allows you to use the vertical-align attribute.<\/p>\n<div id=\"highlighter_154683\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_154683_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_154683\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_154683_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_154683\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.container {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>min-height<\/code><code>: <\/code><code>10em<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>display<\/code><code>: <\/code><code>table-cell<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>vertical-align<\/code><code>: <\/code><code>middle<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Create pullquotes<\/h2>\n<p>Firstly, what is a pullquote? Well in news and magazine style websites, you\u2019ll often notice small quotes added within the article, not as full blockquotes, but as small quotes that sit within the article but to the side, sometimes adding things such as people\u2019s opinions or quotes. They are extremely easy to create you\u2019ll be glad to know, and when used properly, can add greatly to the user experience when reading an article.<\/p>\n<div id=\"highlighter_686815\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_686815_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_686815\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_686815_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_686815\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.pullquote {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>width<\/code><code>: <\/code><code>300px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>float<\/code><code>: <\/code><code>right<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>margin<\/code><code>: <\/code><code>5px<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>font-family<\/code><code>: Georgia, <\/code><code>\"Times New Roman\"<\/code><code>, Times, <\/code><code>serif<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>font<\/code><code>: <\/code><code>italic<\/code> <code>bold<\/code> <code>#ff0000<\/code> <code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>7<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Text Selection<\/h2>\n<p>Some people are unaware that it is possible to change the color when you highlight text in your browser. It is so easy to with two selectors; just be careful you don\u2019t ruin your site with it.<\/p>\n<div id=\"highlighter_119154\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_119154_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_119154\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_119154_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_119154\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>::selection {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>color<\/code><code>: <\/code><code>#000000<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>3<\/code><\/td>\n<td><code>background-color<\/code><code>: <\/code><code>#FF0000<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>4<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>5<\/code><\/td>\n<td><code>::-moz-selection {<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>6<\/code><\/td>\n<td><code>color<\/code><code>: <\/code><code>#000000<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>7<\/code><\/td>\n<td><code>background<\/code><code>: <\/code><code>#FF0000<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>8<\/code><\/td>\n<td><code>}<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<\/div>\n<h2>Print page breaks<\/h2>\n<p>This add\u2019s again to the user experience when printing. For example, when printing an article, it may be useful for a user to have the comments on a new page from the article itself. by adding this class to the comments area, a page break will appear when printing. It can be used anywhere else on your site as well!<\/p>\n<div id=\"highlighter_911447\">\n<div>\n<div><a title=\"view source\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#viewSource\" target=\"_blank\" rel=\"noopener\">view source<\/a><\/div>\n<div><object id=\"highlighter_911447_clipboard\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" width=\"16\" height=\"16\" codebase=\"http:\/\/download.macromedia.com\/pub\/shockwave\/cabs\/flash\/swflash.cab#version=6,0,40,0\"><param name=\"flashvars\" value=\"highlighterId=highlighter_911447\" \/><param name=\"src\" value=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" \/><param name=\"wmode\" value=\"transparent\" \/><embed id=\"highlighter_911447_clipboard\" type=\"application\/x-shockwave-flash\" width=\"16\" height=\"16\" src=\"http:\/\/www.1stwebdesigner.com\/wp-content\/plugins\/syntaxhighlighter\/syntaxhighlighter\/scripts\/clipboard.swf\" flashvars=\"highlighterId=highlighter_911447\" wmode=\"transparent\"><\/embed><\/object><\/div>\n<p><a title=\"print\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#printSource\" target=\"_blank\" rel=\"noopener\">print<\/a><a title=\"?\" href=\"http:\/\/www.1stwebdesigner.com\/development\/useful-css-snippets\/#about\" target=\"_blank\" rel=\"noopener\">?<\/a><\/p>\n<\/div>\n<div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>1<\/code><\/td>\n<td><code>.page-break{<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody>\n<tr>\n<td><code>2<\/code><\/td>\n<td><code>page-break-before<\/code><code>:<\/code><code>always<\/code><code>;<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<table>\n<tbody<\/table>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>CSS is no doubt up there with the most important web languages that we use. While html provides the structure it can be inconsistent and unpredictable across different new and old browsers. Css is where the html is styled though, and where we get creative as well as addressing those\u00a0inconsistencies. Below is a fantastic list [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,14,5,4],"tags":[379,378,738,737,333],"class_list":["post-27","post","type-post","status-publish","format-standard","hentry","category-cross-browser-compatibility","category-web-development","category-wordpress","category-xhtml-coding","tag-mumbai-web-developer","tag-mumbai-website-designer","tag-web-designer","tag-web-developer","tag-website-development"],"_links":{"self":[{"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/posts\/27","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/comments?post=27"}],"version-history":[{"count":4,"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/posts\/27\/revisions"}],"predecessor-version":[{"id":793,"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/posts\/27\/revisions\/793"}],"wp:attachment":[{"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/media?parent=27"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/categories?post=27"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.santoshkori.com\/blog\/wp-json\/wp\/v2\/tags?post=27"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}