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

<channel>
	<title>Monday By Noon &#187; example</title>
	<atom:link href="http://mondaybynoon.com/tag/example/feed/" rel="self" type="application/rss+xml" />
	<link>http://mondaybynoon.com</link>
	<description>A resource for Web designers and developers to read about and discuss their craft.</description>
	<lastBuildDate>Wed, 08 Feb 2012 13:49:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>&#8226; Covering the Implication and Basics of CSS Animation</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20090504%2Fcovering-the-implication-and-basics-of-css-animation%2F&#038;seed_title=%26%238226%3B+Covering+the+Implication+and+Basics+of+CSS+Animation</link>
		<comments>http://mondaybynoon.com/20090504/covering-the-implication-and-basics-of-css-animation/#comments</comments>
		<pubDate>Mon, 04 May 2009 12:45:53 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[Accessibility]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Opinion]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/?p=470</guid>
		<description><![CDATA[Allowing CSS to control the animation of various aspects of your document can have some very interesting implications. Should CSS or JavaScript control animation?<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=470&c=1779179720' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=470&c=1779179720' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>Over the past few months, I&#8217;ve been embracing <a href="http://en.wikipedia.org/wiki/Progressive_enhancement">progressive enhancement</a> on a new(er) level. I&#8217;ve been using <a href="http://www.css3.info/">CSS3</a> to make my life easier, leaving other browsers in the dust with the extra touches. I&#8217;ve lost all interest in making sure a design looks equally sophisticated in substandard browsers, and instead opted to <a href="/2009/04/20/taking-advantage-of-what-tables-have-to-offer/">leave that last column in my table left aligned</a> instead of making the table a bit easier to read with right justification.</p>
<p>Of course I still support <acronym title="Internet Explorer">IE</acronym>, and I don&#8217;t want to bring that up for debate at this time. That poor horse has been long gone for quite a while, so we can all put our sticks down for a bit. I have, however, taken a more aggressive personal stance in my lack of attention to detail when it comes to that browser family.</p>
<p>A <a href="http://twitter.com/zeldman/status/1642292742">tweet by Jeffrey Zeldman</a> really got me hooked to the prospect of further adoption of CSS3:</p>
<blockquote cite="http://twitter.com/zeldman/status/1642292742">
<p>When all browsers except IE support CSS3, it will test the limits of progressive enhancement as a design philosophy.</p>
</blockquote>
<p>With my further embrace of and focus on CSS3 came an increased interest in other bleeding edge techniques in Web design, primarily CSS animation.</p>
<h2>Does CSS animation belong?</h2>
<p>One of the ways in which I&#8217;ve been trying to raise the overall comprehensiveness of my projects is incorporating CSS animation where it may enhance the experience of a particular design. Animation in CSS has, from time to time, been a hot topic in Web design. Does animation belong in CSS? Does it constitute behavioral modification to the document, and therefore find its proper place through JavaScript? Is animation technically behavior?</p>
<p>Trying to classify the true placement of animation has proven to be a personal challenge to me. I can see both sides of the argument. I agree that animation can be correctly implemented through JavaScript, as has been done for some time. On the other side of my personal coin, I see that animation is more of a visual stimulus as opposed to direct behavioral change (e.g. updating the <acronym title="Document Object Model">DOM</acronym> with data received via <acronym title="Asynchronous JavaScript and XML">AJAX</acronym>).</p>
<h2>The basics of CSS animation</h2>
<p>As with all new technologies, you should take a minute to familiarize yourself with implementation as well as implication to make a more educated (and therefore accurate) decision to (not) use it.</p>
<p>The WebKit team provided a <a href="http://webkit.org/blog/138/css-animation/">very nice write up</a> upon the release of a nightly build that supports CSS animation. In the post, an overview of animation with CSS is provided, as well as a bit of documentation and example.</p>
<p>The WebKit implementation of CSS animation has a bit of a learning curve, but once you decipher how it works, it&#8217;s quite elegant (in my opinion). Applying a CSS animation comes in two steps. You&#8217;ll first designate your style as you would normally, defining any properties you&#8217;d like, with the addition of something new: <code>-webkit-transition</code>.</p>
<p><code>-webkit-transition</code> is actually shorthand for three transition properties:</p>
<ul>
<li><code>transition-property</code>: The property to which the animation will be applied</li>
<li><code>transition-duration</code>: The length of time the transition will last</li>
<li><code>transition-timing-function</code>: Possibly better explained as the <a href="http://www.robertpenner.com/easing/">easing method</a> you&#8217;d like to use</li>
</ul>
<p>With these three properties, you&#8217;re provided a set of tools that can directly affect the richness of your designs, bringing the level of interaction up a notch or two. To make things even more elaborate, the WebKit team has also included support for comma delimited transition declarations, allowing you to animate multiple values using a single property declaration.</p>
<p>A finished implementation of WebKit CSS animation may look something like this:</p>
<pre class="sh_css"><code>div.message a.dismiss {
  opacity:0.2;
  -webkit-transition:opacity 0.3s ease-in-out;
}

div.message a.dismiss:hover {
  opacity:1;
}</code></pre>
<p>If you&#8217;re using a recent build of WebKit that supports CSS animation, check out <a href="/examples/css-animation.html">the example</a>.</p>
<p>CSS animation can have dramatic affect on your designs, especially in Web application enahcements. Jonathan Snook recently published a screencast <a href="http://snook.ca/archives/other/screencast-webkit-in-titanium">outlining his use of CSS animations</a> while playing with <a href="http://titaniumapp.com/">Titanium</a>, a platform I&#8217;m actively researching as well.</p>
<p>Jonathan&#8217;s use of CSS animation in his screencast really brings its potential to the surface. With animations such as the combination of scale and opacity to achieve stellar effects really helps to make CSS animations shine.</p>
<h3>What should control animation?</h3>
<p>Truly classifying CSS animation has been a personal challenge for me as a designer; what are <em>your</em> thoughts? Do you feel that animation belongs in the realm of style or behavior? Do you feel animation is something else entirely? Now that an option beyond JavaScript has surfaced, did that change your opinion? Do you see animation in CSS being continually adopted on a more consistent level when it comes to adding &#8216;that little something extra&#8217; for those using an applicable browser?</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=470&c=759662431' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=470&c=759662431' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20090504/covering-the-implication-and-basics-of-css-animation/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>&#8226; Crop and Resize Images with GD or ImageMagick (v1.1)</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20071217%2Fcrop-and-resize-images-with-gd-or-imagemagick-v11%2F&#038;seed_title=%26%238226%3B+Crop+and+Resize+Images+with+GD+or+ImageMagick+%28v1.1%29</link>
		<comments>http://mondaybynoon.com/20071217/crop-and-resize-images-with-gd-or-imagemagick-v11/#comments</comments>
		<pubDate>Mon, 17 Dec 2007 08:12:20 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[Favorites]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Workbench]]></category>
		<category><![CDATA[crop]]></category>
		<category><![CDATA[Cropper UI]]></category>
		<category><![CDATA[demo]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[GD]]></category>
		<category><![CDATA[ImageMagick]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[resize]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2007/12/17/crop-and-resize-images-with-gd-or-imagemagick-v11/</guid>
		<description><![CDATA[A new GD version has been released to complement the ImageMagick crop and resize with JavaScript and PHP. Crop and resize images from within your browser.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=113&c=845215437' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=113&c=845215437' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>Over the past couple weeks, <a href="/2007/01/22/crop-resize-with-javascript-php-and-imagemagick/#comments">conversation has picked up quite a bit</a> surrounding the <a href="/2007/01/22/crop-resize-with-javascript-php-and-imagemagick/#comments">Crop &amp; Resize with JavaScript, PHP, and ImageMagick</a> demo I put together nearly a year ago. There were quite a few requests made in the comments, and there were even some developers beginning to offer their very own code. I&#8217;ve always meant to revisit the example and beef up the feature set a bit, and I&#8217;ve finally been able to do just that.</p>
<h2>Crop and Resize with GD</h2>
<p>Above all, the most asked question was &#8220;<a href="/2007/01/22/crop-resize-with-javascript-php-and-imagemagick/#comment-7477">why only ImageMagick</a>&#8220;? I really don&#8217;t have a solid answer for that, other than the project itself was a way for me to get into using <a href="http://www.imagemagick.org/">ImageMagick</a> in a bit more detail than I ever had. I&#8217;m very happy to say that this version (as well as any future versions) now has equivalent ImageMagick <em>and GD</em> installations. You can choose one or the other in both the demo and download sections.</p>
<p><a class="demo" href="/examples/crop-resize/1.1/gd/">Demo: GD Crop and Resize v1.1</a></p>
<p><a class="demo" href="/examples/crop-resize/1.1/imagemagick/">Demo: ImageMagick Crop and Resize v1.1</a></p>
<p class="update">The demos and downloads have been removed temporarily due to a security issue. Replacements will be linked as soon as possible. Thank you for your patience. Please discontinue use as soon as possible until a revision has been posted.</p>
<p>Converting to <a href="http://www.boutell.com/gd/">GD</a> wasn&#8217;t a major undertaking thanks to the helpful comments on version 1.0. It did take some time getting the slider to properly convey dimensions that would result in an accurate recreation of the image. One thing I have noticed is that the GD version seems to result in lower quality output when compared directly to ImageMagick. If you&#8217;ve got a server with both GD and ImageMagick installed, take a minute to use the same image in both demos to see what the differences are. I plan on looking into this much further, but if you&#8217;re a bit more knowledgeable on the subject, I&#8217;d love to hear what you have to say. Could the answer be that ImageMagick is simply a superior piece of software? I noticed that GD gives you the option to control the quality of images when using certain functions, so I left image output at 90% for the time being (the default is 75%).</p>
<p>If you have any positive or negative experiences with the new GD version, please feel free to post your findings either below, or in an email to me. I&#8217;d be greatly appreciative of any data that comes through.</p>
<h3>Updates to the server side</h3>
<p>There were a number of fixes that needed to be done to the server side of things straight away. First and foremost was Linux dependency. I must admit, a Windows server didn&#8217;t cross my mind when I was working on version 1.0, so I tried to polish things up a bit in that regard. The <code>mv</code> lines have been replaced, as well as an update or two elsewhere. There could very well be some more Windows-specific issues to be dealt with, unfortunately I don&#8217;t have any Windows servers at my disposal to test with. Feedback in this area will be particularly helpful.</p>
<p>A small series of updates I made was to the file upload process itself. The example now only accepts files with a MIME type of <code>image/jpeg</code>. Future versions will allow for more image formats, but I&#8217;d like to do some more research before including it. There are also some checks on the filenames themselves, as there were some issues with particular circumstances in version 1.0.</p>
<p>There was some logic repair regarding the <code>$maxWidth</code> and <code>$maxHeight</code> variables you can set in the first step. As per request, <code>$minWidth</code> and <code>$minHeight</code> have also been added. This should allow you to really narrow down what image dimensions will result using these variables in conjunction with the <a href="http://www.defusion.org.uk/code/javascript-image-cropper-ui-using-prototype-scriptaculous/">Cropper UI</a>. One issue that has not been included yet is taking the minimum and maximum values set in the first step into account when users have reached the resize stage of version 1.1. This will be handled in a future release.</p>
<p>Finally, the last noticeable feature to be added server side was the inclusion of <a href="/2007/01/22/crop-resize-with-javascript-php-and-imagemagick/#comment-25838">image rotation</a>. When the final image is presented, image rotations of 90, 180, and 270 degrees will be available as well. You&#8217;re able to pull apart the code to retrieve which image you&#8217;d like to use, and can also include auto-generation using a form whenever you&#8217;d like. This was a larger hill to climb when it came to GD as none of the servers I have access to had PHP compiled with GD bundled, therefore giving me no access to <a href="http://www.php.net/imagerotate"><code>imagerotate()</code></a>. As reflected in the source, <a title="Alternative PHP function for imagerotate()" href="http://www.php.net/manual/en/function.imagerotate.php#73446">a function was written as an alternative</a>, and appears to work just fine. It checks to see if <code>imagerotate()</code> is available before taking the extra <abbr title="Central Processing Unit">CPU</abbr> cycles doing it &#8216;by hand&#8217;.</p>
<p><span id="more-113"></span></p>
<h3>Updates to the <a href="http://www.defusion.org.uk/code/javascript-image-cropper-ui-using-prototype-scriptaculous/">Cropper UI</a></h3>
<p>I can&#8217;t credit <a href="http://www.defusion.org.uk/">Dave Spurr</a> enough for his <a href="http://www.defusion.org.uk/code/javascript-image-cropper-ui-using-prototype-scriptaculous/">Cropper UI</a> that powers the entire front end of the cropping mechanism this installation provides. He had made a number of updates after my version 1.0 release, so first things first I went ahead and upgraded to his most recent version.</p>
<p>The second most asked for feature was a specific alteration to the Cropper UI itself. Whether it be minimum dimensions, maximum dimensions, or something else, it seemed like many people would like to use the script, but the openness of the Cropper UI was in fact a limitation. I made an effort to indicate that Dave Spurr included many of the requested features right out the box and documented them well on his website. To help with the version 1.1 demo, I&#8217;ve included a few Cropper UI instances to demonstrate its robustness. When you check out the demo, you&#8217;ll see a new option to choose the crop type you&#8217;d like to use. I&#8217;ve included the following by default:</p>
<dl>
<dt>Basic crop</dt>
<dd>Includes the most basic version of the Cropper UI. Unrestricted as far as crop dimension is concerned.</dd>
<dt>Ratio (16:9)</dt>
<dd>A 16:9 ratio will be applied to the Cropper UI. There are no restrictions for width or height.</dd>
<dt>Minimum Dimensions (200&#215;200)</dt>
<dd>The Cropper UI will require a minimum 200px by 200px crop area and will not allow anything less.</dd>
<dt>Minimum Dimensions (200&#215;200) with Ratio (1:1)</dt>
<dd>The Cropper UI will require a minimum 200px by 200px crop area and will not allow anything less. It will also apply a 1 to 1 ratio when adjusting the crop area.</dd>
<dt>Maximum Dimensions (200&#215;200)</dt>
<dd>The Cropper UI will require a maximum 200px by 200px crop area and will not allow anything less.</dd>
<dt>Maximum Dimensions (200&#215;200) with Ratio (1:1)</dt>
<dd>The Cropper UI will require a maximum 200px by 200px crop area and will not allow anything less. It will also apply a 1 to 1 ratio when adjusting the crop area.</dd>
<dt>Fixed Dimensions (200&#215;200)</dt>
<dd>You&#8217;re provided with a crop area at a fixed size of 200px by 200px. The drag handles are also removed as an added convenience.</dd>
<dt>Minimum Dimensions (100&#215;100) &amp; Maximum Dimensions (200&#215;200)</dt>
<dd>With this option, you&#8217;re limited to a crop area range scaling from 100px by 100px to 200px by 200px.</dd>
</dl>
<p>The Cropper UI is quite impressive in and of itself as you can see by the number of options you can apply by changing some values. For example, one thing I didn&#8217;t include in the demo is a Cropper UI that is limited to minimum and maximum dimensions as well as an aspect ratio of 1:1. You can easily invoke a Cropper UI with these attributes by creating a new file (<code>lib/init_cropper/min_max_ratio.js</code> for example) and inserting the following:</p>
<pre class="sh_javascript"><code>function onEndCrop(coords, dimensions) {
	$('cropX').value = coords.x1;
	$('cropY').value = coords.y1;
	$('cropWidth').value = dimensions.width;
	$('cropHeight').value = dimensions.height;
}

Event.observe( window, 'load', function() {
	new Cropper.Img(
		'cropImage', {
			ratioDim: { x: 1, y: 1 },
			minWidth: 200,
			minHeight: 200,
			maxWidth: 300,
			maxHeight: 300,
			onEndCrop: onEndCrop
		}
	);
});</code></pre>
<p>Swapping in this JavaScript would invoke a new Cropper UI for your image with a minimum dimension of 200px by 200px, a maximum dimension of 300px by 300px, as well as an aspect ratio of 1:1. Going further, you&#8217;re also able to specify a minimum or maximum for a height or width alone. This will result in a Cropper UI with handles only on the top and bottom if you wish. I would definitely suggest checking out the official website for <a href="http://www.defusion.org.uk/code/javascript-image-cropper-ui-using-prototype-scriptaculous/">Dave Spurr&#8217;s Cropper UI</a> for more details</p>
<h3>Download &amp; installation instructions</h3>
<p>Installation is very straightforward. Download links to follow.</p>
<ol>
<li>Download the GD or ImageMagick version</li>
<li>Extract</li>
<li>Upload to your webserver</li>
<li><em>Give write permissions</em> to the <code>working</code> folder and subfolders</li>
<li>Begin using the demo</li>
</ol>
<p><a class="zipDownload" href="/examples/crop-resize/1.1/download/crop-resize-gd-1.1.zip">Download GD Crop and Resize v1.1 (.zip)</a></p>
<p><a class="zipDownload" href="/examples/crop-resize/1.1/download/crop-resize-imagemagick-1.1.zip">Download ImageMagick Crop and Resize v1.1 (.zip)</a></p>
<p class="update">The demos and downloads have been removed temporarily due to a security issue. Replacements will be linked as soon as possible. Thank you for your patience. Please discontinue use as soon as possible until a revision has been posted.</p>
<p>Many times, if you&#8217;re experiencing odd behavior such as pages turning up blank, there is an issue with write permissions on your server. The demo will need write access to the directory in which it is stored as well as the <code>working</code> folder and all folders within it. Errors with the code itself will more than likely be output to the screen. If that happens, please feel free to post your errors at your earliest convenience.</p>
<h3>What about AJAX?</h3>
<p>Another request that popped up more than once was a request for an AJAX version, something that didn&#8217;t require the page to reload. I thought about working out something such as that but quickly dismissed it, at least for now. My intention with this project was to provide something which would be used by the widest audience possible. Too many times have I seen examples too far into their own development to prevent me from writing something from scratch. In my opinion, an AJAX version of this example would prevent easy adoption and inclusion for many developers. AJAX may be a possibility for a future version, but I&#8217;d like to seriously consider as many angles as possible. This directly relates to the (lack of) design when looking at the demonstration. I wanted to keep things minimal in order to create the least work for anyone who wants to try incorporating this into something they&#8217;ve written.</p>
<p>I hope at the very least, the GD version presents itself as useful to at least a few people over the coming months. I do plan continuing work on future version, I simply hope it doesn&#8217;t take as long as this revision has. Please provide any comments you&#8217;d like, especially bug reports, and enjoy the demo!</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=113&c=1465291275' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=113&c=1465291275' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20071217/crop-and-resize-images-with-gd-or-imagemagick-v11/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>&#8226; POSH: Semantic Markup for Driving Directions</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20070611%2Fposh-semantic-markup-for-driving-directions%2F&#038;seed_title=%26%238226%3B+POSH%3A+Semantic+Markup+for+Driving+Directions</link>
		<comments>http://mondaybynoon.com/20070611/posh-semantic-markup-for-driving-directions/#comments</comments>
		<pubDate>Mon, 11 Jun 2007 13:11:19 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Opinion]]></category>
		<category><![CDATA[Semantics]]></category>
		<category><![CDATA[Standards]]></category>
		<category><![CDATA[Accessibility]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[Google-Maps]]></category>
		<category><![CDATA[POSH]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2007/06/11/posh-semantic-markup-for-driving-directions/</guid>
		<description><![CDATA[Driving directions offer a lot of semantic data.  This article takes the semantics of driving directions into consideration and offers discussion about how to improve structural markup of directions.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=83&c=1054935219' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=83&c=1054935219' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>One of my all time favorite Web apps to use has to be <a href="http://maps.google.com">Google Maps</a>.  I find myself using it not only because the data provided is that much more accurate than other services such as MapQuest (which has completely let me down repeatedly in the past), but because the service itself is becoming more multipurpose by the day.  Unfortunately, <a href="/2006/03/06/google-vs-web-standards-part-2/">when it comes to Google</a>, applications aren&#8217;t always implemented with <a href="/2006/11/06/flash-javascript-and-providing-alternative-content/">Web standards or graceful degradation</a> in mind.  Google apps are quite debilitated &#8212; if at all functional &#8212; with JavaScript disabled, and downright scary with no <abbr title="Cascading Style Sheets">CSS</abbr>.</p>
<p>Moving on, Google is using tables to mark up their driving directions provided via Google maps, but in my opinion, there&#8217;s a much better way.</p>
<p><img src="/images/google-maps.jpg" alt="[Image] Screenshot of Google Maps directions" /></p>
<p>There is actually quite a bit of information provided in simple driving directions.  For the purposes of this article, I&#8217;d just like to focus on the directions themselves, as opposed to the content offered before and after, as well as the maps that are (usually) included.</p>
<h3>Driving directions at their core</h3>
<p>At the very least, when providing driving directions, you&#8217;re compiling an ordered lists of steps that need to be followed in order to navigate from point A to point B.</p>
<pre><code>&lt;ol class="driving-directions">
  &lt;li>Head southeast on Crossgates Mall Rd - 0.2 mi&lt;/li>
  &lt;li>Turn left onto the Washington Ave Ext E ramp
    to I-90 Thruway/I-87 - 407 ft&lt;/li>
  &lt;li>Merge onto Washington Ave Ext - 0.9 mi&lt;/li>
  &lt;li>Continue on Washington Ave - 3.9 mi&lt;/li>
  &lt;li>Turn right at Robin St. - 417 ft>&lt;/li>
&lt;/ol></code></pre>
<p><span id="more-83"></span></p>
<p>While a single ordered list could be considered acceptable, there is quite a bit more information provided that has semantic value.  For instance, in each step of the ordered list, there is detail given as to what actions should be taken, as well as a measure of distance.  To me, this is a good place to include a definition list.  It seems fitting to mark up this pair of data using a definition list as you&#8217;re relating both the action and the distance traveled.  The distance traveled is a direct result of the action being taken so a definition list would work well.</p>
<pre><code>&lt;ol class="driving-directions">
  &lt;li>&lt;dl>&lt;dt>Head southeast on Crossgates Mall Rd&lt;/dt>
    &lt;dd>0.2 mi&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>&lt;dt>Turn left onto the Washington Ave Ext E ramp
    to I-90 Thruway/I-87&lt;/dt>
    &lt;dd>407 ft&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>&lt;dt>Merge onto Washington Ave Ext&lt;/dt>
    &lt;dd>0.9 mi&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>&lt;dt>Continue on Washington Ave&lt;/dt>
    &lt;dd>3.9 mi&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>&lt;dt>Turn right at Robin St.&lt;/dt>
    &lt;dd>417 ft&lt;/dd>&lt;/dl>&lt;/li>
&lt;/ol></code></pre>
<p>To me, using a combination of an ordered list as well as integrating a definition list results is a much more semantically rich set of driving directions.</p>
<h4>A quick note about <code>address</code></h4>
<p>From time to time, I&#8217;ll come upon some markup that uses <code>address</code> incorrectly.  <code>address</code> <a href="http://www.w3.org/TR/html401/struct/global.html#h-7.5.6">is defined</a> as:</p>
<blockquote cite="http://www.w3.org/TR/html401/struct/global.html#h-7.5.6"><p>The <code>address</code> element may be used by authors to supply contact information for a document or a major part of a document such as a form. This element often appears at the beginning or end of a document.</p>
</blockquote>
<p>Without reading the definition, I can understand why some people may assume that <code>address</code> is used to mark up a segment of data that represents any address, but in reality, it is used to distinguish how to contact those responsible for the document.  It isn&#8217;t applicable to use the <code>address</code> tag to mark up the street address of each step here.</p>
<h4>What about imagery in driving directions?</h4>
<p>Many times, driving directions include images which help to classify what information each instruction is providing.  There may be an arrow indicating which direction to turn, an interstate sign, or something like a traffic light to indicate a future encounter.  How should these images be included?  In my opinion, this is one of the times where <a href="/2006/03/20/semantic-image-use/">semantic image use</a> should be looked into.  Taking a step back and thinking about it, these images are unique in that they aren&#8217;t part of the site design.  They&#8217;re in place to convey pieces of information to the reader.  Making the adjustments to our example:</p>
<pre><code>&lt;ol class="driving-directions">
  &lt;li>&lt;dl>
    &lt;dt>Head southeast on Crossgates Mall Rd&lt;/dt>
    &lt;dd>0.2 mi&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>
    &lt;dt>&lt;img src="images/turn-left.jpg" alt="Image signaling
    a left turn" />Turn left onto the Washington Ave Ext E ramp
    to I-90 Thruway/I-87&lt;/dt>
    &lt;dd>407 ft&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>
    &lt;dt>Merge onto Washington Ave Ext&lt;/dt>
    &lt;dd>0.9 mi&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>
    &lt;dt>Continue on Washington Ave&lt;/dt>
    &lt;dd>3.9 mi&lt;/dd>&lt;/dl>&lt;/li>
  &lt;li>&lt;dl>
    &lt;dt>&lt;img src="images/turn-right.jpg" alt="Image signaling a
    right turn" />Turn right at Robin St.&lt;/dt>
    &lt;dd>417 ft&lt;/dd>&lt;/dl>&lt;/li>
&lt;/ol></code></pre>
<p>Alternatively, it would be argued that the <code>dt</code> provides the instruction and the image is merely redundant.  I think that is the decision of the developer, but I do feel it is more applicable to include these &#8216;helper&#8217; images in this way as opposed to being a <code>background-image</code> to the <code>dt</code>.  What do you think?  Should an element be classed and provided a <code>background-image</code> as opposed to including the image inline?  What other ideas do you have to improve the example?</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=83&c=1335146225' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=83&c=1335146225' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20070611/posh-semantic-markup-for-driving-directions/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>&#8226; Applying Progressive Enhancement to Your CSS</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20070319%2Fapplying-progressive-enhancement-to-your-css%2F&#038;seed_title=%26%238226%3B+Applying+Progressive+Enhancement+to+Your+CSS</link>
		<comments>http://mondaybynoon.com/20070319/applying-progressive-enhancement-to-your-css/#comments</comments>
		<pubDate>Mon, 19 Mar 2007 13:04:57 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[DOM]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Opinion]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[graceful-degradation]]></category>
		<category><![CDATA[progressive-enhancement]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2007/03/19/applying-progressive-enhancement-to-your-css/</guid>
		<description><![CDATA[It is becoming more common for designers to neglect progressive enhancement once unobtrusive JavaScript is obtained.  There are countless JavaScript libraries available, full of code that is designed with progressive enhancement in mind.  The issue that&#8217;s becoming increasingly problematic, in my opinion, is the associated style that is required to achieve desired visual effects.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=71&c=44235267' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=71&c=44235267' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>There&#8217;s no denying that JavaScript can provide a much more pleasant user experience.  There have always been usability and accessibility concerns tied to JavaScript, but only recently have those concerns been carefully minded (by many people).  The first round of widespread JavaScript adoption resulted in obtrusive documents with error prone scripts that were hit or miss as far as browser support was concerned.  Times have taken great change for the better, and now JavaScript can be properly implemented to progressively enhance many documents.</p>
<p>There have been many pieces written on both <a href="http://en.wikipedia.org/wiki/Graceful_degradation">graceful degradation</a> as well as <a href="http://en.wikipedia.org/wiki/Progressive_enhancement">progressive enhancement</a>.  Some people feel that they&#8217;re one and the same, but personally I think they are very similar, but each have unique characteristics.  While a document that gracefully degrades will transparently appear as normal to any reader, progressively enhancing the document adds layers of functionality, if available, after the fact.</p>
<h2>Relating Progressive Enhancement to Your <abbr title="Cascading Style Sheets">CSS</abbr></h2>
<p>Many times when you read about progressive enhancement on the Web, the discussion revolves around JavaScript.  The general idea is to provide unobtrusive JavaScript that will not interfere with the viewing of any document, regardless of browser capability.  As Web based applications become more advanced, there are many visual features being included to [hopefully] benefit the reader.</p>
<p>What&#8217;s unfortunate is that it is becoming more common for designers to neglect progressive enhancement once unobtrusive JavaScript is obtained.  There are countless JavaScript libraries available, full of code that is designed with progressive enhancement in mind.  The issue that&#8217;s becoming increasingly problematic, in my opinion, is the associated style that is required to achieve desired visual effects.</p>
<p>If your document will be enhanced when a reader doesn&#8217;t have a JavaScript equipped Web browser, it&#8217;s equally important that your <abbr title="Cascading Style Sheets">CSS</abbr> doesn&#8217;t interfere.  While JavaScript should only control document behavior, that behavior often involves making changes to the <acronym title="Document Object Model">DOM</acronym> that are in turn effected by the document style.</p>
<p>As an example, there are many times that designers will adjust the <code>visibility</code> or <code>display</code> of an element in their <abbr title="Cascading Style Sheets">CSS</abbr> for the sole purpose of toggling that property at some point.  What&#8217;s important to keep in mind is that readers without a JavaScript enabled browser will apply the entire style sheet, but have no script available to execute that fancy Ajax animation.</p>
<h3>Use JavaScript to Progressively Enhance your <abbr title="Cascading Style Sheets">CSS</abbr></h3>
<p>In my opinion, there&#8217;s nothing wrong with altering the <code>visibility</code> or <code>display</code> of certain elements to bring your Web application together.  It&#8217;s important to keep in mind the necessity of retaining progressive enhancement with your <abbr title="Cascading Style Sheets">CSS</abbr> as well.</p>
<p>On a recent project I ran into a situation in which I wanted certain elements to have stylistic elements that required JavaScript for full functionality.  It would have been a nice feature to add, but requiring JavaScript isn&#8217;t an option.  I needed a way to separate a small bit of <abbr title="Cascading Style Sheets">CSS</abbr> which would only be applied if the reader were able to make use of the JavaScript provided with the document.</p>
<p>I was reminded of an article I had read some time ago (that I&#8217;m having trouble locating) which mentioned using JavaScript to manipulate the <acronym title="Document Object Model">DOM</acronym> and add your <abbr title="Cascading Style Sheets">CSS</abbr>.  This way, the styles are only applied using the technology which will control other document behavior.  What we&#8217;ll do is generate a <code>link</code> element, append the proper attributes, and finally insert our element into the document tree by placing a snippet in the <code>head</code>.</p>
<p><span id="more-71"></span></p>
<pre><code>&lt;script type="text/javascript">
  //&lt;![CDATA[
    initStyles = document.createElement("link");
    initStyles.setAttribute("rel","stylesheet");
    initStyles.setAttribute("type","text/css");
    initStyles.setAttribute("media","screen,projection");
    initStyles.setAttribute("href","css/js-init.css");
    document.getElementsByTagName("head")[0].appendChild(initStyles);
  //]]&gt;
&lt;/script></code></pre>
<p>This snippet allows us to include the <abbr title="Cascading Style Sheets">CSS</abbr> to &#8216;initialize&#8217; the document in preparation for user interaction via JavaScript.  The style will only be applied if your reader has a JavaScript enabled browser, making it extremely likely that your Web app JavaScript will operate as intended.</p>
<h4>It&#8217;s not the only way</h4>
<p>Appending a style sheet to your document using a method like this may not be ideal in your opinion.  You could effectively use your existing <abbr title="Cascading Style Sheets">CSS</abbr> and manipulate the <acronym title="Document Object Model">DOM</acronym> in a way that doesn&#8217;t interfere at all with a JavaScript-less reader.  I&#8217;m not a fan of using JavaScript to directly control the style of an element.  To me, (something like) <code>element.style.color = 'red'</code> triggers nightmarish images of <code>&lt;FONT color="red">Lorem ipsum&lt;/FONT></code>.  I try to stray away from using document behavior to control document style, that&#8217;s reserved for <abbr title="Cascading Style Sheets">CSS</abbr>.</p>
<p>What is truly important is ensuring your document is still <em>equally usable</em> whether you&#8217;re working with JavaScript or not.  That goes beyond taking your scripts into consideration, any preparation you create with <abbr title="Cascading Style Sheets">CSS</abbr> must be monitored as well.</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=71&c=1456745973' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=71&c=1456745973' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20070319/applying-progressive-enhancement-to-your-css/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>&#8226; Using SciTE with TextMate Style Snippets</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20070312%2Fusing-scite-with-textmate-style-snippets%2F&#038;seed_title=%26%238226%3B+Using+SciTE+with+TextMate+Style+Snippets</link>
		<comments>http://mondaybynoon.com/20070312/using-scite-with-textmate-style-snippets/#comments</comments>
		<pubDate>Mon, 12 Mar 2007 11:29:13 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Opinion]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[productivity]]></category>
		<category><![CDATA[SciTE]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[TextMate]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2007/03/12/using-scite-with-textmate-style-snippets/</guid>
		<description><![CDATA[SciTE is a very powerful and capable editor.  Using a Snippets plugin developed by Mitchell, you&#8217;re able to mimic some of the functionality that has made TextMate as popular as it is.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=70&c=341436395' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=70&c=341436395' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>Ever since watching <a href="http://www.dustindiaz.com/screencast-episode-01/">Dustin Diaz&#8217;s first screencast</a>, I was incredibly jealous of <a href="http://macromates.com/">TextMate</a> (specifically the keyboard triggered <a href="http://macromates.com/textmate/manual/snippets">snippets</a>).  I was on a mission to find an alternative that wasn&#8217;t limited to Mac OS X as it was clear there wouldn&#8217;t be a Linux version of TextMate.  There are <a href="http://macromates.com/blog/archives/2005/11/07/windowslinux-alternative/">quite a few suggestions</a> on the TextMate site itself, but I found nothing that mimicked the Snippets functionality of TextMate properly.  <a href="http://www.e-texteditor.com/">E TextEditor</a> came out for Windows, making me <em>even more jealous</em>. Now there was an application for Windows that performed similarly to TextMate, and I had nothing to work with.  The author of E indicated that there would eventually be a Linux version, but not until the Windows version was final. After a continued search, I finally came upon <a href="http://caladbolg.net/scite_snippets.php">SciTE Snippets</a>.</p>
<h2>SciTE &#8211; My New Favorite Editor</h2>
<p><a href="http://www.scintilla.org/SciTE.html">SciTE</a> is (freely) available for both Linux and Windows, but this article will dedicate itself to the Linux install process as it is the only environment in which I&#8217;ve set it up.  Furthermore, the details of the installation process will be specific to <a href="http://www.ubuntu.com/">Ubuntu 6.10</a>, as it is <a href="/2006/09/11/linux-and-web-development-part-2/">my distribution of choice</a>, but the install process itself should be similar on just about any version of Linux.</p>
<h3>Installing SciTE</h3>
<p>SciTE is easily available to install by executing the following in a terminal:</p>
<pre><kbd>sudo apt-get install scite</kbd></pre>
<p>After you enter your password, SciTE will be automatically installed and setup.  You can also install SciTE using Synaptic Package Manager, but I prefer the command line.  SciTE can be run by entering <code>scite</code> in the command line, or using the menu: Applications > Programming > SciTE Text Editor.</p>
<p class="screenshot"><img src="/images/screenshots/scite-default.jpg" alt="Screenshot of default SciTE installation" /></p>
<p>By default, SciTE doesn&#8217;t include the snippet functionality offered by TextMate, but incorporating all of the hard work by <a href="http://caladbolg.net/">Mitchell</a>, <a href="http://caladbolg.net/scite_snippets.php">SciTE Snippets</a> are easy to implement.</p>
<p><span id="more-70"></span></p>
<h3>Implementing SciTE Snippets</h3>
<p>I spent some time trying to grasp how to actually install the snippets plugin Mitchell developed.  Following his <a href="http://caladbolg.net/scite_snippets.php#quick_install">documentation</a> proved to be quite useful and I had SciTE Snippets up and running after a bit of trial and error.  It involved a process that some people new to Linux may find intimidating, so I&#8217;ve decided I would try to use the <a href="http://caladbolg.net/scite.php#binaries">SciTE binaries offered on the site</a>.  Not only do you get working Snippets, you&#8217;re provided with a new look and feel for SciTE itself.  A large library of Snippets are included to work with and add upon and I found it to be a great starting point for using Snippets in SciTE.</p>
<p>The <a href="http://caladbolg.net/scite.php#binaries">binaries Mitchell offers</a> are stored on <a href="http://code.google.com/p/scite-tools/downloads/list">Google Code</a> and available for Windows as well as Linux.  Download the latest Linux Binaries (<code>scite-tools_linux_bin_r3.tgz</code> at the time of this writing) as well as the Source Code (<code>scite-tools_src_r3.zip</code> at the time of this writing) which will come in useful later.</p>
<dl class="installInstructions">
<dt>Extract <kbd>scite-tools_linux_bin_r3.tgz</kbd></dt>
<dd>
<pre><kbd>tar xzvf scite-tools_linux_bin_r3.tgz</kbd></pre>
</dd>
<dt>Copy the new SciTE binary over your installed version</dt>
<dd>
<pre><kbd>cd scite-tools_linux_bin_r3
sudo mv /usr/bin/scite /usr/bin/scite.bak
sudo cp SciTE /usr/bin/scite</kbd></pre>
</dd>
</dl>
<p>The binary has now been copied to your existing installation, it&#8217;s an updated version compared to the one offered in the Ubuntu repositories.  You&#8217;ll notice that if you run SciTE, not much has changed; we&#8217;ll still need to copy over Mitchell&#8217;s configuration files as well as his included snippets.</p>
<dl class="installInstructions">
<dt>Extract scite-tools_src_r3.zip:</dt>
<dd>
<pre><kbd>unzip scite-tools_src_r3.zip</kbd></pre>
</dd>
<dt>Implement configuration and Snippets:</dt>
<dd>
<pre><kbd>cd scite-tools_src_r3/
sudo cp -R * /usr/share/scite/</kbd></pre>
</dd>
</dl>
<p>Just to be clear, not only have you copied over the configuration and included Snippets, you&#8217;ve also copied the source.  If you feel the need to remove the extra files, feel free to do so.  Now that the configuration files have been copied, you can run SciTE again, and you&#8217;ll see it&#8217;s received quite a makeover:</p>
<p class="screenshot"><img src="/images/screenshots/scite-snippets.jpg" alt="Screenshot of default SciTE installation" /></p>
<p>SciTE Snippets are now at your disposal using the <kbd>CTRL+i</kbd> keyboard combination after typing your trigger.</p>
<h4>Customizing SciTE Snippets</h4>
<p>While Mitchell includes many of his personal Snippets, I have a certain way of writing markup, style, and code.  Each developer will want to make adjustments to existing snippets &#8212; as well as add some &#8212; in order to streamline his process even further and take full advantage of their presence.  Managing your Snippets is actually quite easy if you follow the conventions established by Mitchell.  Your snippets are stored in <kbd>/usr/share/scite/scripts/</kbd> and organized according to language.</p>
<p><a href="http://caladbolg.net/scite_snippets.php#creating">Creating Snippets</a> is well documented on Mitchell&#8217;s site, and he even offers a <a href="http://caladbolg.net/scite_snippets.php#gen_snippets">Ruby Snippet Generation Script</a> which can come in quite handy.  Personally, I found the example Snippets offered in <kbd>/usr/share/scite/scripts/html/snippets.lua</kbd> to be most helpful in understanding Snippets and how they worked.  I simply manage the snippets I wish to use in that file and it&#8217;s worked out well so far.</p>
<p>Mitchell has provided a really great tool for many people, free of charge.  He has <a href="http://caladbolg.net/scite_snippets.php">provided screencasts</a> which show his Snippets in action, including a demonstration of <a href="http://caladbolg.net/scite_snippets.php#scopes">how to use scopes</a>, a very powerful feature he&#8217;s included.</p>
<h4>Customizing the SciTE interface</h4>
<p>When using SciTE for the first time, I was surprised not to find a Preferences dialog.  Like anybody, I have preferences as to the type used in my editor, so I was looking to make that simple change.  Instead of a Preferences dialog, you&#8217;ll need to edit a configuration file.  While I&#8217;d much prefer to have a GUI dialog, having to edit a configuration file really isn&#8217;t that big of a deal to me, but I know many people would look at the application as inferior for that very reason.</p>
<p>Regardless, the configuration file can be edited by selecting Options > Open Global Options File within SciTE.  The associated file holds all of the preferences you&#8217;ll want to tinker with to get SciTE to look just how you want it.  If you&#8217;re using Mitchell&#8217;s configuration, you&#8217;ll notice he took the time to reorganize this file, making it very easy to manage.</p>
<h5>SciTE (especially with Snippets) is my new favorite tool</h5>
<p>I&#8217;ve found that creating Snippets can be a lengthy process, but one that offers great benefit.  Using Snippets allows you to work at a much faster pace without getting ahead of yourself and losing focus.  It takes away much of the tedious aspects that come with writing markup.  The speed benefits alone made switching from Bluefish/Quanta worth it.  I have a feeling that many editors will incorporate such a feature in their upcoming releases.</p>
<p>It goes without saying that SciTE has all of the features you would expect in an editor: line numbering, code folding, syntax highlighting, etc.  I&#8217;m very pleased to make the switch to SciTE, and I definitely recommend it to anybody who isn&#8217;t willing to fork over the cash for a copy of <a href="http://www.e-texteditor.com/">E</a>.  I&#8217;ve only been working with SciTE a short time so far, so if anybody has any tips or tricks they&#8217;re willing to offer, it would be great to post them as a comment.</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=70&c=2088103816' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=70&c=2088103816' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20070312/using-scite-with-textmate-style-snippets/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>&#8226; Suckerfish HoverLightbox Redux</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20070219%2Fsuckerfish-hoverlightbox-redux%2F&#038;seed_title=%26%238226%3B+Suckerfish+HoverLightbox+Redux</link>
		<comments>http://mondaybynoon.com/20070219/suckerfish-hoverlightbox-redux/#comments</comments>
		<pubDate>Mon, 19 Feb 2007 14:13:13 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[Favorites]]></category>
		<category><![CDATA[Workbench]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[gallery]]></category>
		<category><![CDATA[hoverbox]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[lightbox]]></category>
		<category><![CDATA[suckerfish]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2007/02/19/suckerfish-hoverlightbox-redux/</guid>
		<description><![CDATA[After taking some time to play with the design as well as functionality, a new version of the Suckerfish HoverLightbox is here.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=67&c=716745934' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=67&c=716745934' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>When the <a href="/2006/03/27/suckerfish-hoverlightbox/">original Suckerfish HoverLightbox</a> was published, I was honestly surprised at the amount of attention it received.  I was a fan of the technique, and I was also really glad that many people took the time to read the entire article instead of just playing with the demo and move on.  One thing I was disappointed in, however, was the lack of attention to detail on my part in the demo and examples provided.  Most of my time was put into testing the technique and determining if it was useful.  I have been meaning to revisit the technique and take another look at it, and recently I was able to do so.</p>
<p><a class="viewDemo" href="/examples/suckerfish_hoverlightbox_redux/">Suckerfish HoverLightbox Redux Demo</a></p>
<p>The Redux has a number of improvements, mostly visual, but some behavioral changes as well.  Before going into detail, it&#8217;s important to give due credit to those who helped make the Suckerfish HoverLightbox a possibility.</p>
<p><a href="http://alistapart.com/articles/dropdowns">Suckerfish Dropdowns</a> are widely accepted and used by many developers in order to include a more comprehensive navigation in their various designs.  Patrick Griffiths and Dan Webb changed a lot when they published their article to <a href="http://alistapart.com">A List Apart</a>.  The <a href="http://sonspring.com/journal/hoverbox-image-gallery">Hoverbox Image Gallery</a> by <a href="http://sonspring.com">Nathan Smith</a> is a great technique that I&#8217;ve found myself using time and time again in various otherwise plain image gallerys.  Finally <a href="http://www.huddletogether.com/projects/lightbox2/">Lightbox JS</a> by Lokesh Dhakar is used to bring the images into full view.  Each of these pieces have been slightly modified for use in the Suckerfish HoverLightbox, but each deserves the utmost respect for their hard work and ingenuity.</p>
<p><a class="zipDownload long" href="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox_redux/the_redux-1.2.zip" title="Download Suckerfish HoverLightbox Redux v1.2">Suckerfish HoverLightbox Redux (.zip)</a></p>
<p>The provided download includes a ZIP archive consisting of the <a href="/examples/suckerfish_hoverlightbox_redux/">vanilla Suckerfish HoverLightbox demo</a> and all the necessary JavaScript, CSS, XHTML, and images.</p>
<h2>Modifications that were made</h2>
<p>When I began work on the Suckerfish HoverLightbox, I started from the inside out.  I began with <a href="http://www.huddletogether.com/projects/lightbox2/">Lightbox JS 2.02</a> as it is an upgraded version from the first, which the original Suckerfish HoverLightbox employed.  This version allows someone to navigate through each set of pictures while continuing to use the Lighbox, as opposed to closing it out each and every time.  I like that feature, as it can save me time when flipping through a collection of pictures.</p>
<p>In my personal experience, some people have had difficulty realizing that navigating from picture to picture was possible.  Unless it was explained, people would continue to close Lightbox and click another image in the series.  After being shown that mousing over the picture will bring up some options, the &#8216;local&#8217; navigation would be used.  To make things easier, I added in another set of navigation elements to the Lightbox.  Near the Close button, there is now a set of small arrows available when there are more images to browse in a particular set.  It seems to have helped some people, while others who have had prior experience with Lightbox can continue to use the native local navigation.</p>
<p>The <a href="http://sonspring.com/journal/hoverbox-image-gallery">Hoverbox Image Gallery</a> was not modified very much beyond a few color changes and dimension adjustments.  The technique is quite robust and does what it aims to do very effectively.  It&#8217;s quite easy to apply to almost anything, and the Suckerfish HoverLightbox is no different.</p>
<p>Finally, some changes needed to be made in the JavaScript for the <a href="http://alistapart.com/articles/dropdowns">Suckerfish Dropdowns</a>.  Originally, the script used the <acronym title="Document Object Model">DOM</acronym> to find a specific element with a particular <code>id</code>. This was changed to find the &#8216;gallery&#8217; container and work from that point.  There was also JavaScript added to assist with a nasty <abbr title="Internet Explorer 6">IE6</abbr> rendering bug I came across when putting the demo together.</p>
<p><span id="more-67"></span></p>
<h3>Problems I ran into</h3>
<p>Naturally, I ran into a snag here and there when putting the Redux together.  I wanted this version to be cleaner and appear more organized.  The design of the first version was severely lacking and in my personal opinion, the Redux is a step forward.  While the last version was easier to customize, this version only requires a couple image changes, and some color updates in the <abbr title="Cascading Style Sheet">CSS</abbr>.</p>
<p>The only major roadblock I ran into was when testing in Internet Explorer 6.  The nested unordered lists weren&#8217;t displaying correctly due to the fact that percentages were used for widths in order to make the Redux easier to work with.  After determining the cause of the issue, the example was modified and the rendering was corrected.</p>
<h4>What would you change?</h4>
<p>As with the first version, I&#8217;m pleased with this version and feel it came out as well.  The Redux degrades gracefully (assuming worthy <code>alt</code> attributes are used).  After the original Suckerfish HoverLightbox was published, a few people suggested that the gallery was a bit invasive in that it appeared on rollover using <abbr title="Cascading Style Sheets">CSS</abbr>.  I took that into serious consideration when putting together the Redux, but elected to stay away from including more JavaScript.  To a degree, I do believe that the Redux is still a bit invasive in that it is very likely a reader will unintentionally roll over the gallery.  Do you think it&#8217;s better or worse that the Redux displays the images on rollover?  Should a version including JavaScript to toggle displays be put together?</p>
<p>I look forward to hearing any reactions to the Redux, in hopes of improving the example even further in the future.</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=67&c=867075622' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=67&c=867075622' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20070219/suckerfish-hoverlightbox-redux/feed/</wfw:commentRss>
		<slash:comments>164</slash:comments>
		</item>
		<item>
		<title>&#8226; My Latest Take on Image Replacement</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20061023%2Fmy-latest-take-on-image-replacement%2F&#038;seed_title=%26%238226%3B+My+Latest+Take+on+Image+Replacement</link>
		<comments>http://mondaybynoon.com/20061023/my-latest-take-on-image-replacement/#comments</comments>
		<pubDate>Mon, 23 Oct 2006 22:18:52 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[Accessibility]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Workbench]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Semantics]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2006/10/23/my-latest-take-on-image-replacement/</guid>
		<description><![CDATA[The new design got me thinking about image replacement techniques and I think I&#8217;ve come up with a good technique for solving the problem of readers with images disabled and CSS enabled.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=47&c=52343353' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=47&c=52343353' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>As you can see, <a href="/2006/10/23/it-was-time-for-a-change-so-i-did/" title="Overview of Monday By Noon Design Changes">the new layout</a> still sports image based headings for much of the reoccurring content around the site.  I took my usual approach of marking up and styling in that I began with bare XHTML 1.0 Strict and then added the <acronym title="Cascading Style Sheets">CSS</acronym> after that was totally complete.  As I got to the first image-based heading, I took some time to think about a better image replacement technique.</p>
<h2>The Problems with Image Replacement</h2>
<p>As you may know, image replacement can be a touchy subject.  Your aim should be to develop something that is equally usable by each and every person that finds their way to a site you designed and/or developed.  Including extra markup that isn&#8217;t semantic didn&#8217;t seem like a path I wanted to travel, so many of the &#8220;accepted&#8221; image replacement techniques were put aside.  The remaining choices left little to be desired if your reader happened to be viewing a site with images disabled and CSS enabled.</p>
<p>&#8220;Who does that?&#8221; you may ask. If I were to take a guess, it could be someone who is fairly Web-savvy and has the ability to use their browser in that particular fashion because they&#8217;re at a relatives house and stuck on a choking dial-up connection.  That&#8217;s just one of the possibilities, and I&#8217;m sure if we all put a few minutes into thinking about it, we could think of another situation in which we wanted to simply disable images only and get straight to the content.</p>
<h4>An Idea was Born</h4>
<p>As I thought about it, I went in a direction that others have gone before, in that the actual text wasn&#8217;t removed from display all together, it was merely camouflaged with the background.  I stuck with that technique because removing the words from display as step one doesn&#8217;t let you get much further with images disabled.</p>
<p>The trouble with camouflaging the text is that most of the time, disabling images simply leaves the &#8216;invisible&#8217; text on screen.  The text proves to be useless to a reader unless they disable CSS as well.  There had to be a better way.</p>
<h5>And That&#8217;s When it Came to Me</h5>
<p>It was at that point I began testing with a structured block element by giving a heading a specific height and width.  I gave that element a <code>background-color</code> that contrasted with the <code>color</code> in order to make the text visible again.  Once that was complete, everything else seemed to fall into place.</p>
<p>Since I had a block element with a height and width, I was able to cut out my desired image for replacement, and simply include it as the headings <code>background-image</code>.  A <em>crucial step</em>, however, is to leave yourself enough real estate to work with when cutting out the image.  What I mean by that is cutting out an extra couple dozen pixels at the top of the image, because that is where your text will reside.  The next step is to give the heading a <code>color</code> that matches the background color of the site (in order for the text to camouflage).  The last step is simply shrinking the <code>font-size</code> of the heading so that our content resides in the real estate we set aside.</p>
<p>To provide a visual example, here&#8217;s what results:</p>
<p><img src="/images/image_replacement.png" alt="Image of mouse highlighting camouflaged text" /></p>
<p><span id="more-47"></span></p>
<p>You can recreate just that on any of the image based headings around the site.  If you disable images, the black background appears and the text is now visible, albeit small.  Go ahead and bump the font size up a couple notches, the technique survives it for a bit.  I don&#8217;t think that many readers would feel the need to bump font size three or four levels, do you?</p>
<h3>Obvious Limitations to the Technique</h3>
<p>As with almost everything, there are certain limitations to using a technique such as this.  First and foremost, it won&#8217;t really work with anything but a solid color background.  Secondly, if a user were to increase their font size a few jumps, your text will begin to overlap the images you created and look like quite a big mess.  Lastly, first time (and some repeat) readers will see that stark background color you gave your heading and it may take them by surprise.  Once your CSS and images are cached the problem shouldn&#8217;t continue, but some people browse with their cache completely disabled.  Something like this might prove to be annoying to readers such as those.</p>
<p>Another thing that could be considered a limitation is the extra space you have to leave at the top of every heading.  Again, this was something that just fell into place with my design, I wanted the extra margin there as it was.  This method of image replacement won&#8217;t be the end all for other techniques; it just seemed to fit my goal set quite nicely.</p>
<h5>How do you Feel About the Technique?</h5>
<p>So far, I&#8217;ve had some mixed reactions to the technique.  Some people think it&#8217;s semantic and innovative while others don&#8217;t like the fact that the background color appears.  I can definitely see both sides, but I feel the semantic benefit of not including empty <code>&lt;span&gt;</code>s outweighs it in a way.</p>
<p>Find this useful?  <a href="http://digg.com/design/A_New_Take_on_CSS_Image_Replacement">Digg it</a>.</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=47&c=858355663' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=47&c=858355663' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20061023/my-latest-take-on-image-replacement/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
		<item>
		<title>&#8226; Beginning to Style Your RSS Feed</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20060814%2Fbeginning-to-style-your-rss-feed%2F&#038;seed_title=%26%238226%3B+Beginning+to+Style+Your+RSS+Feed</link>
		<comments>http://mondaybynoon.com/20060814/beginning-to-style-your-rss-feed/#comments</comments>
		<pubDate>Mon, 14 Aug 2006 11:59:59 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[beginner]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[RSS]]></category>
		<category><![CDATA[XSLT]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2006/08/14/beginning-to-style-your-rss-feed/</guid>
		<description><![CDATA[If you&#8217;re anything like me, RSS has completely changed the way you browse the Web.  It has become much easier to manage the abundance of content I want to read across the net; mostly due to RSS.  No longer must I make my way down a list of bookmarks, hoping to find an update here and there.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=34&c=923945380' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=34&c=923945380' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re anything like me, <acronym title="Really Simple Syndication">RSS</acronym> has completely changed the way you browse the Web.  It has become much easier to manage the abundance of content I want to read across the net; mostly due to RSS.  No longer must I make my way down a list of bookmarks, hoping to find an update here and there.</p>
<p>One of the major drawbacks to RSS is that its use hasn&#8217;t quite filtered down to your average user quite yet.  RSS might sound familiar, but knowing what it can be used for is less common. More often than not, when informing a client that we&#8217;ve equipped their new site with an RSS feed, my coworkers and I are presented with a look that expresses nothing but confusion.  Upon explaining what RSS is and the existing uses for the technology, the client still seems perplexed &#8212; almost as if to say &#8220;So what?&#8221;</p>
<p>Given the wide range of exposure surrounding RSS, I think it&#8217;s really important to handle your feed in a way that will be usable by as many people as possible.  One way to accomplish that is to apply a bit of structure and style to your feed in case an inexperienced user were to somehow find their way to your RSS via their browser.</p>
<h4>Applying CSS to your RSS</h4>
<p>It is possible to include a Cascading Style Sheet in the definition of your RSS feed using the following code snippet:</p>
<pre><code>&lt;?xml-stylesheet type="text/css" href="rss.css"?></code></pre>
<p><span id="more-34"></span></p>
<p>This line of code can be inserted just under the XML version declaration and the CSS will be applied to your document.  You can design the display of your style sheet in any way you please, using the XML tags provided in your feed.  Customization can become quite extensive using this method, and you can make great strides by applying a bit of CSS to your RSS.  Now when someone new to RSS decides to click on your <a href="http://feedicons.com">Feed Icon</a>, they won&#8217;t be faced with a document that looks like a foreign language.  A problem I have with this method, however, is that the user will be no more educated about RSS than they were before.  They still won&#8217;t know what they&#8217;re looking at, or the primary reason for it&#8217;s existence.  There is a better way.</p>
<p>I have read articles describing a few ways to add a bit more information to a feed that has been styled using CSS.  One suggestion was to add a few comments at the top of the file describing the purpose of the document and telling the user they&#8217;re viewing an RSS feed.  I wasn&#8217;t too pleased with this solution because it basically degrades the decent style you had going for you to begin with.  Luckily, there&#8217;s more you can do.</p>
<h2>Styling Your RSS with XSL and CSS</h2>
<p>By default, when navigating to any particular feed, you&#8217;re shown the raw markup of the document (depending on browser and RSS version).  Sometimes you&#8217;re not even shown the markup, but the actual copy of the content &#8212; unformatted and unstructured.  It should be known that the result varies among each version of RSS and browser.  Displaying source code or a document tree isn&#8217;t completely beneficial to a novice end user, no matter how you look at it.</p>
<p>Ideally, we would be able to use the content of our feed along with a predefined structure to introduce a viewer to RSS.  Given the power of <a href="http://www.w3.org/Style/XSL/">XSL</a>, you can do exactly that.</p>
<h3>What is XSL?</h3>
<p>XSL stands for Extensible Stylesheet Language, and it can be defined using the first few lines from the <a href="http://www.w3.org/Style/XSL/WhatIsXSL.html">W3C&#8217;s About XSL</a> page:</p>
<blockquote><p>XSL is a language for expressing style sheets. An XSL style sheet is, like with CSS, a file that describes how to display an XML document of a given type. XSL shares the functionality and is compatible with CSS2 (although it uses a different syntax).</p>
</blockquote>
<p>To make a long story short, XSL gives us the ability to restructure our feed should it be viewed in a browser via the location bar.  I highly suggest snooping around the <a href="http://www.w3.org/Style/XSL/">W3 spec of XSL</a> along with the <a href="http://www.w3.org/TR/xslt">XSLT 1.0 Spec</a> to really understand the inner workings of styling your RSS feed.</p>
<h3>Using XSLT in Conjunction with RSS</h3>
<p>In my opinion, if a user were to view my feed in a browser, it would be great to have an effectively styled document containing not only the information from the feed, but also a small explanation of the document.  You don&#8217;t want people to be using your feed by typing it into their browser do you?  If a novice user is faced with a styled RSS feed, they might be likely to do just that, all the while missing out on the true potential of RSS.</p>
<p>Take for example, the <a href="/feed">RSS feed of Monday By Noon</a>.  Using a few select pieces of XSLT, we can accomplish something just like that.  I think it&#8217;s nice that an unknowing user will be faced with an explanation of what it is they&#8217;re viewing before they start reading the actual content of my feed.  Hopefully it will give them a good starting point into discovering RSS and determining if it&#8217;s something they&#8217;re interested in.</p>
<h2>How to Apply XSLT to your RSS Feed</h2>
<p>To apply XSLT to your feed, you only have to perform a few steps.  First and foremost you must make an addition to your RSS.  Adding the following line of markup will tell the browser where to find  your XSL file:</p>
<pre><code>&lt;?xml-stylesheet href="rss.xsl" type="text/xsl" media="screen"?></code></pre>
<p>That is the only modification you&#8217;ll need to make in that file.  From there, you will need to create your XSL file, in this case, <code>rss.xsl</code>.  It is at this point you begin to have some creative freedom.  It&#8217;s important to keep in mind that you don&#8217;t want to go overboard and include an exact iteration of your site.  After all, you want the user to know that the document they&#8217;re viewing isn&#8217;t meant to be viewed in a browser, right?</p>
<p>Here is an example of the XSL being used on this site:</p>
<pre><code>&lt;?xml version="1.0" encoding="iso-8859-1"?>
&lt;xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
&lt;xsl:template match="/">
&lt;html>
  &lt;head>
    &lt;title>&lt;xsl:value-of select="rss/channel/title"/> RSS Feed&lt;/title>
    &lt;style type="text/css">
    @import url(rss.css);
    &lt;/style>
  &lt;/head>
  &lt;body>
    &lt;div id="explanation">
      &lt;h1>Monday By Noon RSS Feed&lt;/h1>
      &lt;p>You are viewing an &lt;acronym title="Really Simple Syndication">RSS&lt;/acronym> feed.  An RSS feed is a file
      allowing users a way to read updates to a website either through a third party RSS aggregator or other form of RSS
      syndication service.  You can find out more about the RSS file format at the
      &lt;a href="http://en.wikipedia.org/wiki/RSS_(file_format)">Wikipedia RSS entry&lt;/a>.&lt;/p>
      &lt;p>You may use the &lt;acronym title="Uniform Resource Locater">URL&lt;/acronym> of this document for any RSS purposes.&lt;/p>
    &lt;/div>
    &lt;div id="content">
      &lt;xsl:for-each select="rss/channel/item">
      &lt;div class="article">
        &lt;h2>&lt;a href="{link}" rel="bookmark">&lt;xsl:value-of select="title"/>&lt;/a>&lt;/h2>
        &lt;xsl:value-of select="description"/>
      &lt;/div>
      &lt;/xsl:for-each>
    &lt;/div>
  &lt;/body>
&lt;/html>
&lt;/xsl:template>
&lt;/xsl:stylesheet></code></pre>
<p>As with any markup language, it is very important that proper usage be researched.  I&#8217;m going to go over some of the basics of the file above, but if you plan on implementing something like this, take a look at the <a href="http://www.w3.org/TR/xslt">W3C XSLT 1.0 spec</a>.</p>
<p>Two of the most useful pieces of XSLT that are put into use above are <a href="http://www.w3.org/TR/xslt#value-of"><code>xsl:value-of</code></a> and <a href="http://www.w3.org/TR/xslt#for-each"><code>xsl:for-each</code></a>.  After taking a quick look at their usage, <code>xsl:value-of</code> allows us to pull data directly from the RSS feed, and using <code>xsl:for-each</code> allows us to &#8216;loop&#8217; through each of the items stored in our feed.  This allows us to format our data in a way we can effectively style for proper presentation to our reader.</p>
<p>Besides the ability to insert structural markup in our new document, XSLT also gives us the power to properly mark up a section of the document that explains the purpose of the file and gives the reader an outlet to find out more about the technology.  All this is possible while retaining the look and feel of our site in an effort not to scare our user.</p>
<p>As you can see, CSS is applied to the document using <code>@import url(rss.css);</code>.  If you take a look at the style, you can see it is short and to the point:</p>
<pre><code>* { margin:0; padding:0; }

html { display:block; background-color:#960000; padding-bottom:50px; }
body { font:80% Verdana, sans-serif; color:#000; background:#fff url(pagebg_rss.jpg) top left no-repeat; padding:25px 0 0 35px; }

a { color:#960000; }
a:hover { text-decoration:none; }

h2 { font-weight:normal; border-bottom:1px solid #960000; margin-bottom:0.4em; }
h2 a { display:block; margin-bottom:0.2em; text-decoration:none; color:#000; }

div { line-height:1.6em; }

div#content { background:#fff url(logo.jpg) bottom right no-repeat; margin-right:15px; padding:1em 0 55px 0; }
div#content div { margin:0 1em 1em 0; }

div#explanation { padding:1em 1em 0 1em; border:1px solid #ddd; background:#efefef; margin-right:2em; }
div#explanation h1 { font-weight:normal; font-size:1.8em; margin-bottom:0.3em; }
div#explanation p { margin-bottom:1em; }</code></pre>
<p>This CSS is applied just as it would be to a HTML document.  You can go into as much or as little detail as you&#8217;d like when customizing the output of your XSLT, but in my opinion the document should retain the brand and remain minimal.  It should include an area of information surrounding RSS, and help the user have a proper exposure to it.</p>
<h3>Why not Just Use FeedBurner?</h3>
<p><a href="http://feedburner.com">FeedBurner</a> has become quite a popular service for many sites offering RSS.  Using FeedBurner, you&#8217;re able to view certain statistics about your feed not otherwise available (such as how many readers you have).  Lots of people love statistics, so FeedBurner is the perfect way to get another stat not otherwise available to them.  If you have ever clicked on a FeedBurner link as opposed to copying the URL for other use, you&#8217;ll notice that you end up at a FeedBurner branded page using XSLT.  The page includes all of the latest updates related to the site you came from, along with information about FeedBurner.  While this is a decent result for the site owner, it&#8217;s nothing short of excellent for FeedBurner in terms of free advertisement.</p>
<p>Using a custom blend of XSLT and CSS you&#8217;re able to retain your brand in an attempt not to confuse your reader.  This may not outweigh the ability to track the statistics of your feed, and FeedBurner might be too great to pass up.  I don&#8217;t have extensive experience with FeedBurner, but from what I can tell, the markup of your posts is included in the browser rendered version, which also may be a drawback.  Again, this may not be a big deal to you &#8212; as with many things, it comes down to audience, circumstance, and personal preference.</p>
<h4>Don&#8217;t Browsers Apply Default Style to Feeds?</h4>
<p>While it&#8217;s true that some browser publishers have thought ahead and included the ability to apply a default style sheet and structure to various feeds, this also runs into the same issue as FeedBurner in that your branding is lost.  What&#8217;s good is that when the browser notices you&#8217;ve done custom work to style your feed, your markup and CSS is given precedence over the browser default.  While I think the idea of applying a default browser style is better than nothing, with a little effort you can have a far better result.</p>
<h3>Is this a Solution for You?</h3>
<p>Using XSLT and CSS to customize the display of your feed may or may not be something you&#8217;re interested in.  From what I can see, many people may not think there is much purpose to adding such functionality simply because it won&#8217;t be used.  My personal experience, however, tells me differently.  If nothing else, using this technique will help expose RSS to the those who have never heard of it before.  This method also provides an effective solution for those who don&#8217;t care about RSS and don&#8217;t want to know what it is or what it&#8217;s for, but at the same time they don&#8217;t want a link on their page directing people to a document tree.</p>
<p>Help spread the word: <a href="http://digg.com/design/HowTo_Apply_Markup_and_Style_to_Your_RSS_Feed">Digg this article</a></p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=34&c=1211800867' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=34&c=1211800867' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20060814/beginning-to-style-your-rss-feed/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>&#8226; Introducing MBN DuoTone Headings</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20060715%2Fintroducing-mbn-duotone-headings%2F&#038;seed_title=%26%238226%3B+Introducing+MBN+DuoTone+Headings</link>
		<comments>http://mondaybynoon.com/20060715/introducing-mbn-duotone-headings/#comments</comments>
		<pubDate>Sun, 16 Jul 2006 01:53:54 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[DOM]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Semantics]]></category>
		<category><![CDATA[Workbench]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[headings]]></category>

		<guid isPermaLink="false">http://mondaybynoon.com/2006/07/15/introducing-mbn-duotone-headings/</guid>
		<description><![CDATA[One thing that JavaScript is absolutely great for is enhancing the average browsing experience for your user.  On the other hand, requiring the presence of JavaScript compatibility can be an utter disaster.  In my opinion, JavaScript is great for visual or functional enhancements, but those features should not be necessary to make proper use of any particular document.  If a user doesn&#8217;t arrive equipped with the ability to run JavaScript, they shouldn&#8217;t know they&#8217;re missing out on anything.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=30&c=887788104' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=30&c=887788104' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p>One thing that JavaScript is absolutely great for is enhancing the average browsing experience for your user.  On the other hand, requiring the presence of JavaScript compatibility can be an utter disaster.  In my opinion, JavaScript is great for visual or functional enhancements, but those features should not be necessary to make proper use of any particular document.  If a user doesn&#8217;t arrive equipped with the ability to run JavaScript, <em>they shouldn&#8217;t know they&#8217;re missing out on anything</em>.</p>
<p><a class="viewDemo" href="/examples/mbn_duotone_headings/">MBN DuoTone Headings Demo</a></p>
<p>If you were to take a close look at the example heading in a browser supporting both JavaScript and CSS, not only would you realize it&#8217;s actually comprised of two colors, you would see that it isn&#8217;t using any images to create the effect.  Further inspection would show you that the following code was used to insert the heading:</p>
<pre class="sh_html"><code>&lt;h2 class="monday">To Make an Example&lt;/h2></code></pre>
<p>So what is creating the heading above?  To put it simply; that line of <acronym title="HyperText Markup Language">HTML</acronym>, a bit of <acronym title="Cascading Style Sheets">CSS</acronym>, and some manipulation of the <acronym title="Document Object Model">DOM</acronym> using JavaScript.</p>
<p><span id="more-30"></span></p>
<h2>How does it work?</h2>
<p>One of the major benefits to DOM scripting is the fact that it will degrade gracefully and allow a user without JavaScript the ability to continue proper use of the document he or she is viewing.  When it comes to the MBN DuoTone Headings, a user without a JavaScript compatible browser isn&#8217;t going to know they&#8217;re missing out on a two colored heading.  As stated above, this technique is purely for the visual enhancement of the average browsing experience.</p>
<p>If you&#8217;re able to see the DuoTone Heading above, it means that a script was able to scan through the markup of this document looking for headings given a certain class.  The script searches for the <code>class</code> because when it comes to headings, a designer or developer will often want to use the same style repeatedly.  Using the <code>id</code> would restrict use of the effect.  When the script finds any heading with this particular class, duplicates the original content with an additional <code>span</code>.  This change is made by manipulating the DOM, so those viewers who are browsing without JavaScript support will only see the original heading markup.  This is ideal because if the additional markup was present no matter what, viewers without JavaScript would see duplicate content for each header which would be very confusing.</p>
<p>Once the script has run its course, the style sheet is applied to the document and you are left with MBN DuoTone Headings.  A lot can be done with this technique as far as the CSS is concerned.  You can see a few other implementations by looking at the <a href="/examples/mbn_duotone_headings/">MBN DuoTone Headings Example Page</a>.</p>
<h3>Under the Hood</h3>
<p>To implement MBN DuoTone Headings, a small piece of JavaScript will be needed.  The first challenge was to insert a function that would locate each instance of a certain <code>class</code> within the markup.  Basic DOM scripting provides a method to find an instance of an element based on its <code>id</code>, but not by its <code>class</code>.  Luckily, <a href="http://dustindiaz.com">Dustin Diaz</a>, JavaScript connoisseur that he is, had written <a href="http://www.dustindiaz.com/getelementsbyclass/">getElementsByClass</a> and <a href="http://www.snook.ca/jonathan">Jonathan Snook</a> had <a href="http://www.snook.ca/archives/000370.php">written one too</a>.  Thanks to the function and a slight modification, we have the location of each heading with a <code>class</code> of &#8220;monday&#8221; using the following code:</p>
<pre class="sh_javascript"><code>/* Credit Where Credit is Due

getElementsByClass Written By: Dustin Diaz

http://www.dustindiaz.com/getelementsbyclass/

Slight minor modification by: Jon Christopher
      http://www.MondayByNoon.com                   */

function getElementsByClass(node,searchClass,tag) {
    var classElements = new Array();
    var els = node.getElementsByTagName(tag); // use "*" for all elements
    var elsLen = els.length;
    var pattern = new RegExp("\\b"+searchClass+"\\b");
    for (i = 0, j = 0; i &lt; elsLen; i++) {
         if ( pattern.test(els[i].className) ) {
             classElements[j] = els[i];
             j++;
         }
    }
    return classElements;
}

function showSpans() {
if(document.getElementsByTagName &amp;&amp; document.createElement){
    for (var l=1;l<=6;l++){
    var headingArray = getElementsByClass(document,'monday','h'+l);
        for ( var i=0, len=headingArray.length; i&lt;len; ++i ){
             var heading = headingArray[i];
                 var hString = headingArray[i].firstChild.nodeValue;
                 var span = document.createElement('span');
                 heading.appendChild(span);
                 span.innerHTML = hString;
        }
    }
    }
}

window.onload=showSpans;</code></pre>
<p>This particular piece of JavaScript is using <code>window.onload</code> so if you plan on implementing MBN DuoTone Headings on your own site, make sure it won't be interfering with other scripts you may have running.</p>
<p>The script will loop through every heading found and insert a <code>span</code> just after the heading content.  Within the span, a duplicate copy of the content is inserted.  That's the only purpose this script serves and it's all we need it to do, the rest is up to the CSS.</p>
<h3>The Style Sheet</h3>
<p>Giving any heading level a class of "monday" in the original markup will trigger the effect.  As stated before, a <code>span</code> with duplicate content is inserted next to the original heading content.  The following styles are then applied:</p>
<pre class="sh_css"><code>.monday {
    color:#369;
    position:relative; }

.monday span {
    color:#497eb2;
    height:0.55em;
    display:block;
    position:absolute;
    top:0; left:0;
    overflow:hidden; }</code></pre>
<p>The heading itself is given a <code>position:relative</code> which acts as a reference point for the <code>span</code>.  The <code>span</code> is styled with <code>position:absolute</code>, positioned to the top left of the heading and given a <code>height</code> of <code>0.55em</code>.  Using <code>em</code> will render as half of the parent elements font size, <a href="/2006/03/13/effective-style-with-em/">which is essential</a> for the technique.  Setting <code>display:block</code> and <code>overflow:hidden</code> allows us to cut the <code>span</code> in height to create the DuoTone effect.  Setting a different <code>color</code> to the <code>span</code> and its parent heading finishes the technique.</p>
<p>There are more effects you can generate by changing up the CSS a bit, some of which you can see on the <a href="/examples/mbn_duotone_headings/">MBN DuoTone Headings Example Page</a>.  You can download a zipped version of the example page below:</p>
<p><a class="zipDownload" href="/examples/mbn_duotone_headings/mbn_duotone_headings.zip" title="Download MBN DuoTone Headings">Download MBN DuoTone Headings</a></p>
<h4>Hasn't this Been Done Already?</h4>
<p>At the time of thinking up the idea for developing this script into something useful, I wasn't aware that Stu Nicholls had beat me to the punch by quite some time and showed off his own technique for <a href="http://www.cssplay.co.uk/mozilla/splittext.html">two-color headings</a>.  While disappointed I wasn't the first to come up with the idea, I felt it was still a worthy subject to touch upon.  Unfortunately, Stu Nicholls' two color headings reduce to a one color heading in Internet Explorer 6 using the star hack.  My testing so far has shown me that MBN DuoTone Headings render correctly in IE6.  I have also tested in Firefox, Opera and Safari and things seem to render correctly.  If anybody finds otherwise, please post your findings below.</p>
<h2>Semantics of this Technique</h2>
<p>As always, semantics come first when it comes to enhanced effects using JavaScript, CSS, or any other technology.  As I had stated above, the semantics in this example weren't compromised.  Manipulating the DOM allows us to only insert the extra markup if support is available.  One pitfall to the technique would be if the user had JavaScript support, but no support for CSS.  Although uncommon, it is a certain possibility and should be taken into account.</p>
<p>If you were to browse this example page using a text based browser such as Lynx you're faced with the following:</p>
<p><img src="/images/lynx/mbn_duotone.jpg" alt="Viewport of MBN DuoTone Headings using Lynx" /></p>
<p>The extra markup is not included if support isn't present.  A user viewing your document with a screen reader isn't going to have to deal with hearing each heading twice before moving on and you would be faced with the same result had you been navigating the document without JavaScript support.</p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=30&c=1773591387' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=30&c=1773591387' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20060715/introducing-mbn-duotone-headings/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>&#8226; Suckerfish HoverLightbox</title>
		<link>http://mondaybynoon.com/feeder/?FeederAction=clicked&#038;feed=Posts+%28RSS2%29&#038;seed=http%3A%2F%2Fmondaybynoon.com%2F20060327%2Fsuckerfish-hoverlightbox%2F&#038;seed_title=%26%238226%3B+Suckerfish+HoverLightbox</link>
		<comments>http://mondaybynoon.com/20060327/suckerfish-hoverlightbox/#comments</comments>
		<pubDate>Mon, 27 Mar 2006 15:14:55 +0000</pubDate>
		<dc:creator>Jonathan Christopher</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Examples]]></category>
		<category><![CDATA[Favorites]]></category>
		<category><![CDATA[Workbench]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[gallery]]></category>
		<category><![CDATA[hoverbox]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[intermediate]]></category>
		<category><![CDATA[lightbox]]></category>
		<category><![CDATA[suckerfish]]></category>

		<guid isPermaLink="false">http://www.mondaybynoon.com/2006/03/27/suckerfish-hoverlightbox/</guid>
		<description><![CDATA[The Suckerfish HoverLightbox is a mashup of three very popular Web design techniques blended together to offer a new way of presenting your image galleries.<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=14&c=1565594784' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=14&c=1565594784' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></description>
			<content:encoded><![CDATA[<p class="update"><strong>Update:</strong>  If you&#8217;re a fan of the Suckerfish HoverLightbox, you&#8217;ll probably like the <a href="/2007/02/19/suckerfish-hoverlightbox-redux/">Suckerfish HoverLightbox Redux</a>, a new and improved version.</p>
<p>From time to time I come across some truly impressive techniques that are a great blend of CSS, XHTML, and sometimes JavaScript.  Personally, I am not a big fan of implementing JavaScript, but it is sometimes unavoidable.  That is usually due to circumstances created by certain browsers that will remain named: <em>Internet Explorer</em>.  I was truly impressed by the development of the <a href="http://sonspring.com/journal/hoverbox-image-gallery">Hoverbox Image Gallery</a> written by Nathan Smith of <a href="http://www.sonspring.com">SonSpring</a>.  It was great to come across some optimization of the code by <a href="http://solardreamstudios.com/_img/learn/css/pg/">Craig Erskine</a> and I thought it was a really creative way to show a collection of images in a gallery.  After starting a project with a colleague, I was struck with an idea.  How would it look to blend this technique with a set of <a href="http://www.alistapart.com/articles/dropdowns/">Suckerfish Dropdowns</a> originally published by <a href="http://www.alistapart.com">A List Apart</a> (and <a href="http://www.htmldog.com/articles/suckerfish/dropdowns/">revised</a>)?  Take a look for yourself:</p>
<p><a class="viewDemo" href="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox/horizontal.html">Suckerfish HoverLightbox Demo</a></p>
<p>My initial reaction was that I thought it looked pretty neat and would be a nice way to present sets of images.  It then occured to me that it might be nice to include <a href="http://www.huddletogether.com/projects/lightbox/">Lightbox JS</a> written by Lokesh Dhakar in the mix.  Putting these techniques written by these great developers together resulted in quite an expandable image gallery.</p>
<p><span id="more-14"></span></p>
<h2>How it was Done</h2>
<p>Being that Suckerfish, Hoverbox, and Lighbox were all written in an organized and straightforward fashion, combining them was fairly simple.  I left the JavaScript files controlling the Suckerfish and Lightbox separate for organizational sake, and also used a separate stylesheet to control the Suckerfish and Lightbox style.  Being that all three techniques were developed to work cross browser, only minimal edits were required in the CSS to have the gallery behave how I wanted.</p>
<h3>Semantics of the Markup</h3>
<p>What we&#8217;re faced with here is a nested unordered list containing two levels.  The first level contains the gallery &#8216;names&#8217; if you will, and the second level contains the image thumbnails.  Semantically speaking, I think this markup is quite good.  After all, at the most basic level the only thing we&#8217;re dealing with is a list of images.  All markup is standardized and includes <code>alt</code> and <code>title</code> attributes.</p>
<h2>Usability and Accessibility</h2>
<p>A primary concern of mine is always the usability and accessibility of any given markup.  An object of a Web developer should always be to aim towards achieving maximum usability and accessibility of all their work.  A major usability issue that came up with the design of the Suckerfish HoverLightbox is inadvertantly hovering a top level list item which puts the contained thumbnails on display.  If the user doesn&#8217;t mean to view the thumbnails, they can be quite invasive.  One way to help this out is to provide enough real estate for your gallery so that if a user were to accidentally roll over a gallery heading, your content would not be hidden.</p>
<h3>Javascript Degradability</h3>
<p>One of my major issues with the inclusion of JavaScript is complete inoperability if I happen to have JavaScript disabled at the time.  If JavaScript can not degrade, I think a new solution should be looked into. The JavaScript in Suckerfish HoverLightbox controls the thumbnail display in Internet Explorer since it does not support psuedo <code>:hover</code> elements.  It also controls the entire Lightbox portion of the example.</p>
<p>If you were to view the example without a JavaScript enabled browser (excluding Internet Explorer), you wouldn&#8217;t notice a difference until clicking the image for the Lightbox.  Instead you are linked to the full resolution image, which makes sense given the circumstances.  If you happened to be viewing the example using a JavaScript disabled Internet Explorer, you would not be able to view the thumbnail galleries.  Instead you would only see the gallery headings, which would be a link to either a static page containing your thumbnails, or possibly to the directory in which your full resolution images are stored.  Given either situation, the example is less visually appealing, but still usable.</p>
<h3>Using a Text Browser</h3>
<p>There are definately people browsing the Web with text-based browsers.  Albeit a very small percentage, they&#8217;re still out there and developers should meet their needs.  Being that Suckerfish HoverLightbox is simply a two level nested unordered list, text-only output is very clean and organized.  The top level list items contain links to another page, and the second level contains links to images which can be downloaded by a text-based browser such as <a href="http://lynx.browser.org/">Lynx</a>.</p>
<p><img src="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox/images/lynx/suckerfish_hoverlightbox.jpg" alt="Screenshot of Lynx Viewport" /></p>
<p>Please excuse the small viewport, it is merely an example of what you would see had you been viewing this article (specifically the Suckerfish HoverLightbox example) using Lynx.</p>
<h3>Results on a Screen Reader</h3>
<p>When viewing this example using a screen reader, you will be faced with a very similar situation.  Given the circumstances of the example, that it is an image gallery, it is quite useless to someone viewing with a screen reader.  The point to take home here is that even if someone is viewing the example with a screen reader, they aren&#8217;t confused as to what you&#8217;re trying to get across.</p>
<p>If you are curious to see what a particular Web page renders as when using a screen reader, <a href="http://www.standards-schmandards.com/index.php?2004/11/22/8-fangs-release-05">Fangs</a> is a Firefox extension that emulates a screen reader.  It can be very helpful when evaluating the accessibility of your Web site.  Due to the semantic markup, you&#8217;re faced with a pretty self explanatory situation &#8212;  a list of galleries which hold a nested list of images.</p>
<h2>Examples</h2>
<p>I realize that an example tailored to the design of Monday By Noon is not very useful to the end user, so I have compiled a couple of vanilla examples for examination and download.  This example is very new to me and I encourage criticism and critique so that it can be refined to the most optimal end package for future use.</p>
<p><a class="zipDownload" href="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox/Suckerfish_HoverLightbox.zip" title="Download Suckerfish HoverLightbox">Download Suckerfish HoverLightbox</a></p>
<h3>Vanilla Horizontal Example</h3>
<p>I have included a horizontal example of Suckerfish HoverLightbox within this article, but there is also a <a href="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox/horizontal.html">vanilla horizontal version</a>.  I left it as basic as possible but also included some &#8216;before&#8217; and &#8216;after&#8217; text to mimic any given situation.  Minimal styles were included and the markup was not modified.</p>
<h4>Limitations of the Design</h4>
<p>First and foremost, the biggest limitation to the horizontal design is the problems you run into when you have more than a few gallery headings.  In this example, all gallery headings must be on one level because breaking into two levels would adversely affect the thumbnail views.  This is really the only major drawback to the horizontal design and can be tackled using a vertical version.</p>
<h3>Vanilla Vertical Example</h3>
<p>I originally worked on a <a href="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox/vertical.html">vertical example</a> of Suckerfish HoverLightbox because that is the situation in which it would be applicable to the project I was going over with my colleague.  In this example you can include a virtually limitless amount of galleries; however, I chose to include a horizontal version in this article because it seemed to fit better.</p>
<h4>Limitations of the Design</h4>
<p>At first glance, the drawback to this design is the amount of whitespace left behind.  Depending on the design, this can work to your disadvantage, especially when there is a large number of galleries.  When developing this example, I ran into a number of problems.  Initially I wanted all thumbnail views to display in the same position, which would result in a more consistent experience.  I quickly ran into problems when the top level list containing the gallery titles was taller than the thumbnail view itself.  For example if there was a list of 10 different galleries and the 9th gallery had only one thumbnail.  When this situation arose, I was unable to successfully hover the bottom gallery title, and actually use of the thumbnail to get to the Lightbox.  The thumbnail would dissapear as soon as I left the gallery title on the left.  This was due to leaving the <code>:hover</code> state of the gallery title anchor before hovering the nested list, resulting in the thumbnail view returning to a position of <code>left:-999px;</code> before we are able to make use of it.</p>
<p>I think the best way to illustrate the problem is visually:</p>
<p><img src="http://www.mondaybynoon.com/examples/suckerfish_hoverlightbox/images/height_problem.jpg" alt="Image depicting height problem" /></p>
<p>The outlines delegate the border of the unordered list containing the thumbnail images.  The red outline illustrates the height problem.  In order for the Suckerfish to work, the mouse needs to travel from point (a) which is its current position, to point (b) which is within the red boundary.  I first tackled this by setting the height of the container unordered list to auto, and then setting the height of the contained list to 100%.  After testing in Firefox I was pleased with the solution (left hand blue outline).  Unfortunately, Internet Explorer 6 did not render the lists height as 100% and therefore this was not an effective solution (right hand blue outline).  The solution I chose was to position of the contained unordered list at the same height of the associated list item (the gallery title) which solved this problem.  As a result, the thumbnail views are set to appear at the same height as the gallery heading to ensure usability, even if there is only one thumbnail present.</p>
<h3>Finishing Thoughts</h3>
<p>Overall, I feel that this is an effective way of presenting an image gallery using mostly CSS and only a small bit of JavaScript.  I do feel that it is really only an effective solution for a small to medium sized image gallery because of the design limitations.  It degrades well, is semantic, usable, accessible, and nice to look at.  I hope that other developers take a look at this example and write about any changes they would personally make.</p>
<p>Although Suckerfish, Hoverbox and Lightbox have been extensively tested for cross-browser compatibility, I was able to test on PC in Firefox 1.5.0.1, Internet Explorer 6, Internet Explorer 7 Beta 2, Netscape 8 and Opera 8.53.  On the Linux side I tested Firefox 1.5.0.1, Konqueror 3.4.3, Galeon 1.3.21, Mozilla 1.7.12, and Epiphany 1.8.2.  I was unable to perform any testing on the Mac platform, but will do so as soon as possible.</p>
<p><a href="http://digg.com/design/Tabbed_CSS_Gallery_combining_Hoverbox,_Suckerfish,_and_Lightbox.">Digg this Article</a></p>
<br /><p><a href='http://rss.buysellads.com/click.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=14&c=1103399037' target='_blank' rel='nofollow'>
				<img src='http://rss.buysellads.com/img.php?z=1269068&k=2ee344414ac81fbb0f9de6ab08e9831e&a=14&c=1103399037' border='0' alt='' /></a></p><p><a href='http://buysellads.com/buy/sitedetails/pubkey/2ee344414ac81fbb0f9de6ab08e9831e/zone/1269068' target='_blank'>Advertise here with BSA</a></p>]]></content:encoded>
			<wfw:commentRss>http://mondaybynoon.com/20060327/suckerfish-hoverlightbox/feed/</wfw:commentRss>
		<slash:comments>218</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Database Caching 9/120 queries in 0.128 seconds using apc
Object Caching 1833/2032 objects using apc

Served from: www.mondaybynoon.com @ 2012-02-11 08:49:37 -->
