<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:blogChannel="http://backend.userland.com/blogChannelModule" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:pingback="http://madskills.com/public/xml/rss/module/pingback/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="1.0">
  <id>http://nothingisalotofsomething.com/</id>
  <title>Nothing Is a Lot of Something</title>
  <updated>2009-03-19T18:55:31+00:00</updated>
  <link href="http://nothingisalotofsomething.com/" />
  
  <link rel="alternate" href="http://feeds.feedburner.com/NothingIsALotOfSomething" />
  <subtitle>Sententia Sidus</subtitle>
  <author>
    <name>Jason</name>
  </author>
  <generator uri="http://dotnetblogengine.net/" version="1.0.0.0">BlogEngine.Net Syndication Generator</generator>
  <blogChannel:blogRoll>http://nothingisalotofsomething.com/opml.axd</blogChannel:blogRoll>
  <blogChannel:blink>http://www.dotnetblogengine.net/syndication.axd</blogChannel:blink>
  <dc:creator>Jason</dc:creator>
  <dc:description>Sententia Sidus</dc:description>
  <dc:language>en-US</dc:language>
  <dc:title>Nothing Is a Lot of Something</dc:title>
  <geo:lat>42.305600</geo:lat>
  <geo:long>-122.871600</geo:long>
  <link rel="self" href="http://feeds.feedburner.com/NothingIsALotOfSomething" type="application/atom+xml" /><feedburner:feedFlare href="http://add.my.yahoo.com/rss?url=http%3A%2F%2Ffeeds.feedburner.com%2FNothingIsALotOfSomething" src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif">Subscribe with My Yahoo!</feedburner:feedFlare><feedburner:feedFlare href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2FNothingIsALotOfSomething" src="http://www.newsgator.com/images/ngsub1.gif">Subscribe with NewsGator</feedburner:feedFlare><feedburner:feedFlare href="http://feeds.my.aol.com/add.jsp?url=http%3A%2F%2Ffeeds.feedburner.com%2FNothingIsALotOfSomething" src="http://o.aolcdn.com/favorites.my.aol.com/webmaster/ffclient/webroot/locale/en-US/images/myAOLButtonSmall.gif">Subscribe with My AOL</feedburner:feedFlare><feedburner:feedFlare href="http://www.bloglines.com/sub/http://feeds.feedburner.com/NothingIsALotOfSomething" src="http://www.bloglines.com/images/sub_modern11.gif">Subscribe with Bloglines</feedburner:feedFlare><feedburner:feedFlare href="http://www.netvibes.com/subscribe.php?url=http%3A%2F%2Ffeeds.feedburner.com%2FNothingIsALotOfSomething" src="http://www.netvibes.com/img/add2netvibes.gif">Subscribe with Netvibes</feedburner:feedFlare><feedburner:feedFlare href="http://fusion.google.com/add?feedurl=http%3A%2F%2Ffeeds.feedburner.com%2FNothingIsALotOfSomething" src="http://buttons.googlesyndication.com/fusion/add.gif">Subscribe with Google</feedburner:feedFlare><feedburner:feedFlare href="http://www.pageflakes.com/subscribe.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2FNothingIsALotOfSomething" src="http://www.pageflakes.com/ImageFile.ashx?instanceId=Static_4&amp;fileName=ATP_blu_91x17.gif">Subscribe with Pageflakes</feedburner:feedFlare><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com" /><entry>
    <id>http://nothingisalotofsomething.com/post/2009/03/19/Custom-Buttons-with-CSS-Sprites.aspx</id>
    <title>Custom Buttons with CSS Sprites</title>
    <updated>2009-03-19T18:52:43+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=034f2936-f091-448c-9dfe-29cd2fdb84e8" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/Iv17OECvCnc/Custom-Buttons-with-CSS-Sprites.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2009-03-19T18:52:43+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2009/03/19/Custom-Buttons-with-CSS-Sprites.aspx#comment" />
    <category term="Vortx LiveWire" />
    <category term="CSS" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=034f2936-f091-448c-9dfe-29cd2fdb84e8</pingback:target>
    <slash:comments>0</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=034f2936-f091-448c-9dfe-29cd2fdb84e8</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2009/03/19/Custom-Buttons-with-CSS-Sprites.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=034f2936-f091-448c-9dfe-29cd2fdb84e8</wfw:commentRss>
  <content type="html">&lt;div class="wlWriterEditableSmartContent" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:d08bd496-ceed-45e4-a9f1-dde90a4c6696" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;Flickr Tags: &lt;/div&gt;  &lt;p&gt;I published an article on my company’s blog about creating custom buttons using CSS sprites. &lt;a href="http://blog.vortx.com/analytics/fast-and-easy-custom-buttons/"&gt;You can view it here&lt;/a&gt;. I didn’t have the space to expand on indicating other button states with sprites, but be aware that you can apply the same technique used for the disabled styles to pseudo-classes like :active and :hover.&lt;/p&gt;&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Iv17OECvCnc:I36YBKC3IjI:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Iv17OECvCnc:I36YBKC3IjI:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=Iv17OECvCnc:I36YBKC3IjI:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Iv17OECvCnc:I36YBKC3IjI:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=Iv17OECvCnc:I36YBKC3IjI:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Iv17OECvCnc:I36YBKC3IjI:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Iv17OECvCnc:I36YBKC3IjI:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=Iv17OECvCnc:I36YBKC3IjI:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/Iv17OECvCnc" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2009/03/19/Custom-Buttons-with-CSS-Sprites.aspx</feedburner:origLink></entry>
  <entry>
    <id>http://nothingisalotofsomething.com/post/2008/07/23/WPF-MVC-FTW!.aspx</id>
    <title>WPF MVC FTW!</title>
    <updated>2008-07-23T23:18:49+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=77c13161-d48b-422a-803d-9b34cb136c53" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/Q4kQKOaX9IY/WPF-MVC-FTW!.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2008-07-23T23:18:49+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2008/07/23/WPF-MVC-FTW!.aspx#comment" />
    <category term="Design Patterns" />
    <category term="WPF" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=77c13161-d48b-422a-803d-9b34cb136c53</pingback:target>
    <slash:comments>0</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=77c13161-d48b-422a-803d-9b34cb136c53</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2008/07/23/WPF-MVC-FTW!.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=77c13161-d48b-422a-803d-9b34cb136c53</wfw:commentRss>
  <content type="html">&lt;div class="wlWriterSmartContent" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:da5c1e4c-de65-4440-a99e-ae70161f69cb" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;del.icio.us Tags: &lt;a href="http://del.icio.us/popular/wpf" rel="tag"&gt;wpf&lt;/a&gt;,&lt;a href="http://del.icio.us/popular/design+patterns" rel="tag"&gt;design patterns&lt;/a&gt;&lt;/div&gt;  &lt;p&gt;The &lt;a href="http://en.wikipedia.org/wiki/Model-view-controller"&gt;Model/View/Controller paradigm&lt;/a&gt; has been making &lt;a href="http://weblogs.asp.net/scottgu/archive/2008/07/14/asp-net-mvc-preview-4-release-part-1.aspx"&gt;big news&lt;/a&gt; in the ASP.NET development community as of late. &lt;a href="http://developer.apple.com/documentation/Cocoa/Conceptual/CocoaFundamentals/CocoaDesignPatterns/chapter_5_section_4.html"&gt;Mac programmers&lt;/a&gt; and &lt;a href="http://msdn.microsoft.com/en-us/library/4x1xy43a(VS.80).aspx"&gt;crusty old MFC devs&lt;/a&gt; may roll their eyes, but I think any attempt to draw developers’ attention to higher order design principles is laudable.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;ASP.NET may have required some finagling to get it to work in the MVC pattern, but I’ve found that WPF is perfectly aligned for MVC design. Since you’re allowed to pass POCO’s (Plain Old C# Objects) to UI elements, it’s simple as pie to separate your model from your presentation. I don’t have to worry about instantiating and initializing the right control for a particular data type; I simply define a DataTemplate for the class, and it magically uses the UI in the template wherever it sees an instance of that class.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p align="left"&gt;&lt;img title="models" style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="137" alt="models" src="http://www.nothingisalotofsomething.com/image.axd?picture=WindowsLiveWriter/WPFMVCFTW_14D80/models_3.png" width="199" align="right" border="0" /&gt; &lt;/p&gt;  &lt;p&gt;One of my recent personal projects is for managing Magic: The Gathering card collections. I created a data entry app to allow for quick entry of large collections of MTG cards. Each card comes from a set, so my models were pretty obvious. I created a library project, and added a &lt;strong&gt;Card&lt;/strong&gt; and a &lt;strong&gt;Set&lt;/strong&gt; class, as well as some support classes, to the Models namespace. As per the MVC pattern, these models are exclusively for storing data and data-related logic. They contain no UI functionality whatsoever.&lt;/p&gt;  &lt;p align="left"&gt;Now that I had my data, it was time for the UI. I decided to display the list of sets in a combo box, but I had a couple special needs. First, the cards don’t say which set they come from; instead, they show the set’s symbol, a small graphic unique to each set. I needed to display the symbols in the combo box so that the user could choose the correct set, even if they didn’t know the name. Second each set has a standard three letter abbreviation. I wanted the user to be able to type the abbreviation into the combo box to quickly select the desired set, without requiring moving the hands from keyboard to mouse.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;I set out by creating a Views folder in my Interface project. For lack of imagination, I named the views after their respective models, though there can be many views for the same model and I may find myself having to rename them later. Each view inherits from &lt;strong&gt;ViewBase &lt;/strong&gt;(itself inheriting from &lt;strong&gt;UserControl&lt;/strong&gt;), which defines a &lt;strong&gt;Model&lt;/strong&gt; dependency property and events for the &lt;strong&gt;Model&lt;/strong&gt; property changing.&lt;/p&gt;  &lt;p&gt;The set view went through several iterations to get the right data displayed in a compact space. Initially it was displaying everything from the release date to the number of cards in the set, but eventually I ended up with a very reasonable set of controls:&lt;/p&gt;  &lt;p&gt;&lt;/p&gt; &lt;style type="text/css"&gt;










.csharpcode
{
	overflow-x: scroll;
	height: auto;
	width: 100%;
}
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}

.csharpcode pre { margin: 0em; }

.csharpcode .rem { color: #008000; }

.csharpcode .kwrd { color: #0000ff; }

.csharpcode .str { color: #006080; }

.csharpcode .op { color: #0000c0; }

.csharpcode .preproc { color: #cc6633; }

.csharpcode .asp { background-color: #ffff00; }

.csharpcode .html { color: #800000; }

.csharpcode .attr { color: #ff0000; }

.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}

.csharpcode .lnum { color: #606060; }&lt;/style&gt;&lt;!-- code formatted by http://manoli.net/csharpformat/ --&gt;&lt;!-- code formatted by http://manoli.net/csharpformat/ --&gt;  &lt;div class="csharpcode"&gt;   &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Grid&lt;/span&gt; &lt;span class="attr"&gt;Margin&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;2&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;VerticalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Center&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;DataContext&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;{ Binding }&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Grid.ColumnDefinitions&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ColumnDefinition&lt;/span&gt; &lt;span class="attr"&gt;MaxWidth&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;33&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ColumnDefinition&lt;/span&gt; &lt;span class="attr"&gt;MaxWidth&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;8&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ColumnDefinition&lt;/span&gt; &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;*&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ColumnDefinition&lt;/span&gt; &lt;span class="attr"&gt;MaxWidth&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;25&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Grid.ColumnDefinitions&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Grid.RowDefinitions&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;RowDefinition&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Grid.RowDefinitions&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt; &lt;span class="attr"&gt;x:Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;lblAbbreviation&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Column&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;0&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Row&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;0&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Left&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;VerticalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Center&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Text&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;{ Binding Path=Abbreviation }&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Column&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;1&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Row&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;0&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Left&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Text&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;-&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt; &lt;span class="attr"&gt;x:Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;lblName&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Column&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;2&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Row&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;0&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Left&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;VerticalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Center&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;FontWeight&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Bold&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Text&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;{ Binding Path=Name }&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Image&lt;/span&gt; &lt;span class="attr"&gt;x:Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;imgSymbol&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Column&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;3&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Grid&lt;/span&gt;.&lt;span class="attr"&gt;Row&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;0&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Stretch&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;None&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Right&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Source&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;{ Binding Path=Symbol }&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Grid&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;Now for the magic of XAML and DataTemplate. I added a DataTemplate element to the resources for my main window:&lt;/p&gt;
&lt;!-- code formatted by http://manoli.net/csharpformat/ --&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Window.Resources&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;DataTemplate&lt;/span&gt; &lt;span class="attr"&gt;DataType&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;{x:Type Models:Set}&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Views:Set&lt;/span&gt; &lt;span class="attr"&gt;Model&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;{ Binding }&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;DataTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Window.Resources&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;Now whenever my window sees a &lt;strong&gt;Models.Set&lt;/strong&gt; object, it will substitute it with a &lt;strong&gt;Views.Set&lt;/strong&gt; control, passing in the &lt;strong&gt;Models.Set &lt;/strong&gt;as the &lt;strong&gt;Model&lt;/strong&gt; property.&lt;/p&gt;

&lt;p&gt;Next, I created my combo box with the formatting I needed:&lt;/p&gt;
&lt;!-- code formatted by http://manoli.net/csharpformat/ --&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ComboBox&lt;/span&gt; &lt;span class="attr"&gt;x:Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;cboSet&amp;quot;&lt;/span&gt; &lt;/pre&gt;

  &lt;pre&gt;          &lt;span class="attr"&gt;IsEditable&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;False&amp;quot;&lt;/span&gt; &lt;/pre&gt;

  &lt;pre class="alt"&gt;          &lt;span class="attr"&gt;IsReadOnly&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;True&amp;quot;&lt;/span&gt; &lt;/pre&gt;

  &lt;pre&gt;          &lt;span class="attr"&gt;TextSearch&lt;/span&gt;.&lt;span class="attr"&gt;TextPath&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Abbreviation&amp;quot;&lt;/span&gt; &lt;/pre&gt;

  &lt;pre class="alt"&gt;          &lt;span class="attr"&gt;HorizontalContentAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Stretch&amp;quot;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;          &lt;span class="attr"&gt;SelectionChanged&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;cboSet_SelectionChanged&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;ComboBox&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;Pretty simple stuff. The &lt;strong&gt;IsEditable&lt;/strong&gt; and &lt;strong&gt;IsReadonly&lt;/strong&gt; properties allow the user to type in the box to search the existing values (as opposed to adding new ones). The &lt;strong&gt;TextSearch.TextPath&lt;/strong&gt; tells the combo box what property of the items to compare the user’s typing to. Setting it to “Abbreviation” means when the user types, it will be compared against the three-letter set abbreviation. Remember, I’m going to assign my POCO &lt;strong&gt;Models.Set&lt;/strong&gt; class as the combo box items, not the &lt;strong&gt;Views.Set&lt;/strong&gt;. WPF will take care of displaying my &lt;strong&gt;Models.Set&lt;/strong&gt;’s as &lt;strong&gt;Views.Set&lt;/strong&gt;’s. That means any properties I’m talking about will be on the model, not the view (the way it should be!)&lt;/p&gt;

&lt;p&gt;Finally, it’s time for the big test.&lt;/p&gt;
&lt;!-- code formatted by http://manoli.net/csharpformat/ --&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;cboSet.ItemsSource = Sets;&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;Compile and run…&lt;/p&gt;

&lt;p&gt;&lt;img title="combobox" style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="436" alt="combobox" src="http://www.nothingisalotofsomething.com/image.axd?picture=WindowsLiveWriter/WPFMVCFTW_14D80/combobox_7.png" width="517" border="0" /&gt; &lt;/p&gt;

&lt;p&gt;Bingo!&lt;/p&gt;

&lt;p&gt;I applied this same process to the &lt;strong&gt;Card&lt;/strong&gt; view, as well as an internal class call &lt;strong&gt;HistoryItem&lt;/strong&gt;. In the end, I got an app that looks like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.nothingisalotofsomething.com/image.axd?picture=WindowsLiveWriter/WPFMVCFTW_14D80/mtgct_2.png"&gt;&lt;img title="MTG Collection Tracker" style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="440" alt="MTG Collection Tracker" src="http://www.nothingisalotofsomething.com/image.axd?picture=WindowsLiveWriter/WPFMVCFTW_14D80/mtgct_thumb.png" width="588" border="0" /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Q4kQKOaX9IY:5aB8E3lTMM8:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Q4kQKOaX9IY:5aB8E3lTMM8:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=Q4kQKOaX9IY:5aB8E3lTMM8:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Q4kQKOaX9IY:5aB8E3lTMM8:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=Q4kQKOaX9IY:5aB8E3lTMM8:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Q4kQKOaX9IY:5aB8E3lTMM8:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=Q4kQKOaX9IY:5aB8E3lTMM8:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=Q4kQKOaX9IY:5aB8E3lTMM8:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/Q4kQKOaX9IY" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2008/07/23/WPF-MVC-FTW!.aspx</feedburner:origLink></entry>
  <entry>
    <id>http://nothingisalotofsomething.com/post/2008/06/18/Proportional-Image-Resizing-With-XSLT.aspx</id>
    <title>Proportional Image Resizing With XSLT</title>
    <updated>2008-06-18T23:27:46+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=744dab94-a010-41dd-b991-da413a8b329f" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/DGKPyFESD8w/Proportional-Image-Resizing-With-XSLT.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2008-06-18T23:27:46+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2008/06/18/Proportional-Image-Resizing-With-XSLT.aspx#comment" />
    <category term="XSLT" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=744dab94-a010-41dd-b991-da413a8b329f</pingback:target>
    <slash:comments>1</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=744dab94-a010-41dd-b991-da413a8b329f</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2008/06/18/Proportional-Image-Resizing-With-XSLT.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=744dab94-a010-41dd-b991-da413a8b329f</wfw:commentRss>
  <content type="html">&lt;div class="wlWriterSmartContent" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:27483ca1-fa89-4fdd-a9fb-ce19eb7a5d70" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;Technorati Tags: &lt;a href="http://technorati.com/tags/xml" rel="tag"&gt;xml&lt;/a&gt;,&lt;a href="http://technorati.com/tags/xslt" rel="tag"&gt;xslt&lt;/a&gt;,&lt;a href="http://technorati.com/tags/images" rel="tag"&gt;images&lt;/a&gt;&lt;/div&gt;  &lt;p&gt;Let's say you have a bunch of different sized images that you want to constrain to some maximum dimension. You don't want to enlarge images smaller than you constraining dimension. If your limit was 150px, you might try the following:&lt;/p&gt;  &lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; background-color: #f4f4f4"&gt;   &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;     &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;img&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;src&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:value-of&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;media/thumbnail/url&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:if&lt;/span&gt; &lt;span style="color: #ff0000"&gt;test&lt;/span&gt;=&amp;quot;&lt;span style="color: #ff0000"&gt;media&lt;/span&gt;/&lt;span style="color: #ff0000"&gt;thumbnail&lt;/span&gt;/&lt;span style="color: #ff0000"&gt;width&lt;/span&gt; &lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt; 150 or media/thumbnail/height &lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt; 150 &amp;quot;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;style&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;            width: 150px; height: 150px;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:if&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;img&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;The problem with manually specifying the width and height in the style is that if the original image is not square (and most aren’t) the image will be distorted in one dimension. In order to prevent this distortion, you will need to size both dimensions by the same coefficient.&lt;/p&gt;

&lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; background-color: #f4f4f4"&gt;
  &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;
    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;img&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;src&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:value-of&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;media/thumbnail/url&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:choose&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:when&lt;/span&gt; &lt;span style="color: #ff0000"&gt;test&lt;/span&gt;=&amp;quot;&lt;span style="color: #ff0000"&gt;media&lt;/span&gt;/&lt;span style="color: #ff0000"&gt;thumbnail&lt;/span&gt;/&lt;span style="color: #ff0000"&gt;width&lt;/span&gt; &lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt; 150 and media/thumbnail/width &lt;span style="color: #ff0000"&gt;&amp;amp;gt;&lt;/span&gt;= media/thumbnail/height&amp;quot;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;width&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;                &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:value-of&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;(150 div media/thumbnail/width) * media/thumbnail/width&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;px&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;height&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;                &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:value-of&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;(150 div media/thumbnail/width) * media/thumbnail/height&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;px&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:when&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:when&lt;/span&gt; &lt;span style="color: #ff0000"&gt;test&lt;/span&gt;=&amp;quot;&lt;span style="color: #ff0000"&gt;media&lt;/span&gt;/&lt;span style="color: #ff0000"&gt;thumbnail&lt;/span&gt;/&lt;span style="color: #ff0000"&gt;height&lt;/span&gt; &lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt; 150 and media/thumbnail/width &lt;span style="color: #ff0000"&gt;&amp;amp;lt;&lt;/span&gt; media/thumbnail/height&amp;quot;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;width&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;                &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:value-of&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;(150 div media/thumbnail/height) * media/thumbnail/width&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;height&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;                &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:value-of&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;(150 div media/thumbnail/height) * media/thumbnail/height&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;            &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:attribute&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:when&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:choose&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;img&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;In this version, we use an xsl:choose to determine if the height or width is the larger dimension. If the larger dimension is greater than our maximum (again, 150px in this example), then we calculate the percentage that 150px is of that dimension; this is our coefficient. We then multiply both dimension by the coefficient to get the final size: the largest dimension will be 150px, and the smallest will be size proportionally to 150px or less.&lt;/p&gt;

&lt;p&gt;For those so inclined, here’s the sorta math:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;let m be the desired maximum dimension&lt;/p&gt;

  &lt;p&gt;let w and h be the width and height of the image respectively&lt;/p&gt;

  &lt;p&gt;L = maximum(w, h)&lt;/p&gt;

  &lt;p&gt;k = m / L&lt;/p&gt;

  &lt;p&gt;&lt;/p&gt;

  &lt;p&gt;w = w * k&lt;/p&gt;

  &lt;p&gt;h = h * k&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;em&gt;Note that in the example above, we could have simplified it by just applying the percentages directly to the image dimensions instead of taking the extra step of multiplying it by the original dimension. I just liked being able to see that it was exactly 150px in the output.&lt;/em&gt;&lt;/p&gt;&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=DGKPyFESD8w:As9rA6aceX0:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=DGKPyFESD8w:As9rA6aceX0:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=DGKPyFESD8w:As9rA6aceX0:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=DGKPyFESD8w:As9rA6aceX0:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=DGKPyFESD8w:As9rA6aceX0:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=DGKPyFESD8w:As9rA6aceX0:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=DGKPyFESD8w:As9rA6aceX0:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=DGKPyFESD8w:As9rA6aceX0:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/DGKPyFESD8w" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2008/06/18/Proportional-Image-Resizing-With-XSLT.aspx</feedburner:origLink></entry>
  <entry>
    <id>http://nothingisalotofsomething.com/post/2008/06/17/Grouping-with-XSLT.aspx</id>
    <title>Grouping with XSLT</title>
    <updated>2008-06-17T09:43:00+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=3b855a90-f52a-4a50-93d2-8d57cf16ba3a" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/J_Alt6bhBy4/Grouping-with-XSLT.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2008-06-17T09:43:00+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2008/06/17/Grouping-with-XSLT.aspx#comment" />
    <category term="XSLT" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=3b855a90-f52a-4a50-93d2-8d57cf16ba3a</pingback:target>
    <slash:comments>0</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=3b855a90-f52a-4a50-93d2-8d57cf16ba3a</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2008/06/17/Grouping-with-XSLT.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=3b855a90-f52a-4a50-93d2-8d57cf16ba3a</wfw:commentRss>
  <content type="html">&lt;p&gt;I've been working on integrating &lt;a href="http://friendfeed.com"&gt;FriendFeed&lt;/a&gt; into this site. For those who are unfamiliar with FriendFeed, it aggregates your activities across the social web and gathers them into a &lt;a href="http://friendfeed.com/jaecen"&gt;single feed&lt;/a&gt;, to which your friends can subscribe. It's a nifty utility with a wide range of supported services, from &lt;a href="http://twitter.com"&gt;Twitter&lt;/a&gt; to &lt;a href="http://www.flickr.com/"&gt;Flickr&lt;/a&gt; to &lt;a href="http://disqus.com/"&gt;Disqus&lt;/a&gt; to &lt;a href="http://digg.com/"&gt;Digg&lt;/a&gt;. &lt;/p&gt;  &lt;p&gt;FriendFeed provides a full REST API that can provide results in JSON, XML, RSS, and Atom. Since my implementation doesn't require any client-side interactivity, I decided to use XML, transform it with XSLT on the server, and display the result in the page. The provided XML consists of a &amp;lt;feed&amp;gt; full of &amp;lt;entry&amp;gt;'s. Each entry has details such as the posted date, service (Flicker, Twitter, etc), and title. &lt;/p&gt;  &lt;p&gt;One of my presentation requirements is that the items be grouped by date. I wanted to shw and &amp;quot;post&amp;quot; for each day, with each of the days entries beneath it. I found a &lt;a href="http://www.jenitennison.com/xslt/grouping/muenchian.html"&gt;good method&lt;/a&gt; that provides exactly what I need. &lt;/p&gt;  &lt;p&gt;The crux of the functionality is using XSLT keys. Keys are essentially like database indexes, allowing you to quickly select without repeatedly traversing all of the nodes. You define a key as follows: &lt;/p&gt;  &lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; background-color: #f4f4f4"&gt;   &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;     &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:key&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;name-of-key&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;match&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;nodes-to-apply&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;use&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;value-to-index&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt; &lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;The &lt;font face="courier new,courier"&gt;name&lt;/font&gt; is simply the string you want to use to refer to this key later. The &lt;font face="courier new,courier"&gt;match &lt;/font&gt;is the node you want to apply this key to. The use can be any child element, attribute, or computed value (using a function) defining what you want to be indexed. &lt;/p&gt;

&lt;p&gt;In my case, I wanted to use the &amp;lt;updated&amp;gt; element, which containes the time and date the item was last updated. Since I was going to be grouping on the date and not the time, I used the Microsoft-specific time formatting function to truncate the time and format the date as a number: &lt;/p&gt;

&lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; background-color: #f4f4f4"&gt;
  &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;
    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:key&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;entries-by-date&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;match&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;/feed/entry&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;use&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;ms:format-date(updated, 'yyyyMMdd')&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt; &lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;Now I've defined a key called &amp;quot;entries-by-date&amp;quot; that will quickly pull up all matching &amp;lt;entry&amp;gt; elements for a given date in the format &amp;quot;20080614&amp;quot;. The next step is to iterate through all of the dates and show the corresponding entries. Unfortunately, we can't just iterate through the key we created. Instead, we have to sort the &amp;lt;entry&amp;gt; elements by their formatted &amp;lt;updated&amp;gt; element (which we created the key for), then grab all of the other &amp;lt;entry&amp;gt;'s with the same key. We want to be sure to grab each &amp;lt;entry&amp;gt; only once. Here's a larger snippet showing how to acomplish this: &lt;/p&gt;

&lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; background-color: #f4f4f4"&gt;
  &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;
    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #008000"&gt;&amp;lt;!-- Root --&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:template&lt;/span&gt; &lt;span style="color: #ff0000"&gt;match&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;/feed&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #008000"&gt;&amp;lt;!-- Group by date --&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:for-each&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;entry[count(. | key('entries-by-date', ms:format-date(updated, 'yyyyMMdd'))[1]) = 1]&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #008000"&gt;&amp;lt;!-- Sort by date --&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:sort&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;updated&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;data-type&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;number&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;order&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;descending&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;    &lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;        &lt;span style="color: #008000"&gt;&amp;lt;!-- Show date groups --&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:call-template&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;dateGrouping&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:for-each&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:template&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;The magic happens in the for-each. First, we take the current node and the first node from the key (aka index) with the same calculated date value. We create a set with these two nodes using the &amp;quot;|&amp;quot; operator. If the nodes are different, we'll get a set containing two nodes. If they are the same, there will only be one node in the set. We then check the number of nodes in the set using the count() function. If the count is one, we use it in the for-each; otherwise, we skip it. In the end, this gives us the first entry each date. &lt;/p&gt;

&lt;p&gt;After we have our target date to group by, we want to display each &amp;lt;entry&amp;gt; with the same date. In my stylesheet, I implemented it in the &amp;quot;dateGrouping&amp;quot; template. The actual code is pretty easy: &lt;/p&gt;

&lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; background-color: #f4f4f4"&gt;
  &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;
    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:template&lt;/span&gt; &lt;span style="color: #ff0000"&gt;name&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;dateGrouping&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;    &lt;span style="color: #008000"&gt;&amp;lt;!-- You could output the date header here --&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:for-each&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;key('entries-by-date', ms:format-date(updated, 'yyyyMMdd'))&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;        &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:apply-templates&lt;/span&gt; &lt;span style="color: #ff0000"&gt;select&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;.&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; border-bottom-style: none"&gt;    &lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:for-each&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, &amp;#39;Courier New&amp;#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&lt;span style="color: #0000ff"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #800000"&gt;xsl:template&lt;/span&gt;&lt;span style="color: #0000ff"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;We use the key() function to get every node in the given key with the matching value. We then apply the formatting to each node to get our final result. &lt;/p&gt;&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=J_Alt6bhBy4:ZKrZnIcn66Q:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=J_Alt6bhBy4:ZKrZnIcn66Q:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=J_Alt6bhBy4:ZKrZnIcn66Q:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=J_Alt6bhBy4:ZKrZnIcn66Q:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=J_Alt6bhBy4:ZKrZnIcn66Q:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=J_Alt6bhBy4:ZKrZnIcn66Q:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=J_Alt6bhBy4:ZKrZnIcn66Q:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=J_Alt6bhBy4:ZKrZnIcn66Q:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/J_Alt6bhBy4" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2008/06/17/Grouping-with-XSLT.aspx</feedburner:origLink></entry>
  <entry>
    <id>http://nothingisalotofsomething.com/post/2008/06/13/Poker-Bot-Competition.aspx</id>
    <title>Poker-Bot Competition</title>
    <updated>2008-06-13T22:06:50+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=050c5e79-daa8-4f2b-8ac7-f9e358fe6b14" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/1jBAv-vpCUI/Poker-Bot-Competition.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2008-06-13T22:06:50+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2008/06/13/Poker-Bot-Competition.aspx#comment" />
    <category term="Ideas" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=050c5e79-daa8-4f2b-8ac7-f9e358fe6b14</pingback:target>
    <slash:comments>0</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=050c5e79-daa8-4f2b-8ac7-f9e358fe6b14</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2008/06/13/Poker-Bot-Competition.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=050c5e79-daa8-4f2b-8ac7-f9e358fe6b14</wfw:commentRss>
  <content type="html">&lt;p&gt;People enjoy the idea of creating things to battle with each other, ala &lt;a href="http://www.battlebots.com"&gt;BattleBots&lt;/a&gt;. Here’s an idea that is both fun and potentially lucrative: a bot-only online poker server for real money. You would put money into an account an upload your own custom-written poker bot. Your bot would play until it ran out of money. It would keep its earnings, and you would be allowed to withdraw them. &lt;/p&gt;  &lt;p&gt;The idea is that you would lets these bots run for a long time and play &lt;strong&gt;many&lt;/strong&gt; games (if only machines are playing, games would go incredibly fast). To that end, you would need a bot to be able to choose what buy-in it wanted to play at, so it could adjust up or down depending on its success rate.&lt;/p&gt;  &lt;p&gt;It would be of critical importance to not allow the bots to communicate or know who they’re playing against. If they could coordinate, then could game the system to always win. To that end, each bot would be assigned to a random table, and no identifying information about either the tables (so two bots could know if they’re at the same table) or the other players would be given.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;Since it’s just machines playing, the human factor would be removed. At first glance, that would make it seem like a purely mathematical exercise. However, some strategies would become apparent, and a bot can be coded to detect and play against them. Additionally, a bot could employ random factors to protect against these types of detections. It would make the game very dynamic.&lt;/p&gt;  &lt;div class="wlWriterSmartContent" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:a17630d4-0fc3-4599-b62d-9698a950eb64" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;del.icio.us Tags: &lt;a href="http://del.icio.us/popular/bots" rel="tag"&gt;bots&lt;/a&gt;,&lt;a href="http://del.icio.us/popular/poker" rel="tag"&gt;poker&lt;/a&gt;&lt;/div&gt;&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=1jBAv-vpCUI:69CzReOhTuM:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=1jBAv-vpCUI:69CzReOhTuM:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=1jBAv-vpCUI:69CzReOhTuM:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=1jBAv-vpCUI:69CzReOhTuM:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=1jBAv-vpCUI:69CzReOhTuM:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=1jBAv-vpCUI:69CzReOhTuM:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=1jBAv-vpCUI:69CzReOhTuM:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=1jBAv-vpCUI:69CzReOhTuM:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/1jBAv-vpCUI" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2008/06/13/Poker-Bot-Competition.aspx</feedburner:origLink></entry>
  <entry>
    <id>http://nothingisalotofsomething.com/post/2008/06/13/building-a-blog.aspx</id>
    <title>building a blog</title>
    <updated>2008-06-13T20:58:56+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=46d8a6b6-e140-4032-af38-8bd8055d006b" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/jdxYawv5rc0/building-a-blog.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2008-06-13T20:58:56+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2008/06/13/building-a-blog.aspx#comment" />
    <category term="Blog" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=46d8a6b6-e140-4032-af38-8bd8055d006b</pingback:target>
    <slash:comments>0</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=46d8a6b6-e140-4032-af38-8bd8055d006b</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2008/06/13/building-a-blog.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=46d8a6b6-e140-4032-af38-8bd8055d006b</wfw:commentRss>
  <content type="html">&lt;p&gt;&lt;img title="bricks" height="240" alt="bricks" src="http://www.nothingisalotofsomething.com/image.axd?picture=WindowsLiveWriter/buildingablog_13517/bricks_3.jpg" width="213" align="right" /&gt;&lt;/p&gt;  &lt;p&gt;My first inclination when planning this site was to roll my own blogging suite; I even convinced the admin to upgrade the server to .NET 3.5 so I could use LINQ. My previous experiences with content management systems left me turned off to the idea of pre-defined layouts and constricting plug-in API’s. I wanted to be able to include every feature to take my fancy at the drop of a hat (and the upload of a .cs file). I wanted to use every AJAX/XHTML/CSS trick in the book as well as new ones that come along. If there’s one thing I knew, it’s that I would much too quickly find the bounds of the likes of &lt;a href="http://www.mamboserver.com/"&gt;Mambo&lt;/a&gt;, &lt;a href="http://drupal.org/"&gt;Drupal&lt;/a&gt;, and &lt;a href="http://www.joomla.org/"&gt;Joomla&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;Unfortunately, I can’t design the paint job for a barn. I have the knowledge and tools for great functionality. Great looks? Not so much.&lt;/p&gt;  &lt;p&gt;My next thought was to take an existing open source blogging package and adapt the theming engine and any attractive themes. Luckily for me, the first Google result for “.net open source blog engine” was &lt;a href="http://www.dotnetblogengine.net/"&gt;BlogEngine.NET&lt;/a&gt;. A quick peek through the project showed that there has been a lot of progress since my forays in to open source CMS. I was sold. I dropped any ideas of creating my own software and installed the entire package.&lt;/p&gt;  &lt;p&gt;So far, I couldn’t be happier. Instead of imposing an architecture on you, you are presented with what could be considered a reference application, and you’re free to go to town with whatever ASP.NET techniques you want. Theming ASP.NET master pages. You can use your own server and user controls without any restrictions. And since it’s open source, you can add whatever core functionality you want. In short, it’s what I like to imaging I would have written.&lt;/p&gt;  &lt;p&gt;Back to the core issue of design, BlogEngine.NET comes with a few basic themes, and there is a nice, if a bit anemic, theme gallery on their site (though it was broken when I tried to use it). It turns out, however, that there is a &lt;em&gt;thriving&lt;/em&gt; community of free XHTML/CSS site designs. There is a huge selection available at (and significant overlap between) &lt;a href="http://www.oswd.org/"&gt;oswd.org&lt;/a&gt; and &lt;a href="http://www.opendesigns.org/"&gt;opendesignes.org&lt;/a&gt;. They’re realeased under the Creative Commons Attribution License 2.5, so you’re free to do whatever you want with them (including commercial uses), as long as you give credit to the original authors.&lt;/p&gt;  &lt;p&gt;I also found an interesting site called &lt;a href="http://disqus.com/"&gt;Disqus&lt;/a&gt;, which allows you to implement threaded comments without any local resources. Additionally, it allows users to track comments and reputation across multiple sites. There is a similar service called &lt;a href="http://www.intensedebate.com/"&gt;Intense Debate&lt;/a&gt;, though I went with Disqus since it’s integrated with &lt;a href="http://friendfeed.com"&gt;FriendFeed&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;There are, of course, many other useful services, such as &lt;a href="http://www.feedburner.com/"&gt;FeedBurner&lt;/a&gt; for stats on your RSS, &lt;a href="http://www.google.com/analytics/"&gt;Google Analytics&lt;/a&gt; for stats on your site, and &lt;a href="http://flickr.com/"&gt;Fli&lt;/a&gt;&lt;/p&gt;  &lt;div class="wlWriterSmartContent" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:feadb00c-3e3a-40f8-a5b0-9ae0a53ed741" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;del.icio.us Tags: &lt;a href="http://del.icio.us/popular/blog" rel="tag"&gt;blog&lt;/a&gt;,&lt;a href="http://del.icio.us/popular/blogengine.net" rel="tag"&gt;blogengine.net&lt;/a&gt;&lt;/div&gt;  &lt;p&gt;&lt;a href="http://flickr.com/"&gt;ckr&lt;/a&gt; for images. I plan to add more to the site as I come across them.&lt;/p&gt;&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jdxYawv5rc0:nsusG6LpW6k:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jdxYawv5rc0:nsusG6LpW6k:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=jdxYawv5rc0:nsusG6LpW6k:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jdxYawv5rc0:nsusG6LpW6k:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=jdxYawv5rc0:nsusG6LpW6k:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jdxYawv5rc0:nsusG6LpW6k:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jdxYawv5rc0:nsusG6LpW6k:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=jdxYawv5rc0:nsusG6LpW6k:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/jdxYawv5rc0" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2008/06/13/building-a-blog.aspx</feedburner:origLink></entry>
  <entry>
    <id>http://nothingisalotofsomething.com/post/2008/06/11/A-Home-for-My-Words.aspx</id>
    <title>A Home for My Words</title>
    <updated>2008-06-11T13:24:00+00:00</updated>
    <link rel="self" href="http://nothingisalotofsomething.com/post.aspx?id=460e46c4-743b-4398-82e2-5a148d478959" />
    <link href="http://feedproxy.google.com/~r/NothingIsALotOfSomething/~3/jri_dnsT4ME/A-Home-for-My-Words.aspx" />
    <author>
      <name>jaecen</name>
    </author>
    
    <published>2008-06-11T13:24:00+00:00</published>
    <link rel="related" href="http://nothingisalotofsomething.com/post/2008/06/11/A-Home-for-My-Words.aspx#comment" />
    <category term="Blog" />
    <dc:publisher>jaecen</dc:publisher>
    <pingback:server>http://nothingisalotofsomething.com/pingback.axd</pingback:server>
    <pingback:target>http://nothingisalotofsomething.com/post.aspx?id=460e46c4-743b-4398-82e2-5a148d478959</pingback:target>
    <slash:comments>0</slash:comments>
    <trackback:ping>http://nothingisalotofsomething.com/trackback.axd?id=460e46c4-743b-4398-82e2-5a148d478959</trackback:ping>
    <wfw:comment>http://nothingisalotofsomething.com/post/2008/06/11/A-Home-for-My-Words.aspx#comment</wfw:comment>
    <wfw:commentRss>http://nothingisalotofsomething.com/syndication.axd?post=460e46c4-743b-4398-82e2-5a148d478959</wfw:commentRss>
  <content type="html">&lt;p&gt;
&lt;img src="http://nothingisalotofsomething.com/image.axd?picture=christen.jpg" alt="" align="right" /&gt;Welcome to &amp;quot;Nothing Is a Lot of Something dot com&amp;quot;, a non-sensical name leading to an eminently sensical destination, assuming your sense is to read about practical software development interspersed with musings on life from the perspective of one, Jason Addington.
&lt;/p&gt;
&lt;p&gt;
If that doesn&amp;#39;t make sense to you, then I&amp;#39;m sorry. To make up for it, I&amp;#39;ll give you this link -- &lt;a href="#" onclick="javascript: history.go(-1)"&gt;link!&lt;/a&gt;  -- to take you back to whatever more interesting place you came from. Have fun. You probably won&amp;#39;t be missed. 
&lt;/p&gt;
&lt;p&gt;
Now that all of the boring people are gone, let&amp;#39;s get down to business! I&amp;#39;ve created this blog for three main reasons:
&lt;/p&gt;
&lt;ol&gt;
	&lt;li&gt;To share things I learn regarding software development in order to spread understanding and understand better myself.&lt;/li&gt;
	&lt;li&gt;To write down my thoughts so I can hear what others think about them. &lt;/li&gt;
	&lt;li&gt;To do something with this domain name that I bought simply because I thought it was funny. &lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;
Sadly, the third reason was the most motivating factor. Still, like oak trees from acorns, great things can come from small ideas! So, on this surreptitiously auspicious day, I give you the smallest of ideas planted in the most fertile of grounds, in the hope that one day we may all enjoy the, uh, shade of our efforts and the, er, acorn flour of our collective cognation?
&lt;/p&gt;
&lt;p&gt;
Meh, I just hope I can remember to water it. 
&lt;/p&gt;
&lt;div class="feedflare"&gt;
&lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jri_dnsT4ME:4uUdCCkBjvQ:yIl2AUoC8zA"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=yIl2AUoC8zA" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jri_dnsT4ME:4uUdCCkBjvQ:F7zBnMyn0Lo"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=jri_dnsT4ME:4uUdCCkBjvQ:F7zBnMyn0Lo" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jri_dnsT4ME:4uUdCCkBjvQ:V_sGLiPBpWU"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=jri_dnsT4ME:4uUdCCkBjvQ:V_sGLiPBpWU" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jri_dnsT4ME:4uUdCCkBjvQ:qj6IDK7rITs"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?d=qj6IDK7rITs" border="0"&gt;&lt;/img&gt;&lt;/a&gt; &lt;a href="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?a=jri_dnsT4ME:4uUdCCkBjvQ:FQYkTm3cDRI"&gt;&lt;img src="http://feeds.feedburner.com/~ff/NothingIsALotOfSomething?i=jri_dnsT4ME:4uUdCCkBjvQ:FQYkTm3cDRI" border="0"&gt;&lt;/img&gt;&lt;/a&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/NothingIsALotOfSomething/~4/jri_dnsT4ME" height="1" width="1"/&gt;</content><feedburner:origLink>http://nothingisalotofsomething.com/post/2008/06/11/A-Home-for-My-Words.aspx</feedburner:origLink></entry>
</feed>
