<?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>ReDsgn &#187; XHTML</title>
	<atom:link href="http://www.redsgn.com/category/xhtml/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.redsgn.com</link>
	<description>When small things come together great things happen.</description>
	<lastBuildDate>Tue, 10 Nov 2009 04:15:01 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Damn that IE, how to target Internet Explorer for CSS, Content and Scripts</title>
		<link>http://www.redsgn.com/2009/06/30/damn-that-ie-how-to-target-internet-explorer-for-css-content-and-scripts/</link>
		<comments>http://www.redsgn.com/2009/06/30/damn-that-ie-how-to-target-internet-explorer-for-css-content-and-scripts/#comments</comments>
		<pubDate>Tue, 30 Jun 2009 04:18:15 +0000</pubDate>
		<dc:creator>Paul Boutin</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[XHTML]]></category>
		<category><![CDATA[conditional comments]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.redsgn.com/?p=391</guid>
		<description><![CDATA[We were once sold on the Idea that we needed true CSS hacks to make stuff work in IE we were also sold on browser detection with JavaScript for other content.
Conditional comments can do more than allow you to serve up different CSS for specific versions you can use conditional comments for just about any type of content you want to exclude or include for various versions. Conditional comments work in IE versions 5 and newer. You can be as specific as you need to like IE 5.01 and 5.5.]]></description>
			<content:encoded><![CDATA[<p>We were once sold on the Idea that we needed true CSS hacks to make stuff work in IE we were also sold on browser detection with JavaScript for other content.</p>
<p>I have been using conditional comments for years now and this may seem like old news to some, To others this is refresher.</p>
<p>Conditional comments can do more than allow you to serve up different CSS for specific versions you can use conditional comments for just about any type of content you want to exclude or include for various versions. Conditional comments work in IE versions 5 and newer. You can be as specific as you need to like IE 5.01 and 5.5.<span id="more-391"></span></p>
<p>The syntax is simple&#8230;<br />
&lt;!- -[if IE 6]&gt;<br />
Special instructions for IE 6 here<br />
&lt;![endif]- -&gt;<br />
Variations are as follows&#8230;<br />
[if IE]<br />
[if IE 7]<br />
[if gte IE 5]<br />
[if lt IE 6]<br />
[if lte IE 5.5]<br />
[if gt IE 6]<br />
[if !IE]<br />
[if !(IE 7)]<br />
[if (gt IE 5)&amp;(lt IE 7)]<br />
[if (IE 6)|(IE 7)]</p>
<p>All standard comments are wrapped in &lt;!- &#8211; and &#8211; -&gt;<br />
All conditional comments fall within a standard comment and have an if block wrapped in square brackets [if ] [endif]</p>
<ul>
<li>!: not equal</li>
<li>&amp;: and</li>
<li>|: or</li>
<li>gt: greater than</li>
<li>gte: greater than or equal to</li>
<li>lt: less than</li>
<li>lte: less than or equal to</li>
</ul>
<p>They are just comments to all other browsers and just like comments they can be anywhere comments can be&#8230; in the Head or body. Places these comments don&#8217;t work are inside CSS files or script files.</p>
<p>to server up diff CSS for IE you can either use embedded CSS as in &lt;style type=&#8221;text/css&#8221;&gt;&lt;/style&gt; or link to an external CSS file as in &lt;link type=&#8221;text/css&#8221; rel=&#8221;stylesheet&#8221; media=&#8221;all&#8221; href=&#8221;#&#8221; /&gt;</p>
<p>Same for script files&#8230;<br />
&lt;script type=&#8221;text/javascript&#8221;&gt;&lt;/script&gt; or &lt;script type=&#8221;text/javascript&#8221; src=&#8221;#&#8221;&gt;&lt;/script&gt;</p>
<p>IE also has a JScript version of this for using inside JavaScript files.</p>
<p>/*@cc_on @*/<br />
/*@if (@_win32)<br />
IE specific JavaScript goes here.<br />
/*@end @*/</p>
]]></content:encoded>
			<wfw:commentRss>http://www.redsgn.com/2009/06/30/damn-that-ie-how-to-target-internet-explorer-for-css-content-and-scripts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fixing those bleeding backgrounds on fieldsets</title>
		<link>http://www.redsgn.com/2009/02/19/fixing-those-bleeding-backgrounds-on-fieldsets/</link>
		<comments>http://www.redsgn.com/2009/02/19/fixing-those-bleeding-backgrounds-on-fieldsets/#comments</comments>
		<pubDate>Thu, 19 Feb 2009 15:33:12 +0000</pubDate>
		<dc:creator>Paul Boutin</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[XHTML]]></category>
		<category><![CDATA[Bug]]></category>
		<category><![CDATA[Fieldset]]></category>

		<guid isPermaLink="false">http://www.redsgn.com/?p=162</guid>
		<description><![CDATA[Ever encounter this IE bug&#8230; The issue occurs when you style fieldsets with a background color. The top of the fieldset color will bleed out of the border to the top of the legend. IE pads to the outside of borders and its apparent here when the padding is increased to accommodate a legend which [...]]]></description>
			<content:encoded><![CDATA[<p>Ever encounter this IE bug&#8230; The issue occurs when you style fieldsets with a background color. The top of the fieldset color will bleed out of the border to the top of the legend. IE pads to the outside of borders and its apparent here when the padding is increased to accommodate a legend which is over the border of the fieldset.</p>
<p><img src="http://www.redsgn.com/wp-content/uploads/2009/02/ie-fieldset-bleed-300x156.gif" alt="ie fieldset bleed" width="300" height="156" class="size-medium wp-image-325" /></p>
<p>This is a simple fix that will work in all browsers so no need for special IE Hacks or Conditional Comments.</p>
<p>First add a position: relative; declaration to the fieldset rule so that the absolute positioning of the legend will be relative to its fieldset:</p>
<p><code>fieldset {<br />
position: relative;<br />
background: #ffffcc;<br />
}</code></p>
<p>Next, add a new rule for the legend element and set its absolute positioning properties to emulate its current position:</p>
<p><code>legend {<br />
position: absolute;<br />
top: -.7em;<br />
left: .2em;<br />
}</code></p>
<p>That&#8217;s it&#8230; That&#8217;s all there is to it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.redsgn.com/2009/02/19/fixing-those-bleeding-backgrounds-on-fieldsets/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Semantic Rounded Corners</title>
		<link>http://www.redsgn.com/2008/11/24/semantic-rounded-corners/</link>
		<comments>http://www.redsgn.com/2008/11/24/semantic-rounded-corners/#comments</comments>
		<pubDate>Mon, 24 Nov 2008 16:35:25 +0000</pubDate>
		<dc:creator>Paul Boutin</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[XHTML]]></category>
		<category><![CDATA[Rounded Corners]]></category>
		<category><![CDATA[Semantic]]></category>
		<category><![CDATA[Sliding Doors]]></category>
		<category><![CDATA[Styling Headers]]></category>

		<guid isPermaLink="false">http://www.redsgn.com/?p=127</guid>
		<description><![CDATA[In today&#8217;s modern web design Rounded corners are the new trend. So in keeping up with the trend we need to accommodate new designs with our current markup. In this post I will show you how to take any four containers of markup and convert them into a semantic rounded corner display. This technique will [...]]]></description>
			<content:encoded><![CDATA[<p>In today&#8217;s modern web design Rounded corners are the new trend. So in keeping up with the trend we need to accommodate new designs with our current markup. In this post I will show you how to take any four containers of markup and convert them into a semantic rounded corner display. This technique will be fluid and accommodate text size changes. (Tested in IE 6 and 7 and Firefox 3) If this works in other browsers please let me know.</p>
<p>This technique uses the <a href="http://www.alistapart.com/articles/slidingdoors/">Sliding Doors of CSS</a> technique described by <a href="http://www.alistapart.com/authors/b/douglasbowman">Douglas Bowman</a> on <a href="http://www.alistapart.com/">A List Apart</a>.</p>
<p>We need 4 containers or elements we can apply style to, to define the four corners we want to round. Here you see I&#8217;m using an h4 tag as my outer container and nesting inside it two spans one for the header text and one for a link or anchor point. With the inclusion of our anchor tag we now have our four elements.</p>
<p><code>&lt;h4&gt;&lt;span class="title"&gt;H4 Demo Title 2&lt;/span&gt;&lt;span class="link"&gt;&lt;a href="edit_link.htm" title="edit"&gt;Edit&lt;/a&gt;&lt;/span&gt;&lt;/h4&gt;<br />
</code></p>
<p><code>&lt;h4&gt;&lt;span class="title"&gt;H4 Demo Title&lt;/span&gt;&lt;span class="link"&gt;&lt;a name="anchor"&gt;&amp;nbsp;&lt;/a&gt;&lt;/span&gt;&lt;/h4&gt;<br />
</code></p>
<p>The markup may seem a bit overkill in this example but I tend to always design for the future. In my original markup I wanted to allow for Graphic headers as well as edit links in my headers. But as you can see in my second example the edit link can be used as a legacy anchor. No matter how you split it up the goal here is to have semantic markup in the end not a bunch of meaningless wrapper divs. I will get into using wrapper containers in a later post.</p>
<p><span id="more-127"></span></p>
<p>I have created my corners in a graphical editor. I used gif&#8217;s for their transparency and browser support. The corners are transparent on the inside of the corner and have the background color of the page on the outside of the corner. Doing this allows me to style the background of the object that is being rounded with any color and not have to recreate the corner images every time I want to change the styling. Here are the images as I have made them. 
<a href='http://www.redsgn.com/2008/11/24/semantic-rounded-corners/corner-bl/' title='corner-bl'><img width="4" height="4" src="http://www.redsgn.com/wp-content/uploads/2008/11/corner-bl.gif" class="attachment-thumbnail" alt="Bottom Left Corner" title="corner-bl" /></a>
<a href='http://www.redsgn.com/2008/11/24/semantic-rounded-corners/corner-tr/' title='corner-tr'><img width="4" height="4" src="http://www.redsgn.com/wp-content/uploads/2008/11/corner-tr.gif" class="attachment-thumbnail" alt="Top Right Corner" title="corner-tr" /></a>
<a href='http://www.redsgn.com/2008/11/24/semantic-rounded-corners/corner-br/' title='corner-br'><img width="4" height="4" src="http://www.redsgn.com/wp-content/uploads/2008/11/corner-br.gif" class="attachment-thumbnail" alt="Bottom Right Corner" title="corner-br" /></a>
<a href='http://www.redsgn.com/2008/11/24/semantic-rounded-corners/corner-tl/' title='corner-tl'><img width="4" height="4" src="http://www.redsgn.com/wp-content/uploads/2008/11/corner-tl.gif" class="attachment-thumbnail" alt="Top Left Corner" title="corner-tl" /></a>
</p>
<p>Ok so now lets style it&#8230;</p>
<p><code>h4 {<br />
background:#E3E3E3 url(corner-TL.gif) no-repeat scroll 0 0;<br />
font-size:1.1em;<br />
height:5ex;<br />
position:relative;<br />
}<br />
</code></p>
<p>I set the background color on the outer container and position the background (in this case the Top Left corner,) image to the top left and set it to no repeat. I set the position to relative so I can use absolute positioning for the rest of the corners. I also set the height here to accommodate the text so I used ex which is 1/2 em in browser calculations. see my post on <a href="http://www.redsgn.com/2008/11/15/calculating-ems/">calculating ems</a> for more info. (Note: Elements when positioned absolute are removed from the document flow causing the parent containers to collapse as if they have no contents.)</p>
<p><code>h4 span.title {<br />
background:transparent url(corner-BL.gif) no-repeat scroll 0 100%;<br />
bottom:0;<br />
display:block;<br />
left:0;<br />
padding:0 0 10px 10px;<br />
position:absolute;<br />
}<br />
</code></p>
<p>Here I set the Bottom left corner position in the background property and set the position to absolute with a bottom and left of zero. Its important to note that our background color is set to transparent here because all of the absolute positioned elements inside the first container sit on top and I don&#8217;t want to hide the background image of its container element. The padding is set to space in my text 10px from the left and bottom of the container. I set the display to block and any inline element so it holds its padding.</p>
<p><code>h4 span.link {<br />
background:transparent url(corner-TR.gif) no-repeat scroll 100% 0;<br />
display:block;<br />
height:5ex;<br />
padding:0 10px;<br />
position:absolute;<br />
right:0;<br />
top:0;<br />
}<br />
</code></p>
<p>Here I set the top Right corner nothing different and pad in the text 10px. I set the height to the same height we used for the container. Since this container has no content (child elements when positioned absolute are removed from the document flow causing the parent containers to collapse) we set the padding to accommodate the corner image and the height to accommodate the anchor tag.</p>
<p><code>h4 span.link a {<br />
background:transparent url(corner-BR.gif) no-repeat scroll 100% 100%;<br />
bottom:0;<br />
display:block;<br />
font-size:0.7em;<br />
font-weight:normal;<br />
padding:0 10px 10px 0;<br />
position:absolute;<br />
right:0;<br />
}<br />
</code></p>
<p>In this last piece we set the Bottom Right corner and pad in the text from the right and bottom. I reduced the font size for the link so it does not compete with the header text. Set the padding here to 10px to accommodate the corner image and spacing in the text from the bottom and right.</p>
<h4>The Results</h4>
<h4 class="titlebar"><span class="title">H4 Demo Title 1</span><span class="link"><a href="#" title="edit">Edit</a></span></h4>
<h4 class="titlebar"><span class="title">H4 Demo Title 2</span><span class="link"><a name="demo2" id="demo2">&nbsp;</a></span></h4>
]]></content:encoded>
			<wfw:commentRss>http://www.redsgn.com/2008/11/24/semantic-rounded-corners/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Beautiful Print Style Ordered Lists using a simple CSS Technique</title>
		<link>http://www.redsgn.com/2008/11/21/beautiful-print-style-ordered-lists-using-a-simple-css-technique/</link>
		<comments>http://www.redsgn.com/2008/11/21/beautiful-print-style-ordered-lists-using-a-simple-css-technique/#comments</comments>
		<pubDate>Fri, 21 Nov 2008 18:34:56 +0000</pubDate>
		<dc:creator>Paul Boutin</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[XHTML]]></category>
		<category><![CDATA[Ordered Lists]]></category>
		<category><![CDATA[Styling]]></category>

		<guid isPermaLink="false">http://www.redsgn.com/?p=98</guid>
		<description><![CDATA[This is a simple technique for creating large heading style list numbers while maintaining normal text sizes in the content of my list.
The Problem: HTML Lists don&#8217;t allow you to style the list counters separate form the contents of the list.
Here is the markup for my Ordered List. (note the span tag that wraps the [...]]]></description>
			<content:encoded><![CDATA[<p>This is a simple technique for creating large heading style list numbers while maintaining normal text sizes in the content of my list.</p>
<p><strong>The Problem:</strong> HTML Lists don&#8217;t allow you to style the list counters separate form the contents of the list.</p>
<p>Here is the markup for my Ordered List. (note the span tag that wraps the content&#8230; this is important)</p>
<p><code>&lt;ol&gt;<br />
&lt;li&gt;&lt;span&gt;&lt;strong&gt;Intro&lt;/strong&gt; description. &lt;/span&gt;&lt;/li&gt;<br />
&lt;li&gt;&lt;span&gt;&lt;strong&gt;Intro&lt;/strong&gt; description. &lt;/span&gt;&lt;/li&gt;<br />
&lt;li&gt;&lt;span&gt;&lt;strong&gt;Intro&lt;/strong&gt; description. &lt;/span&gt;&lt;/li&gt;<br />
&lt;/ol&gt;</code></p>
<p>The basic Idea here is to overcome the limitations of styling the list numbers separate from the content. In order to accomplish this I use the span tag to wrap the content.</p>
<p>Now for the CSS</p>
<p><code>ol {<br />
color:#225E8A;<br />
font-size:1.5em;<br />
font-weight:900;<br />
}<br />
ol li span {<br />
color:#696969;<br />
font-size:0.7em;<br />
font-weight:normal;<br />
}</code></p>
<h3>Whats going on?</h3>
<p>I am setting the color and size of the font on the &#8220;ol&#8221; element, to a 1.5em larger size from its parent size (the body) and making it bold and blue. This will style the list numbers <em>and</em> the content. Now I need to reset the content of my list items to use a smaller font of regular color and weight. To do this I simply style the span that is wrapping the content to a smaller size and normal color and weight.</p>
<p>I use a .7em here to say I want to make my font .7em of its parent size which was 1.5em larger than my base size. So if my body font size is 12px, 1.5em makes my &#8220;ol&#8221; font size 18px. Now I want to re-size my lists content font to roughly 12px, so .7em of the &#8220;ol&#8221; font size (18px) we will get 12.6px. (A closer number would be .67em.) I am also resetting the color and weight to match the rest of the page text.</p>
<h3>Example</h3>
<div id="page-content">
<ol>
<li><span><strong>Intro</strong> description. </span></li>
<li><span><strong>Intro</strong> description. </span></li>
<li><span><strong>Intro</strong> description. </span></li>
</ol>
</div>
<p>for more information read my other post on <a href="hhttp://www.redsgn.com/2008/11/15/calculating-ems/">Calculating ems</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.redsgn.com/2008/11/21/beautiful-print-style-ordered-lists-using-a-simple-css-technique/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Calculating ems</title>
		<link>http://www.redsgn.com/2008/11/15/calculating-ems/</link>
		<comments>http://www.redsgn.com/2008/11/15/calculating-ems/#comments</comments>
		<pubDate>Sat, 15 Nov 2008 04:21:05 +0000</pubDate>
		<dc:creator>Paul Boutin</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[XHTML]]></category>
		<category><![CDATA[Calculating Ems]]></category>
		<category><![CDATA[Ems]]></category>

		<guid isPermaLink="false">http://www.redsgn.com/?p=120</guid>
		<description><![CDATA[This isn&#8217;t the actual way ems are measured in typography, Most browsers assume 1 em is equal to the calculated font size. For example, if the base font was 11px, then 1em would be 11px, 2em = 22px, etc.
As an example, set a div font size to 10px (use a contrasting background color), zero out [...]]]></description>
			<content:encoded><![CDATA[<p>This isn&#8217;t the actual way ems are measured in typography, Most browsers assume 1 em is equal to the calculated font size. For example, if the base font was 11px, then 1em would be 11px, 2em = 22px, etc.</p>
<p>As an example, set a div font size to 10px (use a contrasting background color), zero out the border and padding, and then set the width to 100em. It should equal 1000px exactly.</p>
<p>The accurate method to convert a true typographic em is to use a capitol M&#8217;s width to calculate the em size. It&#8217;s the same method for calculating the en and ex units. Most browsers just treat en and ex as one-half em.</p>
<p>calculated: 1em == 2en == 2ex</p>
]]></content:encoded>
			<wfw:commentRss>http://www.redsgn.com/2008/11/15/calculating-ems/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
