<?xml version="1.0" encoding="utf-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: The media object saves hundreds of lines of code</title>
	<atom:link href="http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/</link>
	<description>A Term of Endearment</description>
	<lastBuildDate>Mon, 07 May 2012 17:31:22 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
	<item>
		<title>By: Thierry Koblentz</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-19901</link>
		<dc:creator>Thierry Koblentz</dc:creator>
		<pubDate>Wed, 01 Jun 2011 22:38:45 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-19901</guid>
		<description>Hi Nicole,

Fwiw, I&#039;d not use the term &quot;clearfix&quot; to describe the styling of these elements. I think for most people &quot;clearfix&quot; is a method that clears floats via hasLayout in IE and via a pseudo-selector in modern browsers. 
But such styling does *not* create a block formatting context across the board (only in IE lt 8 ) which is very different than what you do here - where the styling is the same across browsers.</description>
		<content:encoded><![CDATA[<p>Hi Nicole,</p>
<p>Fwiw, I&#8217;d not use the term &#8220;clearfix&#8221; to describe the styling of these elements. I think for most people &#8220;clearfix&#8221; is a method that clears floats via hasLayout in IE and via a pseudo-selector in modern browsers.<br />
But such styling does *not* create a block formatting context across the board (only in IE lt 8 ) which is very different than what you do here &#8211; where the styling is the same across browsers.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul Irish</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-19897</link>
		<dc:creator>Paul Irish</dc:creator>
		<pubDate>Tue, 31 May 2011 23:55:37 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-19897</guid>
		<description>Necolas made a nice demo of this technique I wanted to keep a reference to: http://jsfiddle.net/necolas/rZvEF/</description>
		<content:encoded><![CDATA[<p>Necolas made a nice demo of this technique I wanted to keep a reference to: <a href="http://jsfiddle.net/necolas/rZvEF/" rel="nofollow">http://jsfiddle.net/necolas/rZvEF/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: High Performance CSS code design &#124; Eddie Welker.com</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-19551</link>
		<dc:creator>High Performance CSS code design &#124; Eddie Welker.com</dc:creator>
		<pubDate>Wed, 06 Apr 2011 05:46:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-19551</guid>
		<description>[...] frequently on the Facebook site is something she has coined a &#8220;Media Block,&#8221; which she defines as &#8220;an image to the left, with descriptive content to the right.&#8221;  Simply put, this is [...]</description>
		<content:encoded><![CDATA[<p>[...] frequently on the Facebook site is something she has coined a &#8220;Media Block,&#8221; which she defines as &#8220;an image to the left, with descriptive content to the right.&#8221;  Simply put, this is [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kiko Doran</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-18354</link>
		<dc:creator>Kiko Doran</dc:creator>
		<pubDate>Tue, 04 Jan 2011 05:25:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-18354</guid>
		<description>Nicole,
It seems to make more sense to me that the img class is put on the image instead of on the link.  It seems more reusable that way because all my images will be images but they won&#039;t all be anchor links.  

I&#039;ve messed with it both ways and it seems to work my way just fine but I&#039;m wondering if there is a downside to doing it this way.  I will now defer to the master... 

Thanks,
Kiko</description>
		<content:encoded><![CDATA[<p>Nicole,<br />
It seems to make more sense to me that the img class is put on the image instead of on the link.  It seems more reusable that way because all my images will be images but they won&#8217;t all be anchor links.  </p>
<p>I&#8217;ve messed with it both ways and it seems to work my way just fine but I&#8217;m wondering if there is a downside to doing it this way.  I will now defer to the master&#8230; </p>
<p>Thanks,<br />
Kiko</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nicole Sullivan</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-15701</link>
		<dc:creator>Nicole Sullivan</dc:creator>
		<pubDate>Mon, 29 Nov 2010 19:13:53 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-15701</guid>
		<description>@Patrick - I don&#039;t know if there will be an image inside. It could be a sprite which just has a background image on a link or span. So I apply the float and margin to the piece that is always there.</description>
		<content:encoded><![CDATA[<p>@Patrick &#8211; I don&#8217;t know if there will be an image inside. It could be a sprite which just has a background image on a link or span. So I apply the float and margin to the piece that is always there.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Patrick</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-15692</link>
		<dc:creator>Patrick</dc:creator>
		<pubDate>Wed, 17 Nov 2010 00:15:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-15692</guid>
		<description>Nicole, what is the benefit of applying the margin and float to the wrapper, instead of simply the image itself?
I tried doing so, and noticed no difference in the layout in any browser.

.media .img {float:left; margin-right: 10px;}
.media .img img{display:block;}</description>
		<content:encoded><![CDATA[<p>Nicole, what is the benefit of applying the margin and float to the wrapper, instead of simply the image itself?<br />
I tried doing so, and noticed no difference in the layout in any browser.</p>
<p>.media .img {float:left; margin-right: 10px;}<br />
.media .img img{display:block;}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nicole Sullivan</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-15585</link>
		<dc:creator>Nicole Sullivan</dc:creator>
		<pubDate>Thu, 26 Aug 2010 14:20:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-15585</guid>
		<description>@Ron Derksen - it gets a new formatting context via mod.css. http://github.com/stubbornella/oocss/blob/master/core/module/mod.css#L10-11

This is the key to it not needing a ton of extra classes for different sized images. I haven&#039;t written about this method of creating a new formatting context (yet!), but you can check out the overflow method in this post: http://www.stubbornella.org/content/2009/07/23/overflow-a-secret-benefit/</description>
		<content:encoded><![CDATA[<p>@Ron Derksen &#8211; it gets a new formatting context via mod.css. <a href="http://github.com/stubbornella/oocss/blob/master/core/module/mod.css#L10-11" rel="nofollow">http://github.com/stubbornella/oocss/blob/master/core/module/mod.css#L10-11</a></p>
<p>This is the key to it not needing a ton of extra classes for different sized images. I haven&#8217;t written about this method of creating a new formatting context (yet!), but you can check out the overflow method in this post: <a href="http://www.stubbornella.org/content/2009/07/23/overflow-a-secret-benefit/" rel="nofollow">http://www.stubbornella.org/content/2009/07/23/overflow-a-secret-benefit/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ron Derksen</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-15584</link>
		<dc:creator>Ron Derksen</dc:creator>
		<pubDate>Thu, 26 Aug 2010 12:41:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-15584</guid>
		<description>Nicole, when the text in the body gets too long, it will wrap below the image. Shouldn&#039;t the .bd element be floated or get a margin to prevent this?</description>
		<content:encoded><![CDATA[<p>Nicole, when the text in the body gets too long, it will wrap below the image. Shouldn&#8217;t the .bd element be floated or get a margin to prevent this?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chad Hietala</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-15581</link>
		<dc:creator>Chad Hietala</dc:creator>
		<pubDate>Tue, 24 Aug 2010 17:52:22 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-15581</guid>
		<description>Wow.  This is great.  I&#039;m in process of turning all my components that have this layout into media objects.</description>
		<content:encoded><![CDATA[<p>Wow.  This is great.  I&#8217;m in process of turning all my components that have this layout into media objects.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nicole Sullivan</title>
		<link>http://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/comment-page-1/#comment-15494</link>
		<dc:creator>Nicole Sullivan</dc:creator>
		<pubDate>Thu, 12 Aug 2010 18:10:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.stubbornella.org/content/?p=497#comment-15494</guid>
		<description>@Dmitri - I&#039;m glad I helped you catch up on CSS. I can&#039;t use first-child because &lt;a href=&quot;http://www.quirksmode.org/css/contents.html#t17&quot; rel=&quot;nofollow&quot;&gt;support for it is pretty poor in IE&lt;/a&gt;. I would use pseudo classes for table decoration an other purely presentational aspects, but for something essential like this, the fallback isn&#039;t reasonable. Support for the child-node selector, &quot;&gt;&quot; is also not great. I can&#039;t wait until older browsers get retired, for now, I&#039;m using this selector for decoration only.</description>
		<content:encoded><![CDATA[<p>@Dmitri &#8211; I&#8217;m glad I helped you catch up on CSS. I can&#8217;t use first-child because <a href="http://www.quirksmode.org/css/contents.html#t17" rel="nofollow">support for it is pretty poor in IE</a>. I would use pseudo classes for table decoration an other purely presentational aspects, but for something essential like this, the fallback isn&#8217;t reasonable. Support for the child-node selector, &#8220;>&#8221; is also not great. I can&#8217;t wait until older browsers get retired, for now, I&#8217;m using this selector for decoration only.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Served from: www.stubbornella.org @ 2012-05-16 18:46:49 by W3 Total Cache -->
