<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>boolean.co.nz &#187; CSS</title>
	<atom:link href="http://boolean.co.nz/blog/category/development/css/feed/" rel="self" type="application/rss+xml" />
	<link>http://boolean.co.nz/blog</link>
	<description>Where there is more to logic than TRUE or FALSE</description>
	<lastBuildDate>Fri, 18 May 2012 09:56:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Making a CSS div behave like a link</title>
		<link>http://boolean.co.nz/blog/making-a-css-div-behave-like-a-link/610/</link>
		<comments>http://boolean.co.nz/blog/making-a-css-div-behave-like-a-link/610/#comments</comments>
		<pubDate>Mon, 29 Aug 2011 02:56:52 +0000</pubDate>
		<dc:creator>Boolean</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://boolean.co.nz/blog/?p=610</guid>
		<description><![CDATA[The requirements were that Javascript shouldn&#8217;t be necessary (bad SEO and accessibility) and that the HTML had to validate. For some examples have a look at Facebook advertisements. Here is how it was done: Create the div as normal using HTML and CSS. In the div you will need to place the link you are [...]]]></description>
			<content:encoded><![CDATA[<table>
<tr>
<td><img src="http://boolean.co.nz/blog/wp-content/uploads/2009/04/css_logo.png" alt="" title="css_logo" width="126" height="114" class="aligncenter size-full wp-image-75" /></td>
</tr>
</table>
<p>The requirements were that Javascript shouldn&#8217;t be necessary (bad SEO and accessibility) and that the HTML had to validate. For some examples have a look at Facebook advertisements. Here is how it was done:</p>
<ul>
<li>Create the div as normal using HTML and CSS. In the div you will need to place the link you are wanting to be accessible.</li>
<li>Inside that link you will need an empty span tag.</li>
<li>Make sure that the div is styled in CSS with position:relative</li>
<li>Apply the following style to the empty span tag:</li>
</ul>
<div class="codesnip-container" >{ position:absolute;<br />
width:100%;<br />
height:100%;<br />
top:0;<br />
left: 0;<br />
z-index: 1 }</div>
<p>Any other links you may have inside the div will require position:relative and a suitable z-index (greater than 1)</p>
]]></content:encoded>
			<wfw:commentRss>http://boolean.co.nz/blog/making-a-css-div-behave-like-a-link/610/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Understanding CSS Class and ID</title>
		<link>http://boolean.co.nz/blog/understanding-css-class-and-id/131/</link>
		<comments>http://boolean.co.nz/blog/understanding-css-class-and-id/131/#comments</comments>
		<pubDate>Thu, 07 May 2009 15:44:26 +0000</pubDate>
		<dc:creator>Boolean</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://boolean.co.nz/blog/?p=131</guid>
		<description><![CDATA[Often these selectors can confuse beginners. In CSS a class is represented by a dot &#8220;.&#8221; while an id is a hash &#8220;#&#8221;. Simply put an id is used on a unique style that doesnt repeat whilst a class can be re-used. Often it can be hard to decide where to use a class versus [...]]]></description>
			<content:encoded><![CDATA[<table>
<tr>
<td>
<img src="http://boolean.co.nz/blog/wp-content/uploads/2009/04/css_logo.png" alt="css_logo" title="css_logo" width="126" height="114" class="aligncenter size-full wp-image-75" />
</td>
</tr>
</table>
<p>Often these selectors can confuse beginners.  In CSS a class is represented by a dot &#8220;.&#8221; while an id is a hash &#8220;#&#8221;.  Simply put an id is used on a unique style that doesnt repeat whilst a class can be re-used.</p>
<p>Often it can be hard to decide where to use a class versus an id for an element</p>
<p><strong>Use a class tag if: </strong></p>
<p>1.The style is used in various places throughout the document.<br />
2.The style is very general.</p>
<p><strong>Use an id tag if: </strong></p>
<p>1.The style is only used once ever in the document.<br />
2.The style is specific to a certain area of the document.</p>
<p>Remember that an id can only appear once in any HTML document. Once you&#8217;ve used that id it should not be used again on that page.</p>
]]></content:encoded>
			<wfw:commentRss>http://boolean.co.nz/blog/understanding-css-class-and-id/131/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Replace text with an image using CSS</title>
		<link>http://boolean.co.nz/blog/replace-text-with-an-image-using-css/71/</link>
		<comments>http://boolean.co.nz/blog/replace-text-with-an-image-using-css/71/#comments</comments>
		<pubDate>Thu, 02 Apr 2009 08:20:44 +0000</pubDate>
		<dc:creator>Boolean</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://boolean.co.nz/blog/?p=71</guid>
		<description><![CDATA[A quick little way to do this (whilst still degrading and being kind to screen readers) h1 { text-indent:-9999px; background:url(&#8220;heading.jpg&#8221;) no-repeat; width:100px; height:50px; How it works: text-indent:-9999px; relocates the text title off screen, replacing it by an image declared by background: {&#8230;} utilising a fixed width and height.]]></description>
			<content:encoded><![CDATA[<table>
<tr>
<td>
<img src="http://boolean.co.nz/blog/wp-content/uploads/2009/04/css_logo.png" alt="css_logo" title="css_logo" width="126" height="114" class="aligncenter size-full wp-image-75" />
</td>
</tr>
</table>
<p>A quick little way to do this (whilst still degrading and being kind to screen readers)</p>
<div class="codesnip-container" >h1 {<br />
text-indent:-9999px;<br />
background:url(&#8220;heading.jpg&#8221;) no-repeat;<br />
width:100px;<br />
height:50px;</div>
<p><strong>How it works:</strong> text-indent:-9999px; relocates the text title off screen, replacing it by an image declared by background: {&#8230;} utilising a fixed width and height.</p>
]]></content:encoded>
			<wfw:commentRss>http://boolean.co.nz/blog/replace-text-with-an-image-using-css/71/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

