<?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>onenaught.com &#187; General Web Development</title>
	<atom:link href="http://www.onenaught.com/posts/category/general-web-development/feed" rel="self" type="application/rss+xml" />
	<link>http://www.onenaught.com</link>
	<description>A blog on web standards, accessibility, css, javascript, xslt, and more</description>
	<lastBuildDate>Fri, 30 Jul 2010 13:55:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
<image>
		<title>One Naught</title>
		<url>http://www.onenaught.com/wp-content/themes/onenaught/images/onenaught.png</url>
		<link>http://www.onenaught.com</link>
		<width>116</width>
		<height>130</height>
		<description>OneNaught.com</description>
	</image>		<item>
		<title>CSS: inner elements breaking border-radius</title>
		<link>http://www.onenaught.com/posts/266/css-inner-elements-breaking-border-radius</link>
		<comments>http://www.onenaught.com/posts/266/css-inner-elements-breaking-border-radius#comments</comments>
		<pubDate>Thu, 09 Jul 2009 08:34:39 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[General Web Development]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/?p=266</guid>
		<description><![CDATA[Some browsers support border-radius for rounded corners. But inner elements may break those corners. Sometimes, applying border-radius to those inner elements can resolve the issue.]]></description>
			<content:encoded><![CDATA[<p>Browsers such as Firefox 2+ and Webkit-based browsers (Chrome, Safari) support the useful css <a href="http://www.w3.org/TR/2005/WD-css3-background-20050216/#the-border-radius">border-radius</a> feature (via -moz-border-radius and -webkit-border-radius, respectively).</p>
<p>Unfortunately inner elements can break rounded borders as Richard Rutter described when <a href="http://clagnut.com/blog/2273/">using <code>&lt;img&gt;</code> elements inside an element with <code>border-radius</code></a>. He also provided a useful solution which is webkit only, unfortunately.</p>
<p>Inner elements with background colors can also break border-radius. But there is a way around that too: <strong>apply <code>border-radius</code> to the offending inner elements too</strong>.</p>
<h3 id="toc-the-problem">The problem</h3>
<p>Here&#8217;s an example (view in Firefox 2+ or Safari/Chrome) where <code>border-radius</code> gets broken:</p>
<p>(If you are reading this in an RSS feed reader, you might need to <a href="http://www.onenaught.com/posts/266/css-inner-elements-breaking-border-radius">go to the page to see the example properly</a>)</p>
<p>A <code>div</code> containing a <code>blockquote</code> and a paragraph to mention the source of the quote:</p>
<div class="blockquote-with-source">
<blockquote>
<p>Fear is the path to the Dark Side&#8230; Fear leads to anger&#8230; anger leads to hate&#8230; hate leads to suffering&#8230;</p>
</blockquote>
<p class="source">— Yoda, <cite>Star Wars, Episode 1: The Phantom Menace</cite></p>
</div>
<p>Notice the bottom corners aren&#8217;t right: the background of the source paragraph breaks through the rounded corners.</p>
<p>The rounded corners are achieved using something like this:</p>
<pre class="syntax-highlight:css">
.blockquote-with-source {
  border:1px solid #e8eac8;
  border-radius:10px;
  -moz-border-radius:10px;
  -webkit-border-radius:10px;
}
</pre>
<p>(The above code is of course slightly more than necessary due to both mozilla and webkit implementing them via their rendering prefixes.)</p>
<h3 id="toc-the-ideal-solution">The ideal solution</h3>
<p><code>overflow:hidden</code> on inner elements should do the trick, but doesn&#8217;t work in Safari, Chrome or Firefox (although will work for the webkit-based ones for images as Richard Rutter points out in the above link).</p>
<h3 id="toc-workaround-for-non-image-elements-with-backgrounds">Workaround for non-image elements with backgrounds</h3>
<p>There are a few ways to work around this:</p>
<h4 id="toc-apply-border-radius-to-the-inner-element-breaking-the-rounded-corners">Apply border-radius to the inner element breaking the rounded corners</h4>
<p>If you are using background color (or background image) on the inner HTML element, you can apply <code>border-radius</code> to them too:</p>
<p>In the case of the above example, we just need rounded corners on the bottom left and bottom right of the source paragraph:</p>
<pre class="syntax-highlight:css">
.source {
    border-radius-bottomleft:10px;
    border-radius-bottomright:10px;
    -moz-border-radius-bottomleft:10px;
    -moz-border-radius-bottomright:10px;
    -webkit-border-bottom-left-radius:10px;
    -webkit-border-bottom-right-radius:10px;
}
</pre>
<p>The final styled quote would then look like this:</p>
<div class="blockquote-with-source">
<blockquote>
<p>Fear is the path to the Dark Side&#8230; Fear leads to anger&#8230; anger leads to hate&#8230; hate leads to suffering&#8230;</p>
</blockquote>
<p class="source with-fix">— Yoda, <cite>Star Wars, Episode 1: The Phantom Menace</cite></p>
</div>
<p>(If you inspect the above with Firebug or equivalent, you&#8217;ll notice I used slightly different CSS classes so it just fits with the current theme on this blog, but the principle is the same.)</p>
<h5 id="toc-drawback-to-the-above-workaround">Drawback to the above workaround</h5>
<p>The main one I can think of is that you have to maintain the border radius value in more than one place &#8212; CSS variables would be nice here <img src='http://www.onenaught.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<h4 id="toc-thick-enough-borders-hide-the-problem">Thick enough borders hide the problem</h4>
<p>If your design allows it, thick borders on the element using border-radius may do the trick.</p>
<p>In the example below, I use a thick border on the left side of the containing div, with border radius only on the bottom right of the source paragraph:</p>
<div class="blockquote-with-source with-thick-left-border">
<blockquote>
<p>Fear is the path to the Dark Side&#8230; Fear leads to anger&#8230; anger leads to hate&#8230; hate leads to suffering&#8230;</p>
</blockquote>
<p class="source with-fix">— Yoda, <cite>Star Wars, Episode 1: The Phantom Menace</cite></p>
</div>
<p>The thickness of the border is the same as the size of the radius, though you don&#8217;t have to do that.</p>
<h5 id="toc-drawback-to-the-above-workaround1">Drawback to the above workaround</h5>
<p>When using one thick border as above, it doesn&#8217;t render as nicely in webkit as it does in gecko. Don&#8217;t know if that is vagueness in the spec, or what&#8230;</p>
<p>However, if all four borders are given the same width, then it seems ok.</p>
<h3 id="toc-workaround-for-image-elements">Workaround for image elements</h3>
<p>As Richard Rutter commented, putting an image as a CSS background image would do the trick, but that isn&#8217;t always ideal or possible (e.g. an image that is important as part of the content is better marked up as <code>&lt;img&gt;</code>).</p>
<p>Are there other, perhaps better, ways to deal with this?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/266/css-inner-elements-breaking-border-radius/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Web Standards &#8211; a good thing, but won&#8217;t help with SEO</title>
		<link>http://www.onenaught.com/posts/256/web-standards-a-good-thing-but-wont-help-with-seo</link>
		<comments>http://www.onenaught.com/posts/256/web-standards-a-good-thing-but-wont-help-with-seo#comments</comments>
		<pubDate>Tue, 30 Jun 2009 13:16:02 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[General Web Development]]></category>
		<category><![CDATA[SEO]]></category>
		<category><![CDATA[web standards]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/?p=256</guid>
		<description><![CDATA[There are many good reasons to follow web standards principles, to use CSS-based layout and progressive enhancement but SEO, unfortunately, is not one of them.]]></description>
			<content:encoded><![CDATA[<p><strong>Update 30 June 2009</strong>: Added a couple of links at the end of this post for additional information from some recent research/experimenting.</p>
<p>Web standards is generally a good thing. When done well, it can help to create lean pages, improve markup quality, provide better accessibility and can be easier to maintain (even while supporting IE6!)</p>
<p>One claim often made in the past to promote web standards is that following web standards (using CSS-based layouts, proper use of heading elements in markup, etc) will improve SEO.</p>
<p>Though this might be desirable, it is not the case; most sites on the web don&#8217;t follow web standards and most rank very high in their areas. Search engines are not going to penalize the 90+ % of sites that don&#8217;t follow web standards; that&#8217;s like shooting themselves in the foot!</p>
<p>As I describe in an earlier post on <a href="http://www.onenaught.com/posts/30/explaining-natural-seo-search-engine-ranking-vs-indexing">search engine ranking vs indexing</a> while there are technical things one can do to ensure the site gets indexed well (e.g. URL canonicalization, good use of the &lt;title /&gt; element, etc), for ranking it is mostly about having good content that people will link to.</p>
<p>But as Matt Cutts, head of Google&#8217;s web spam team notes in this very short video, <a href="http://www.youtube.com/watch?v=fL_GZwoC2uQ">using CSS-based layouts or table-based layouts will have no bearing on search engine friendliness</a>:</p>
<p><object width="480" height="295"><param name="movie" value="http://www.youtube.com/v/fL_GZwoC2uQ&#038;hl=en&#038;fs=1&#038;"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/fL_GZwoC2uQ&#038;hl=en&#038;fs=1&#038;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="480" height="295"></embed></object></p>
<p>There are many good reasons to follow web standards principles, to use CSS-based layout and progressive enhancement but SEO, unfortunately, is not one of them.</p>
<p><strong>Update 30 June 2009</strong>: A couple of decent articles recently talk about similar things:</p>
<ol>
<li><a href="http://www.seomoz.org/blog/seo-best-practices-seomozs-new-policies-based-on-updated-correlation-data">SEO Best Practices: SEOmoz&#8217;s New Policies Based on Updated Correlation Data</a></li>
<li><a href="http://www.thegooglecache.com/uncategorized/the-triviality-of-on-page-html-tag-optimization/">The Triviality of On-Page HTML Tag Optimization<br />
</a></li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/256/web-standards-a-good-thing-but-wont-help-with-seo/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Use CSS display:table for Layout</title>
		<link>http://www.onenaught.com/posts/201/use-css-displaytable-for-layout</link>
		<comments>http://www.onenaught.com/posts/201/use-css-displaytable-for-layout#comments</comments>
		<pubDate>Sun, 15 Feb 2009 22:34:38 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[General Web Development]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/?p=201</guid>
		<description><![CDATA[<img class="post-img" align="left" src="/wp-content/uploads/ffx-css-display-table-post-img.jpg" alt="" /> For a few years now, web developers doing CSS-based layouts have used floats or absolute positioning for layout web sites to avoid using non-semantic HTML <code>&#60;table&#62;</code>s.

While doable, extra hoops often have to be jumped through (mostly for IE) and some seemingly simple things can be harder than necessary (like equal height columns).

However, for a simpler solution, CSS-based <code>display:table</code>, <code>display:table-row</code>, <code>display:table-cell</code> etc are all usable today across Firefox 2+, Safari 3+, Opera 9+ and IE8.]]></description>
			<content:encoded><![CDATA[<p><img class="post-img" src="http://www.onenaught.com/wp-content/uploads/ffx-css-display-table-post-img.jpg" alt="" /> I had this post in draft since October 2008. I thought I&#8217;d redesign this blog site using <code>display:table</code> and explain that in a series of posts, starting with this one. But I never found the time for the redesign! </p>
<p>Still, I have been using <code>display:table</code> on a much larger site for about 6 months now, so I thought I might as well post this as it is, and perhaps follow up with more examples later.</p>
<p>Also, about 3 weeks after I started this draft, <a href="http://www.digital-web.com/articles/everything_you_know_about_CSS_Is_wrong/">Rachel Andrew and Kevin Yank wrote a book on CSS <code>display:table</code> for layout, as well as a useful summary article</a>! I do recommend looking at that article for finer details.</p>
<h3 id="toc-no-need-for-css-float-for-layout-in-modern-browsers">No need for css float for layout in modern browsers</h3>
<p>For a few years now, web developers doing CSS-based layouts have used floats or absolute positioning for layout web sites to avoid using non-semantic HTML <code>&lt;table&gt;</code>s.</p>
<p>While doable, extra hoops often have to be jumped through (mostly for IE) and some seemingly simple things can be harder than necessary (like equal height columns).</p>
<p>However, for a simpler solution, CSS-based <code>display:table</code>, <code>display:table-row</code>, <code>display:table-cell</code> etc are all usable today across Firefox 2+, Safari 3+, Opera 9+ and IE8.</p>
<p>Example:</p>
<p>Consider the following HTML:</p>
<pre class="syntax-highlight:html">
&lt;body&gt;
	&lt;div id=&quot;header&quot;&gt;
		&lt;!-- header --&gt;
	&lt;/div&gt;

	&lt;div id=&quot;content-body-wrapper&quot;&gt;
		&lt;div id=&quot;content-body&quot;&gt;
			&lt;div id=&quot;primary-nav&quot;&gt;
				&lt;!-- some navigation column here --&gt;
			&lt;/div&gt;
			&lt;div id=&quot;secondary-nav&quot;&gt;
				&lt;!-- some additional column here --&gt;
			&lt;/div&gt;
			&lt;div id=&quot;content&quot;&gt;
				&lt;!-- main content here --&gt;
			&lt;/div&gt;
		&lt;/div&gt;
	&lt;/div&gt;

	&lt;div id=&quot;footer&quot;&gt;
		&lt;!-- footer --&gt;
	&lt;/div&gt;
&lt;/body&gt;
</pre>
<p>And the CSS to style it to get equal height columns:</p>
<pre class="syntax-highlight:css">
#content-body-wrapper {
    display:table;
    border-collapse:collapse;
}

#content-body {
    display:table-row;
}

#primary-nav, #secondary-nav, #content {
    display:table-cell;
}

#primary-nav, #secondary-nav {
    width:20%;
}

#content {
    width:60%;
}
</pre>
<p>And that&#8217;s it!</p>
<p>The above is just the layout bit of the CSS. Here are some screenshots (click for full size) with content and very basic styling just to see the equal height column effect:</p>
<p><a href='/wp-content/uploads/ffx-css-display-table.jpg' title='ffx-css-display-table'><img src="http://www.onenaught.com/wp-content/uploads/ffx-css-display-table-150x150.jpg" width="150" height="150" class="attachment-thumbnail" alt="" /></a> <a href='/wp-content/uploads/ie8-css-display-table.jpg' title='ie8-css-display-table'><img src="http://www.onenaught.com/wp-content/uploads/ie8-css-display-table-150x150.jpg" width="150" height="150" class="attachment-thumbnail" alt="" /></a></p>
<p>The first is with Firefox 3 and the second with IE8.</p>
<p>You can actually omit extra divs, even the one that gets display:table and the browser is required to create an anonymous table for you.</p>
<h3 id="toc-isnt-using-table-for-layout-wrong">Isn&#8217;t using table for layout wrong?</h3>
<p>This is not the same as using the <em>structural</em> html table elements for layout purposes &#8212; that indeed is an inappropriate use for tables.</p>
<p>This is using CSS to give table-like <em>display</em>, which is fine as it leaves the HTML (and document structure) in tact.</p>
<h3 id="toc-what-about-ie-7-and-6">What about IE 7 and 6?</h3>
<p>IE7 and 6 of course remain problems, but you can use conditional comments and give them older techniques that attempt to achieve this.</p>
<h3 id="toc-some-limitations-or-issues">Some limitations or issues</h3>
<p>Some limitations of css display:table I have come across, however, include these:</p>
<ul>
<li>Lack of colspan/rowspan equivalents</li>
<li>Like HTML tables, a CSS cell can expand in width based on content (as well as height).</li>
</ul>
<p>On the last one I noticed this when using things like <code>&lt;pre&gt;</code> even with overflow:auto with the thought that just like inside floated columns with widths assigned this would result in those <code>&lt;pre&gt;</code> blocks getting horizontal scrolls if they became too wide.</p>
<p>Instead, as with HTML tables, they push out the cell they are in. The only workaround I knew to this was to give a px or em width to such elements. (It also applies to large images in a cell.)</p>
<p>That being said, <code>display:table</code> seems a lot cleaner!</p>
<p>CSS3 has an advanced layout module in the works but there are not any browser implementations of it (that I am aware of), so in the interim this could be a useful approach.</p>
<h3 id="toc-more-info">More info</h3>
<ul>
<li><a href="http://www.w3.org/TR/CSS21/tables.html">W3C specifications on CSS display:table</a></li>
<li><a href="http://www.digital-web.com/articles/everything_you_know_about_CSS_Is_wrong/">Rachel Andrew: Everything you know about CSS is wrong</a></li>
</ul>
<h3 id="toc-translations">Translations</h3>
<p>Update: May 2010. Translated into <a href="http://pc.de/pages/vykarystanne-css-display-table">Belorussian</a>, by <a href="http://pc.de/">PC.de</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/201/use-css-displaytable-for-layout/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>ASP.NET Is a Leaky Abstraction</title>
		<link>http://www.onenaught.com/posts/42/aspnet-is-a-leaky-abstraction</link>
		<comments>http://www.onenaught.com/posts/42/aspnet-is-a-leaky-abstraction#comments</comments>
		<pubDate>Wed, 02 Jan 2008 18:41:44 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[General Web Development]]></category>
		<category><![CDATA[Server Side]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[markup]]></category>
		<category><![CDATA[XSLT]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/42/aspnet-is-a-leaky-abstraction</guid>
		<description><![CDATA[<img class="post-img" align="left" src="/wp-content/uploads/mona-unmasked.jpg" alt="A manipulation of the classic Mona Lisa shows her holding a mask revealing a smiling, ugly face." /> ASP.NET is a leaky abstraction because it tries to hide away some of the details of HTML markup generation for you when sometimes you need to know about the underlying markup.

In doing so, it is too easy to create ASP.NET sites that violate web accessibility guidelines and contain unnecessary markup bloat. In some cases, ASP.NET makes it really difficult to create the exact output you need. But there are a some options to address this problem.]]></description>
			<content:encoded><![CDATA[<p><img class="post-img" src="http://www.onenaught.com/wp-content/uploads/mona-unmasked.jpg" alt="A manipulation of the classic Mona Lisa shows her holding a mask revealing a smiling, ugly face." /> At work, we have been using .NET and C# since around 2002. Writing from a mid-tier development perspective, I have to admit I have liked it. However, writing as a web developer using <em>ASP</em>.NET (Microsoft&#8217;s attempt to abstract away the creation of HTML so that it can target non-web developers/mid-tier/VB-like developers to use their IDEs and platform) is another story!</p>
<p>ASP.NET has been problematic for many web developers/designers trying to do the &#8220;right thing&#8221;, such as</p>
<ul>
<li>Use web standards</li>
<li>Output semantically meaningful markup</li>
<li>Develop to standards, rather than browsers for cross-browser development</li>
<li>Use progressive enhancement concepts to cater for as many user preferences and technology limitations as possible</li>
<li>Create sites that are as accessible as possible without unnecessary trade-offs with the visual design</li>
<li>Create sites that are friendly for SEO</li>
<li>Create lean and optimal markup for quicker download</li>
<li>etc.</li>
</ul>
<p>(ASP.NET 1 was far worse, and version 2 allows many of the above to happen, but not all, and not always easily.)</p>
<p>Describing the problems caused by the poor quality and bloated markup and the weird/wonderful/complex/ugly/hacky ways to work around this seems to take ages. Some fans of ASP.NET don&#8217;t like to hear it when going into these details, and react defensively. And, to be fair, these problems are not unique to ASP.NET, either.</p>
<p>But recently, I rediscovered a summary explanation to help explain <em>why</em> ASP.NET is often problematic from a web developer&#8217;s perspective:</p>
<p><strong>ASP.NET is a <a href="http://www.joelonsoftware.com/articles/LeakyAbstractions.html">leaky abstraction</a></strong>:</p>
<p>That term, &#8220;leaky abstraction&#8221;, was coined some time ago (end of 2002) by Joel Spolsky, a prominent writer on software development and he was noting the problems with ASP.NET way back then.</p>
<blockquote cite="http://www.joelonsoftware.com/articles/LeakyAbstractions.html"><p>
In teaching someone about ASP.NET programming, it would be nice if I could just teach them that they can double-click on things and then write code that runs on the server when the user clicks on those things. Indeed ASP.NET abstracts away the difference between writing the HTML code to handle clicking on a hyperlink (&lt;a&gt;) and the code to handle clicking on a button. Problem: the ASP.NET designers needed to hide the fact that in HTML, there&#8217;s no way to submit a form from a hyperlink. They do this by generating a few lines of JavaScript and attaching an onclick handler to the hyperlink. The abstraction leaks, though. If the end-user has JavaScript disabled, the ASP.NET application doesn&#8217;t work correctly, and if the programmer doesn&#8217;t understand what ASP.NET was abstracting away, they simply won&#8217;t have any clue what is wrong.</p>
<p class="source">&#8211; <cite>Joel Spolsky, <a href="http://www.joelonsoftware.com/articles/LeakyAbstractions.html">The Law of Leaky Abstractions</a>, November 11, 2002</cite></p>
</blockquote>
<p>I think this is a decent summary description that can be useful for constructive discussion on what to do about it (if anything).</p>
<p><span id="more-42"></span></p>
<h3 id="toc-abstraction-without-understanding-problems">Abstraction without understanding = problems</h3>
<p>Of course, this is not just an ASP.NET issue, but a general problem in software development, as Spolsky added:</p>
<blockquote cite="http://www.joelonsoftware.com/articles/LeakyAbstractions.html"><p>
The law of leaky abstractions means that whenever somebody comes up with a wizzy new code-generation tool that is supposed to make us all ever-so-efficient, you hear a lot of people saying &#8220;learn how to do it manually first, then use the wizzy tool to save time.&#8221; Code generation tools which pretend to abstract out something, like all abstractions, leak, and the only way to deal with the leaks competently is to learn about how the abstractions work and what they are abstracting. So the abstractions save us time working, but they don&#8217;t save us time learning.</p>
<p>And all this means that paradoxically, even as we have higher and higher level programming tools with better and better abstractions, becoming a proficient programmer is getting harder and harder.</p>
<p class="source">&#8211; <cite>Joel Spolsky, <a href="http://www.joelonsoftware.com/articles/LeakyAbstractions.html">The Law of Leaky Abstractions</a>, November 11, 2002</cite></p>
</blockquote>
<p>This helps explain:</p>
<dl>
<dt>Why non-web developers or IE-only web developers like ASP.NET</dt>
<dd>It is an abstraction, so you don&#8217;t worry about it</dd>
<dt>Why web developers/designers despise ASP.NET</dt>
<dd>The abstraction leaks, horribly at times, and you <em>want</em> to worry about what is being abstracted</dd>
</dl>
<p>What is still interesting is that as a <em>software</em> developer (not necessarily a web specialist), Joel has understood some of the problems <em>web</em> developers and designers will have with .NET even though many Microsoft converts and ASP.NET fans do not!</p>
<p>Many software developers look down on web developers, thinking things like HTML and CSS are beneath them (its &#8220;just&#8221; the UI, or that JavaScript is not a real programming language, etc).</p>
<p>While those attitudes are generally changing, many software/mid-tier/non-web developers I come across still hold some of these views and don&#8217;t want to write anything in these languages, preferring the safety and familiarity of their IDE! (To be fair, some of these concerns are quite valid, too, and the principle for supporting the abstraction is actually often good; it is just that with web technology at the level it is at now, some of that abstract necessarily has to leak&#8230;)</p>
<h3 id="toc-negative-perception-of-ie-and-asp-net-for-web-developers">Negative perception of IE and ASP.NET for Web Developers</h3>
<p>It is interesting to note at various conferences like @media, @media AJAX, and on various blogs by noted web developers and designers, Microsoft gets a lot of stick for its IE web browser (as it is recognized as the poorest in quality of all the modern browsers, with the most bugs, biggest divergence from web standards and causing the most headaches for modern web development).</p>
<p>Indeed, since winning the &#8220;browser war&#8221; IE has stagnated and because of its dominance, web technologies have hardly changed in the last 10 years (we are still on HTML 4.01/XHTML 1.0, CSS 2.1 etc). As I posted earlier, <a href="http://www.onenaught.com/posts/44/microsofts-internet-explorer-slows-down-web-development">IE has slowed down web development progress</a> in recent years.</p>
<p>Combine that with the poor quality markup typically generated by ASP.NET, there has been a lot of criticism from the web development community aimed at Microsoft for either not caring about standards (or, as with ASP.NET 2 and <a href="http://www.onenaught.com/posts/46/microsofts-internet-explorer-8-to-speed-up-web-development">IE 8</a>) caring about it as an after thought or when threatened by rivals.</p>
<p>Here is quite a telling quote summarizing some of the implications:</p>
<blockquote cite="http://blogs.msdn.com/ie/archive/2007/11/30/the-first-year-of-ie7.aspx"><p>
I sympathize with your situation, but you desperately need to get your seniors and peers to understand what&#8217;s happening, and to assign your team way more resources.  IE is a first-impression MSFT product for most web developers, and yet you all continue to underestimate the dramatic spillover effect this poor developer experience has had and will continue to have on your other products and services.</p>
<p>Let me drive this point home. I am a front-end programmer and a co-founder of a start-up. I can tell you categorically that my team:</p>
<p>- Won&#8217;t download and play with Silverlight<br />
- Won&#8217;t build a Live widget<br />
- Won&#8217;t consider any MSFT search or ad products in the future</p>
<p>And the reason is because of IE &#8211; because MSFT disregards its most important relationship with us.  Until this relationship is repaired, nothing else stands a chance.</p>
<p>Please fight the good fight and drive this point home in your org.  Good luck.</p>
<p class="source">&#8211; <cite>Anonymous commenter to <a href="http://blogs.msdn.com/ie/archive/2007/11/30/the-first-year-of-ie7.aspx">The First Year of IE7</a>, November 30, 2007</cite></p>
</blockquote>
<p>It may be seem a bit harsh, as some developers and technical managers at Microsoft certainly seem to &#8220;get it&#8221;, but for whatever reason it has happened and left a sour taste in the mouths of many web designers and developers.</p>
<h3 id="toc-leaky-abstractions-lead-to-productivity-loss-and-unnecessary-trade-offs">Leaky abstractions lead to productivity loss and <em>unnecessary</em> trade-offs</h3>
<p>As I blogged earlier, <a href="http://www.onenaught.com/posts/4/should-web-developers-avoid-wysiwyg-editors">the WYSIWYG paradigm that Visual Studio and other such IDEs encourage, is often inappropriate for web development</a> as it encourages bad practice such as non-semantic markup.</p>
<p>The <em>perceived</em> productivity gains of such editors vanish when needing to deal with typical web related concerns (semantic markup, accessibility, progressive enhancement, SEO, etc). In fact, what often occurs is <em>unnecessary</em> trade-offs. E.g.</p>
<ul>
<li>A back-end developer uses an ASP.NET control that offers quick development with sophisticated capabilities just by dragging it onto a canvas and setting a few properties.</li>
<li>A web developer then claims that control is poor from all the web development perspectives and lists a number of things to change.</li>
<li>The back-end developer resists (especially if it comes from a &#8220;lowly&#8221; web developer!).</li>
<li>Trade-offs are then made (or not).</li>
<li>Reworking in full (if embraced at all) takes a long time.</li>
</ul>
<p>Even though ASP.NET 2.0 is far better than 1.x, the abstractions still leak; it is too easy to create sites that either</p>
<ul>
<li>Rely on JavaScript</li>
<li>Violate, or easily encourage ignoring, basic accessibility</li>
<li>Encourage further leaky abstractions because of the ease at which various ASP.NET controls can be created (the idea is good, but the fundamental leakage means that it will carry through to various controls).</li>
</ul>
<h3 id="toc-so-what-can-people-do">So what can people do?</h3>
<p>As an overall thought: <strong>by its nature, abstracting away HTML is almost guaranteed to result in a leaky abstraction</strong>.</p>
<p>Instead, it may be better to <strong>embrace the reasons for the leak, and provide cleaner separation while empowering people to work with the markup</strong>, given it is so crucial from so many perspective.</p>
<p>So here are some examples of a few ways to deal with the challenge, all with their merits for different purposes. Your mileage with each option will vary according to need. In addition, it is not a complete list; there may be other ways to achieve what you need:</p>
<h4 id="toc-strict-discipline-with-the-controls-you-choose-to-use">Strict discipline with the controls you choose to use</h4>
<p>The controls idea is certainly nice. ASP.NET and others (e.g. Java Server Faces) have put a lot of resources into this approach, and is certainly appealing from various perspectives (packaging components, reusability, productising components, etc).</p>
<p>Despite the problems, trying to stick with the <em>principle</em> of controls based abstraction may still be worth trying to pursue.</p>
<p>If so, I think it would require being VERY careful about third party controls you use, or purchase.</p>
<p>The other problem I see with this is in the case of medium/large teams; this strict discipline is unlikely to hold for too long, and eventually a developer with less experience on web development (or no inclination to do the web bit) will insist on using some poor quality controls that offer perceived productivity gains (&#8220;they can fix the problems you highlight to them!&#8221;, or &#8220;it looks okay&#8221;, or &#8220;people with accessibility needs don&#8217;t use the web, so it doesn&#8217;t matter!&#8221;).</p>
<p>Your mileage on this option will vary, depending on your team and project, etc.</p>
<h4 id="toc-inherit-and-override-problematic-controls">Inherit and override problematic controls</h4>
<p>Don&#8217;t like the way asp:label outputs its HTML? Override its Render() method. Same with any other control.</p>
<p>Sounds nice and easy enough, but this option is likely to run into trouble when someone invariably will want to use or integrate a composite, possibly third party, control written elsewhere that cannot be overridden (easily). So ASP.NET adaptors may be a better alternative than this one.</p>
<h4 id="toc-asp-net-control-adaptors">ASP.NET Control Adaptors</h4>
<p>Also known as CSS Adaptors (which reveals a fundamental misunderstanding; developers want semantic markup for all sorts of reasons, not just creating CSS-based layouts).</p>
<p>This approach tries to give developers the opportunity to clean up the HTML output by overriding the default implementation.</p>
<p>The kind of problems I see with this approach:</p>
<ul>
<li>Code examples I have seen that look awful &#8212; lots of string concatenations, obscure configuration settings, etc.</li>
<li>It may not always be easy to deploy a quick change after initial development (need to recompile a .NET Assembly, for example).</li>
</ul>
<p>Despite the potential problems, it may still be a useful option if there aren&#8217;t any other alternatives.</p>
<p>(Does this approach help prove the abstraction fails?)</p>
<h4 id="toc-do-nothing-wait-for-microsoft-to-fix-it">Do nothing (wait for Microsoft to fix it)</h4>
<p>It may seem odd to entertain an option of &#8220;do nothing&#8221;, but I often think this is an option that should be considered in many situations, if not just for completeness but because pondering on this may let you think out of the box, so to speak.</p>
<p>Why should this option be entertained for ASP.NET? Well, you could take the approach of:</p>
<ul>
<li>It&#8217;s not my problem; I just want to create cool apps</li>
<li>Microsoft will always fix it; we can just wait</li>
<li>If we get sued (accessibility compliance) or our bosses/managers complain, we can just blame Microsoft</li>
<li>The abstraction might be leaky now, but that doesn&#8217;t mean it always will &#8212; look at the improvement of ASP.NET 2 vs ASP.NET 1.x</li>
<li>I&#8217;m <em>so</em> fed up I have lost the will to live and do anything else other than just be assimilated <img src='http://www.onenaught.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
<li>Problems? What problems? (Already assimilated a long time ago <img src='http://www.onenaught.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  )</li>
</ul>
<p>And so on.</p>
<p>Needless to say, I would disagree with many of these perspectives. For example,</p>
<ul>
<li>I feel as a web developer, it is out responsibility to use the tools available to create sites that are as accessible to as wide an audience as possible.</li>
<li>Claiming ignorance, or actively avoiding issues you know are there somehow does not feel right.</li>
<li>Microsoft may certainly fix these issues over time. Reading blogs and interviews of key people in ASP.NET and Internet Explorer teams certainly gives some hope for the future, but it depends on whether you think you can wait or not (and whether you have enough information on when they will release specific fixes that are important to you).</li>
<li>The controls paradigm might always be leaky regardless of what is done. I think it would still be important to know the output that is being created in order to fully understand the implications of what you are creating. If there are problems with the site, you are likely to have to sort it out, not Microsoft (or any other vendor/framework you go for).</li>
</ul>
<p>For many web developers who know exactly what they need, having a tool do it for you, and to a lower quality, will be infuriating. Knowing it can be done better (not just for one&#8217;s own ego, but because it is good for the user/customer) can be compelling enough to want to do something about it.</p>
<p>Indeed, a principle behind a number of open source frameworks has been to try and make the web better, and keep it open because it is felt that open standards and related principles will lead to greater choice, diversity and vibrancy of the web. (Indeed, a lot of &#8220;Web 2.0&#8243; and the social web has come about because of open source technologies and ideas.)</p>
<h4 id="toc-use-an-open-source-alternative">Use an open source alternative</h4>
<p>Those loyal to Microsoft will not like to hear this, but this is a decent option in many scenarios.</p>
<p>As Simon Willison, co-creator of the popular <a href="http://www.djangoproject.com/">Django web framework</a> said a few years ago, one of the key benefits of the open source approach is <a href="http://simonwillison.net/2005/Nov/1/destiny/">you are in charge of your own destiny</a>.</p>
<p>(I&#8217;m not going to debate the open vs closed source paradigms here; that is not the purpose of this blog. I will just say that I didn&#8217;t use to buy the arguments of open source in the past, but in the last 3 or 4 years I have come to respect it a LOT more &#8212; I have not regretted moving to Linux at home recently, one bit, for example, and looking at the types of projects flourishing is quite encouraging.)</p>
<h4 id="toc-dont-use-asp-net-but-dont-throw-the-baby-net-out-with-the-bath-water-asp-net">Don&#8217;t use ASP.NET, but don&#8217;t throw the baby (.NET) out with the bath water (ASP.NET)</h4>
<p>Okay, so for some scenarios, completely changing platforms may not be an option.</p>
<p>In addition, I have to admit, programming in .NET (C# 2, etc) is nice.</p>
<p>Although Microsoft may be losing credibility with web developers because of the poor quality Internet Explorer browser and because of the problems of ASP.NET from a web designer&#8217;s perspective, .NET more generally is actually quite good.</p>
<p>Unlike on the Internet Explorer side of things, the MSDN blogs seem to be more active regarding on-going developments on .NET. <a href="http://weblogs.asp.net/scottgu/">Scott Guthrie, for example, has an immensely useful and popular blog</a> on all things about Visual Studio, ASP.NET etc. (Scott Guthrie is General Manager of development teams that build the .NET CLR and the core .NET Base Class Libraries, ASP.NET, Silverlight, IIS 7.0, Visual Studio Tools for ASP.NET, WPF and Silverlight.)</p>
<p>For some projects we have successfully used .NET but by-passed the ASP.NET controls, using XSLT instead.</p>
<h4 id="toc-xslt-an-open-standard">XSLT &#8212; an open standard</h4>
<p>Using XSLT to generate the output can be one way to overcome limitations of proprietary frameworks where you lack control of the output (ASP.NET) or where other frameworks may be open source but you have to learn their templating conventions.</p>
<p>XSLT can also make the markup generation simpler to unit test as part of a developer’s daily work, which is not always the case (or not necessarily as simple) in other templating systems, because you don&#8217;t have to be dependent on a running web server and all the set up that would come with it (thus making unit tests quick to run as well, increasing the likelihood of them being used and maintained).</p>
<p>Being platform agnostic, XSLT can be an effective part of a View in an MVC framework and be applied to different frameworks and platforms, reducing up-skilling costs in the long term.</p>
<p>If you consult or contract for a number of customers/clients, it would be nice if there was one common skill that is portable across all these frameworks (just like HTML/CSS/JavaScript typically is on the client side). XSLT could be such a thing, potentially, all the while giving you full control of the markup that you need to be create.</p>
<p>In my experience, and those of some of my colleagues at work, using XSLT to by-pass .NET controls has actually been more productive from an overall development perspective because we save time that would otherwise be needed battling the controls trying to force or work alternative markup options, building accessibility, etc. (And we have architected/developed sites for one of the largest online retailers in the world, so the strategies are not merely wishful thinking, but reasonably proven).</p>
<p>XSLT may not always be appropriate in all cases, and many are certainly put off by its oddities or perceived limitations. But, perhaps XSLT deserves another look?</p>
<p>(Indeed, a follow-up post does just that, starting by looking at <a href="http://www.onenaught.com/posts/8/xslt-in-server-side-web-frameworks">XSLT in server side web frameworks</a>.)</p>
<p>Do you find these problems with ASP.NET for your sites? How do you overcome them, or do you just stick with it?</p>
<h3 id="toc-image-credits">Image credits</h3>
<p>&#8220;Mona Unmasked&#8221; reposted with kind permission from <a href="http://www.flickr.com/photos/gx9/">gravityx9</a> from flickr. See the original image at <a href="http://www.flickr.com/photos/gx9/354387041/">http://www.flickr.com/photos/gx9/354387041/</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/42/aspnet-is-a-leaky-abstraction/feed</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Microsoft&#8217;s Internet Explorer Slows Down Web Development</title>
		<link>http://www.onenaught.com/posts/44/microsofts-internet-explorer-slows-down-web-development</link>
		<comments>http://www.onenaught.com/posts/44/microsofts-internet-explorer-slows-down-web-development#comments</comments>
		<pubDate>Fri, 14 Dec 2007 21:08:18 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[Browsers]]></category>
		<category><![CDATA[General Web Development]]></category>
		<category><![CDATA[ie]]></category>
		<category><![CDATA[internetexplorer]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/44/microsofts-internet-explorer-slows-down-web-development</guid>
		<description><![CDATA[<img class="post-img" align="left" src="/wp-content/uploads/ie-voodoo.jpg" alt="" /> This has been said so many times on the web by web developers frustrated at IE's rendering bugs, lack of progress in support for web technologies, and so on, that at first I didn't want to bother writing this post. However, a number of other posts on this site make reference to this point and I end up repeating myself, side tracking from the point at hand. For that reason, and for the benefit of some readers not familiar with this issue, this post serves as a summary of those concerns.]]></description>
			<content:encoded><![CDATA[<p><img class="post-img" src="http://www.onenaught.com/wp-content/uploads/ie-voodoo.jpg" alt="" /> This has been said so many times on the web by web developers frustrated at IE&#8217;s rendering bugs, lack of progress in support for web technologies, and so on, that at first I didn&#8217;t want to bother writing this post. </p>
<p>However, a number of other posts on this site make reference to this point and I end up repeating myself, side tracking from the point at hand. For that reason, and for the benefit of some readers not familiar with this issue, this post serves as a summary of those concerns.</p>
<p><span id="more-44"></span></p>
<h3 id="toc-ies-dominance-unquestioned">IE&#8217;s dominance unquestioned</h3>
<p><img class="post-img" src="http://www.onenaught.com/wp-content/uploads/ms-domination.jpg" alt="" /> There is no doubt that IE dominates the browser market share, from 90 to 60% depending on your demographics. IE 7 usage is on the rise as Microsoft pushes it out more, but IE 6 is still dominant too.</p>
<p>Where did this dominance come from? Was it from good quality software back in the late 1990s when the dominance started? Maybe, but it certainly wasn&#8217;t the only (main?) reason: during the browser wars with Netscape, as <a href="http://news.zdnet.com/2100-9595_22-6222606.html">ZDNet reminds us</a>, in 1998, &#8220;the U.S. Justice Department won a major judgment against Microsoft for competing illegally against another browser, Netscape.&#8221;</p>
<p>Back in those days of the browser wars, Microsoft was quite innovative. For example,</p>
<ul>
<li>They contributed to HTML 4, for example.</li>
<li>Microsoft&#8217;s proprietary conditional comments for example are ironically a good way to separate out all the IE-specific workarounds from the normal code</li>
<li>They even created the XMLHttpRequest object (XHR) almost a decade ago &#8212; ironically it wasn&#8217;t until a lot later that it was used on the client side for AJAX. And, while they had used it in Outlook Web Access, it wasn&#8217;t until Google and others started using it on a large scale that this technology took off.</li>
<li>IE 6 (a 2001 browser) introduced Doc Type switching so that if you declared the doc type in your HTML document (and did so <em>properly</em>), it would attempt to render according to W3C standards, not Microsoft&#8217;s own quirky implementations (known as Quirks mode). The importance of this one is not to be underestimated (it gave Microsoft a way of retaining backward compatibility while supporting standards rendering going forward).</li>
</ul>
<p>Of course, both they and Netscape also made some now embarrassing choices, too (Netscape&#8217;s, blink and font elements and Microsoft&#8217;s marquee, for example!)</p>
<p>But IE&#8217;s victory in the browser war for itself in the short term has resulted in created collateral damage, and possibly self-defeat.</p>
<h3 id="toc-innovation-stopped-after-dominance">Innovation stopped after dominance</h3>
<p><img class="post-img" src="http://www.onenaught.com/wp-content/uploads/rust-in-peace.jpg" alt="" /> Since IE won the browser wars and came out with IE6 with Windows XP in 2001, that also seemed to mark the end of their innovation. To be fair, for its time, IE6 was the best browser around. The problem is, given the speed at which things change on the Internet, it is now the <em>worst</em> mainstream web browser for developers to deal with; web technology has moved on, but Microsoft barely has (on this front).</p>
<p>It wasn&#8217;t until the start of the <a href="http://www.webstandards.org">Web Standards Project</a> that this began to change as people started coming together pressuring web browsers to improve, asking things like Why should developers have to waste so much time? Why can&#8217;t standards such as CSS be used across all browsers without coding for each browser (that you know of)? Why prevent people using your site?</p>
<p>This growing vocal discontent and Firefox&#8217;s rise contributed to the reasons IE7 made <em>some</em> improvements in IE7. Chris Wilson, platform architect for the IE team noted this a while back:</p>
<blockquote cite="http://blogs.msdn.com/cwilso/archive/2006/08/10/694584.aspx"><p>
&#8230; we prioritized IE7 around 3 things – security, end user experience, and standards improvements in the platform.  When I look back at the work my team has done in the platform, we have done only these things.  No proprietary features added, just standards improvements&#8230;.  I feel that we’ve addressed the biggest problems and shortcomings from IE6 for web developers and designers&#8230;  As I previously stated, our goal is to make the lives of web developers better by improving standards support in IE.  I think we’ve done a lot in IE7 to do just that, and I’m looking forward to doing even more.</p>
<p class="source">&#8211; Chris Wilson, <a href="http://blogs.msdn.com/cwilso/archive/2006/08/10/694584.aspx">IE and CSS &#8220;Compliance&#8221;</a>, August 10, 2006</p>
</blockquote>
<p>While IE7 is definitely an improvement, it is still a fair bit behind compared to other web browsers, from a development perspective. In addition, IE 6 remains prevalent.</p>
<p>(Its amazing to think how many problems IE6 has when one of they key focus points for IE7 was better standards support and there is still so much left to do to catch up with the others. If you follow some of the links to other posts, and read their comments you will see how vitriolic some people can get about this, as it is very frustrating for web developers.)</p>
<h3 id="toc-ie-stifles-creativity-or-makes-it-harder">IE stifles creativity (or makes it harder)</h3>
<p><img class="post-img" src="http://www.onenaught.com/wp-content/uploads/html-cannot-do-that.jpg" alt="" /> While IE 6 stagnated (and IE7 offered only a few improvements compared to what is really needed), other browsers have carried on, making web development through &#8220;Web Standards&#8221; important and possible (IE6 has enough of the basics to make this possible). Web developers have tried to move on too, but IE has hardly budged, thus slowing down real progress.</p>
<p>Well-known web designer, Andy Clarke, and an &#8220;invited expert&#8221; on the CSS Working Group at the W3C (where a lot of the specifications for things like HTML, CSS, XML, XSLT etc are made), recently made the following point:</p>
<blockquote cite="http://www.stuffandnonsense.co.uk/malarkey/more/css_unworking_group/"><p>
Along with web designers worldwide, I have been creatively stifled by Microsoft&#8217;s decision to allow Internet Explorer 6 for Windows to languish in the doldrums for so many years. With their significant market-share, Microsoft should have been at the forefront of technical development and standards support in browsers. That would have fostered an ever increasing focus on what can be possible using CSS. Instead Microsoft allowed their lead to hinder progress and web designers, developers, their clients and their customers have all suffered as a result.</p>
<p class="source">&#8211; <cite>Andy Clarke, <a href="http://www.stuffandnonsense.co.uk/malarkey/more/css_unworking_group/">CSS Unworking Group</a>, Stuff and Nonsense, December 14, 2007</cite></p>
</blockquote>
<p>In some cases it has stifled creativity, in other cases, it requires a lot of workaround which leads to excess code (and all the costs that are associated with that).</p>
<p>Rather than go into the technical details that plague the browser here, such as the multitude of bugs, lack of CSS support, lack of W3C DOM Support, here are some resources that do just that:</p>
<ul>
<li><a href="http://www.quirksmode.org/">Quirks Mode</a> by Peter Paul-Koch (ppk) lists all sorts of browser incompatibilities</li>
<li><a href="http://www.positioniseverything.net/">Position is Everything</a> to explain CSS bugs</li>
<li>Gérard Talbot has listed <a href="http://www.gtalbot.org/BrowserBugsSection/">numerous CSS bugs for browsers</a> with IE topping the list.</li>
</ul>
<p>What&#8217;s also interesting about Talbot&#8217;s page for <a href="http://www.gtalbot.org/BrowserBugsSection/MSIE7Bugs/">IE7 CSS bugs</a> is that it has a number of quotes and rants about IE&#8217;s impact on web development:</p>
<blockquote cite="http://blogs.msdn.com/cwilso/archive/2006/08/10/694584.aspx#695711"><p>
Until IE is reasonably standards-compliant you can expect no quarter from us. We&#8217;ve spent too much time designing web sites that will work for CSS and then work for IE. We&#8217;ve destroyed budgets, pissed off our bosses, irritated clients and made development more expensive because of [IE].</p>
<p class="source">&#8211; <cite>a comment to Chris Wilson&#8217;s post, <a href="http://blogs.msdn.com/cwilso/archive/2006/08/10/694584.aspx#695711">IE and CSS &#8220;Compliance&#8221;</a>, August 10, 2006</cite></p>
</blockquote>
<p>This comment to another post from the IE blog was made back in 2004 and is unfortunately still relevant today:</p>
<blockquote cite="http://blogs.msdn.com/ie/archive/2004/07/21/190747.aspx#190979"><p>
I author to standards, it takes a few minutes to tweak things to get everything perfect in browsers like Firefox and Safari, and then ages to work around all of Internet Explorer&#8217;s bugs and shortcomings. The time to implement a decent XHTML Strict + CSS 2 design would be shortened by at least a third if Internet Explorer wasn&#8217;t so buggy. I have measured this personally across a number of projects.</p>
<p>&#8230; CSS 2 is over six years old, and Microsoft have had employees in the CSS working group the whole time&#8230;. Given that Microsoft are the world&#8217;s biggest software company, it looks very much like standards are deliberately being sabotaged. Is it any wonder web developers are starting to get royally pissed off with Microsoft?</p>
<p class="source">&#8211; <cite>a comment to a post on the IE Blog, <a href="http://blogs.msdn.com/ie/archive/2004/07/21/190747.aspx#190979">I love this browser!</a>, IE Blog, July 21, 2004</cite></p>
</blockquote>
<p>Alex Russell, a prominent web developer and creator of the popular <a href="http://www.dojotoolkit.org/">Dojo JavaScript toolkit</a> highlights the pain caused:</p>
<blockquote cite="http://alex.dojotoolkit.org/?p=536"><p>
Here&#8217;s a little hint to whoever is the PM in charge of the renewed IE 7 effort: we don&#8217;t care. We don&#8217;t care how much it costs you. We&#8217;ve been cleaning up your messes for *years*. Those of us tasked with &#8216;just making it work&#8217; have spent so many sleepless days and nights routing around IE brokenness that our empathy and sympathy are entirely tapped out. All that&#8217;s left is a combination of despair and loathing. You want us to give a (expletive) that you blog and are &#8216;engaging with the community&#8217;? Fine. Fix your (expletive) browser. That&#8217;s the bar the IE 7 team needs to hurdle.</p>
<p class="source">&#8211; <cite>Alex Russell, <a href="http://alex.dojotoolkit.org/?p=536">How IE7 Can Avoid Irrelevance</a>, January 22nd 2006</cite></p>
</blockquote>
<h3 id="toc-economic-wastage">&#8220;Economic Wastage&#8221;</h3>
<p><a href="http://www.i-marco.nl/weblog/archive/2006/06/24/time_breakdown_of_modern_web_d" title="Click image to see full size/source"><img src="http://www.onenaught.com/wp-content/uploads/web-breakdown.png" alt="Almost 50% of the time is wasted sorting out IE!" width="445" /></a></p>
<p>Okay, so the above pie chart (<a href="http://www.i-marco.nl/weblog/archive/2006/06/24/time_breakdown_of_modern_web_d">from Marco van Hylckama Vlieg</a>, a web developer working for Yahoo! Europe) is a bit of fun, but reveals underlying frustrations (and while maybe at the time the image was created some CSS layouts were frustrating enough to contemplate table-layout, I think for the past year or two that has not been necessary! Also, if any one knows what Firefox JavaScript space issue the image is referring to, please drop a comment!)</p>
<p>In a way, IE therefore has contributed to a lot of &#8220;economic wastage&#8221; that others bear the brunt of.</p>
<p>For example, there are</p>
<ul>
<li><strong>Unnecessary trade-offs</strong>, such as reduced features, less or no accessibility considerations, limited cross-browser compatibility, extra code bloat, etc.</li>
<li><strong>Extra costs</strong>, such as hiring more web developers than actually necessary in an effort to deliver on time, or assigning more time to the project, or just accepting that this is how web development is done, not realizing it can be better if web standards formed the basis of web development.</li>
</ul>
<p>These costs are borne by companies, organizations, and individuals, not Microsoft.</p>
<p>This results in <strong>wasted capital</strong> and a <strong>slow rate of evolution for the web</strong>.</p>
<p>Reading the comments from developers on some of the IE Blog&#8217;s recent posts, reveals just how frustrating web development has been at times:</p>
<ul>
<li><a href="http://blogs.msdn.com/ie/archive/2007/11/30/the-first-year-of-ie7.aspx">The First Year of IE7</a></li>
<li><a href="http://blogs.msdn.com/ie/archive/2007/12/05/internet-explorer-8.aspx">Internet Explorer 8</a> &#8212; this was meant to be light humor on how Bill Gate announced that the next version of IE would be called IE8 (a no-brainer?) but the comments revealed the real concern was lack of progress, features, insight into IE development.</li>
<li><a href="http://blogs.msdn.com/ie/archive/2007/10/30/ecmascript-3-and-beyond.aspx">ECMAScript 3 and beyond</a> &#8212; although this post is about a wider debate on ECMAScript, the comments reveal frustration at JScript (Microsoft&#8217;s implementation of ECMAScript, which we otherwise typically call JavaScript) and its numerous problems</li>
</ul>
<p>The JavaScript 2/ECMAScript 4 debate is interesting in that another influential player, Yahoo!, has joined Microsoft saying they don&#8217;t like the proposed changes (proposed/supported by Mozilla/Adobe/Apple). At a recent conference at <a href="http://www.onenaught.com/posts/37/day-2-media-ajax-november-2007">@media AJAX, Douglas Crockford said that amongst other things it was IE6 that was holding back real JavaScript improvements</a> (because while it remains a prevalent browser, any changes introduced to JavaScript either won&#8217;t be backward compatible enough, or won&#8217;t help address fundamental security problems which IE6 in particular is vulnerable to. This is a big enough issue itself, which I won&#8217;t go into here.)</p>
<h3 id="toc-how-microsoft-can-redeem-itself">How Microsoft can redeem itself?</h3>
<p>Microsoft can easily rectify the problem: they have the resources to put people into sorting out the issues if they really wanted to (they will when threatened by competition, as Firefox&#8217;s rise showed, but many still regard them as a monopoly and thus have very little incentive to move ahead significantly at this time).</p>
<p>On the plus side, they have people on board, like Chris Wilson, that generally get the grievances developers hold and wants to see progress on this front.</p>
<p>Aggressively supporting efforts like <a href="http://www.onenaught.com/posts/category/html-5">HTML 5</a>, maybe JavaScript 2, etc, will be a chance to start afresh and provide decent implementation.</p>
<p>(Reading posts on HTML 5, there is much skepticism that it will happen in a meaningful timeframe in such a way that it will be used mainstream &#8212; not because of the slow standards-defining process (though that certainly may be part of it) but because of IEs dominance and slow movement in these areas.)</p>
<p>None of this is easy by any means, but it has taken some 5 years to get some progress from IE6 to IE7 and it still lags behind the others.</p>
<p>Vendor-specific implementation is okay, (maybe even encouraged?) but standards should form basis from which these extensions are made.</p>
<p>When IE 7 first came out, Microsoft said they would release more frequently, every three quarters to a year would be a new release. One year on from IE7 and the best we have is the announcement that the next version will be called IE 8 and growing frustration at how little information there is now coming out from Microsoft about any solid plans for IE 8.</p>
<p>So maybe their priorities, from a web development perspective, would be to</p>
<ul>
<li>Become more open and tell developers what they are planning and when for</li>
<li>Actually fix all the remaining CSS and JScript bugs</li>
<li>Complete HTML 4/XHTML 1.0 support (e.g. the <code>&lt;q&gt;</code> element would be nice, as well as the XHTML mime type)</li>
<li>Provide far better CSS 2.1 support (maybe even start supporting some CSS 3 features)</li>
<li>Provide far better W3C DOM support to make JavaScript development (and execution) more efficient</li>
</ul>
<p>This is not a complete list, and there are all sorts of posts on the web and to the IE Blog with better lists, but you get the idea.</p>
<p>Here is one ominous warning for Microsoft of not doing so:</p>
<blockquote cite="http://blogs.msdn.com/ie/archive/2007/11/30/the-first-year-of-ie7.aspx"><p>
I sympathize with your situation, but you desperately need to get your seniors and peers to understand what&#8217;s happening, and to assign your team way more resources.  IE is a first-impression MSFT product for most web developers, and yet you all continue to underestimate the dramatic spillover effect this poor developer experience has had and will continue to have on your other products and services.</p>
<p>Let me drive this point home. I am a front-end programmer and a co-founder of a start-up. I can tell you categorically that my team:</p>
<p>- Won&#8217;t download and play with Silverlight<br />
- Won&#8217;t build a Live widget<br />
- Won&#8217;t consider any MSFT search or ad products in the future</p>
<p>And the reason is because of IE &#8211; because MSFT disregards its most important relationship with us.  Until this relationship is repaired, nothing else stands a chance.</p>
<p>Please fight the good fight and drive this point home in your org.  Good luck.</p>
<p class="source">&#8211; <cite>Anonymous commenter to <a href="http://blogs.msdn.com/ie/archive/2007/11/30/the-first-year-of-ie7.aspx">The First Year of IE7</a>, November 30, 2007</cite></p>
</blockquote>
<h3 id="toc-do-we-ironically-thank-microsoft-for-this-mess">Do we ironically thank Microsoft for this mess?</h3>
<p>In many regards, the evolution of the web has been slow, and we should have been a lot further down the line than we are now.</p>
<p>For example, HTML 5 should perhaps be a lot closer to reality, Accessible AJAX apps should be the norm, not the exception, CSS3 should be widespread, etc.</p>
<p>Finally, one thought: would this have really happened without IE&#8217;s problems? One can never know for sure. Were it not for the problems IE caused, could it be that the frustration that led to better awareness of web standards would never have been nurtured? Ironically, do we have to thank Microsoft for making our lives so hard that we now have some ideas of how it could be better?!</p>
<h3 id="toc-image-credits">Image credits</h3>
<ul>
<li><a href="http://www.flickr.com/photos/chisa/1349759901/">Internet Explorer Voodoo Doll</a>, by chisa, posted on Flickr</li>
<li><a href="http://www.flickr.com/photos/dasbull/422814442/">Rust in Peace</a>, by dasbull, posted on Flickr</li>
<li><a href="http://www.flickr.com/photos/27812804@N00/85595853/">Microsoft World Domination 99</a>, by kelly varner, posted on Flickr</li>
<li><a href="http://www.flickr.com/photos/thefangmonster/490423135/">HTML Cannot Do That</a>, by Noah Sussman, posted on Flickr</li>
<li><a href="http://www.i-marco.nl/weblog/archive/2006/06/24/time_breakdown_of_modern_web_d">Time breakdown of modern web design</a> via Marco van Hylckama Vlieg</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/44/microsofts-internet-explorer-slows-down-web-development/feed</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>The Email Standards Project</title>
		<link>http://www.onenaught.com/posts/39/the-email-standards-project</link>
		<comments>http://www.onenaught.com/posts/39/the-email-standards-project#comments</comments>
		<pubDate>Thu, 29 Nov 2007 13:05:17 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[General Web Development]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/39/the-email-standards-project</guid>
		<description><![CDATA[<p><img src="/wp-content/uploads/email-standards-project.png" alt="The Email Standards Project" class="post-img" align="left" /> HTML-based email seems to be a mess, with different email clients supporting a different set (and sub-set) of web technologies such as HTML and CSS.</p>

Microsoft's Outlook has a commanding share of desktop email clients. However, Microsoft announced that Outlook 2007 would use Word's HTML rendering engine, rather than Internet Explorer's which seems like a big step backward.

While some may prefer text-only email, others prefer to -- or must -- create HTML-based email.

The Email Standards Project is attempting to follow the example of the Web Standards Project, but for email clients, web- and desktop-based to try and make HTML-email creation less hit and miss.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.email-standards.org/" class="post-img"><img src="http://www.onenaught.com/wp-content/uploads/email-standards-project.png" alt="The Email Standards Project" /></a> HTML-based email seems to be a mess, with different email clients supporting a different set (and sub-set) of web technologies such as HTML and CSS.</p>
<p>Microsoft&#8217;s Outlook has a commanding share of desktop email clients. However, Microsoft announced that Outlook 2007 would use Word&#8217;s HTML rendering engine, rather than Internet Explorer&#8217;s which seems like a big step backward.</p>
<p>While some may prefer text-only email, others prefer to &#8212; or must &#8212; create HTML-based email.</p>
<p>The Email Standards Project is attempting to follow the example of the Web Standards Project, but for email clients, web- and desktop-based to try and make HTML-email creation less hit and miss.</p>
<p><span id="more-39"></span></p>
<h3 id="toc-html-email-is-a-mess">HTML-email is a mess</h3>
<p>Anyone who has tried to do html email in the past knows that it is an even more mixed beast than regular web development.</p>
<p>These days, on the web, at least there is a reasonable formula of web standards using CSS-based designs, etc. With HTML email, some clients only support text, others only some HTML, only some CSS, no CSS, while others will edit/strip your content.</p>
<h3 id="toc-outlook-2007-takes-a-step-backwards">Outlook 2007 takes a step backwards?</h3>
<p>Around January 2007, there was a bit of a storm when Microsoft announced that it&#8217;s Office 2007 Outlook client would use Word&#8217;s HTML rendering, not Internet Explorer&#8217;s for displaying HTML email.</p>
<p>For many web developers, this seemed immensely backward. Word&#8217;s HTML output is notoriously bloated and, quite frankly, rubbish.</p>
<p>However, it seems that the reason was for consistency with Word and for between Outlook users primarily, as users were typically using Word to compose such messages and more likely to send to another Outlook user, given its commanding share amongst email desktop clients.</p>
<p>Outlook&#8217;s wide usage cannot not just be ignored, so how to developers deal with this?</p>
<h3 id="toc-what-about-text-only-email">What about text only email?</h3>
<p>In some of the links presented below it is interesting to read the comments on those posts from many people who have very little sympathy for people struggling with the HTML-based email challenges.</p>
<p>My personal view/preference is in favour of plain text email and having switched recently to Linux/KDE and KMail, which only supports plain text, I find it far better than trying to understand HTML emails with disabled images that don&#8217;t have alt text or have broken layouts!</p>
<p>However, many people do desire &#8212; or require &#8212; that HTML-based emails be created, so for them, this can be a real problem.</p>
<p>(Even when HTML-email is required sending a plain text version with the HTML version is important for those who cannot see HTML email or have it disabled.)</p>
<h3 id="toc-simple-html-only">Simple HTML Only?</h3>
<p>Some advocate using the simplest layout tables in HTML, which are shunned upon by most standards-aware web developers for all the problems (accessibility, maintenance etc) that it causes.</p>
<p>Simpler HTML, limited to just a few headings, paragraphs, lists, etc may offer improved readability over just plain text. However, this also seems to defeat the purpose of HTML email, especially for marketers and advertisers.</p>
<h3 id="toc-the-email-standards-project">The Email Standards Project</h3>
<p>The <a href="http://www.email-standards.org/">Email Standards Project</a>, in a similar way to what the Web Standards Project did for web browsers and web developers, is trying to get email clients to follow standards better. They have an <a href="http://www.email-standards.org/acid-test/">email client acid test</a> and a report on <a href="http://www.email-standards.org/clients/">web standards support in popular email clients</a>.</p>
<p>It will be interesting to see how this works out&#8230; Will they get Outlook to change? Hard to tell, although the following may be encouraging (from one of the web standards most well known advocates, Molly Holzschlag, who now works at Microsoft):</p>
<blockquote cite="http://www.campaignmonitor.com/blog/archives/2007/01/the_truth_behind_the_outlook_2.html"><p>
Microsoft was very clear in letting me know that if we want a feature and need it and get an organized list to them, those issues will be addressed and prioritized as the new engine develops in response to developer needs, too.</p>
<p>&#8230; I&#8217;m now working directly with Microsoft, and I can honestly say that their software developers by and large get it completely. They aren&#8217;t our problem, and never really have been.</p>
<p>It&#8217;s the business decisions that drive the technology decisions. </p>
<p class="source">&#8211; <cite>Molly Holzschlag, quoted by, and commenting in <a href="http://www.campaignmonitor.com/blog/archives/2007/01/the_truth_behind_the_outlook_2.html">The truth behind the Outlook 2007 change and what you can do about it</a>, Campaign Monitor, January 22, 2007</cite></p>
</blockquote>
<h3 id="toc-what-about-actually-getting-the-email-delivered">What about actually getting the email delivered?</h3>
<p><a href="http://www.thinkvitamin.com/features/design/ensuring-your-html-emails-look-great-and-get-delivered">Ensuring your HTML emails look great and get delivered</a>, by David Greiner is a great resource, discussing issues such as spam lists, what you can request from some ISPs, etc.</p>
<h3 id="toc-more-information">More information</h3>
<ul>
<li><a href="http://www.email-standards.org">The Email Standards Project</a></li>
<li><a href="http://www.webstandards.org/2007/11/28/the-email-standards-project/">The Web Standards Project&#8217;s post on the Email Standards Project</a> (from which I learned about the Email Standards Project). This post is interesting for the various comments the post attracted.</li>
<li><a href="http://www.zeldman.com/2007/06/08/e-mail-is-not-a-platform-for-design/">E-mail is not a platform for design</a>, Jeffery Zeldman (the guy who started the Web Standards move), June 2007.</li>
<li>About Microsoft&#8217;s Outlook 2007 decision and some further details on what this means:
<ul>
<li><a href="http://www.campaignmonitor.com/blog/archives/2007/01/microsoft_takes_email_design_b.html">Microsoft takes email design back 5 years</a>, Campaign Monitor, January 12, 2007</li>
<li><a href="http://www.campaignmonitor.com/blog/archives/2007/01/the_truth_behind_the_outlook_2.html">The truth behind the Outlook 2007 change and what you can do about it</a>, Campaign Monitor, January 22, 2007</li>
<li><a href="http://www.sitepoint.com/blogs/2007/01/10/microsoft-breaks-html-email-rendering-in-outlook/">Microsoft Breaks HTML Email Rendering in Outlook 2007</a>, Sitepoint.com, January 10, 2007</li>
<li><a href="http://www.microsoft-watch.com/content/messaging_collaboration/the_saga_of_html_message_rendering_in_outlook_2007.html">The Saga of HTML Message Rendering in Outlook</a>, Microsoft Watch, January 31, 2007</li>
<li><a href="http://msdn2.microsoft.com/en-us/library/aa338201.aspx">Word 2007 HTML and CSS Rendering Capabilities in Outlook 2007</a>, Microsoft Developer Network, August 2006</li>
<li><a href="http://www.microsoft.com/downloads/details.aspx?familyid=0b764c08-0f86-431e-8bd5-ef0e9ce26a3a&amp;displaylang=en">2007 Office System Tool: Outlook HTML and CSS Validator</a>, Microsoft</li>
</ul>
</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/39/the-email-standards-project/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Day 2: @media ajax November 2007</title>
		<link>http://www.onenaught.com/posts/37/day-2-media-ajax-november-2007</link>
		<comments>http://www.onenaught.com/posts/37/day-2-media-ajax-november-2007#comments</comments>
		<pubDate>Thu, 22 Nov 2007 22:28:51 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[General Web Development]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[@media ajax]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[JavaScript2]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/37/day-2-media-ajax-november-2007</guid>
		<description><![CDATA[<p><img src="/wp-content/uploads/at-media-ajax.gif" alt="@media ajax 2007" class="post-img" align="left" /> My impression of day 2 at @media ajax, the ajax/javascript conference with some of the leading figures in this area.</p>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.onenaught.com/wp-content/uploads/at-media-ajax.gif" alt="@media ajax 2007" class="post-img" /> A previous post summarized <a href="http://www.onenaught.com/posts/36/day1-media-ajax-november-2007">day 1 of @media ajax</a> which looked at general issues of JavaScript on the web.</p>
<p>This post is a summary of day 2, a more technical look at JavaScript and its future.</p>
<p><span id="more-37"></span></p>
<h3 id="toc-javascript-2-and-the-open-web">JavaScript 2 and The Open Web</h3>
<p>By <a href="http://weblogs.mozillazine.org/roadmap/">Brendan Eich</a>, the inventor of JavaScript.</p>
<p>Good talk on some details about JavaScript 2 which he (and others) have been blogging about recently. He also briefly talked about the &#8220;open web&#8221; (WHATWG, W3C, etc) versus a &#8220;closed one&#8221; (Adobe AIR, Microsoft&#8217;s Silverlight, etc), which he has also <a href="http://weblogs.mozillazine.org/roadmap/archives/2007/03/the_open_web_and_its_adversari.html">blogged about previously</a>.</p>
<p>He also talked about some of the language features being proposed for JavaScript 2 which would make it look much more object-oriented (namespaces, classes, packages, generics etc). He said the main drivers for JavaScript 2 were better security, better APIs and better programming language support.</p>
<p>Why are these needed? He felt users deserved more support in the language. He lamented that the combination of Microsoft&#8217;s domination combined with Netscape&#8217;s self-destruction had made the web stagnate. JavaScript hasn&#8217;t really changed that much in those years. As web apps were getting more common place, some of these new features could be more important.</p>
<p>A point he and others have made is that while there are better languages out there, most have not really been used as widely as JavaScript, especially from the kind of wide user base that JavaScript has, so the perceived weaknesses of JavaScript can also be its strengths (something Douglas Crockford looked into further &#8212; more below!).</p>
<p>Update 1: he has posted <a href="http://weblogs.mozillazine.org/roadmap/archives/2007/11/my_media_ajax_keynote.html">slides together with notes and commentary</a>. A useful read.</p>
<p>Update 2: <a href="http://ajaxian.com/archives/brendan-eich-javascript-2-evolution-and-the-myth-busting-tracing-jit">Ajaxian has a decent look at a specific aspect of his talk</a>: JS code bloat and JS2&#8242;s improvement, and the performance benefits of JITting.</p>
<p>(Here&#8217;s a <a href="http://ejohn.org/blog/easy-pdf-sharing/">decent set of slides on the new features being considered in JavaScript 2</a>, actually by John Resig, the next speaker!)</p>
<h3 id="toc-building-interactive-prototypes-with-jquery">Building Interactive Prototypes with jQuery</h3>
<p>By <a href="http://ejohn.org/">John Resig</a>, inventor of <a href="http://jquery.com">jQuery</a>.</p>
<p>I think this was one of my most favourite sessions, but it should not have been! It should not have been because I have been using the excellent jQuery library for about two or three months now, So I should have found most of this talk familiar and therefore not of that much interest.</p>
<p>Instead, I was really impressed with the quality of the session. John was showing the features of jQuery with code examples, and throughout his talk, people from the audience would ask if it was possible to do various things, and he was always able to answer in a polite, positive way, constantly changing his code on the fly in front of everyone. Many of the seemingly complex things that were being asked were implemented not by one line of code, but one word or two!</p>
<p>The talk wasn&#8217;t really about building prototypes, though, more about just using it. (And it isn&#8217;t just for prototyping; it is being used in a lot of big places.)</p>
<p>If you haven&#8217;t seen it, check out the jQuery site and try it out. It&#8217;s really growing on me. While I initially found it weird, it is amazingly powerful, simple, efficient and productive. Its quite different to most of the other popular JavaScript frameworks, especially in how it queries the DOM so efficiently and with hardly any code! I have removed anywhere from 40-60% of some of my JavaScript code when I have used it and I hope to use it more.</p>
<p>Update: <a href="http://ejohn.org/blog/building-interactive-prototypes-with-jquery/">Slides for the JQuery presentation</a> are now available.</p>
<h3 id="toc-metaprogramming-javascript">Metaprogramming JavaScript</h3>
<p>By <a href="http://www.danwebb.net/">Dan Webb</a>, a JavaScript expert and part of the core <a href="http://www.prototypejs.org/">Prototype</a> JavaScript framework team</p>
<p>I had bumped into him the day before during a session break, and he was saying he was nervous about his talk with so many experts as speakers!</p>
<p>But he did a great job explaining a decent topic: meta programming; programming JavaScript to augment itself at run time (e.g. to overcome deficiencies such as IE&#8217;s limited event handling in an efficient manner). Rather than describe the things he talked about, have a look at <a href="http://www.slideshare.net/danwrong/metaprogramming-javascript">his metaprogramming slides</a>.</p>
<h3 id="toc-dojo-1-0-great-experiences-for-everyone">Dojo 1.0: Great Experiences For Everyone</h3>
<p>By <a href="http://alex.dojotoolkit.org/">Alex Russell</a>, project lead for the <a href="http://dojotoolkit.org/">Dojo Toolkit</a></p>
<p>Instead of talking about Dojo, Alex Russell decided to talk about the state of the web in general &#8212; which was a great talk!</p>
<p>Interesting points included that the emergence of Adobe&#8217;s Flex, Microsoft Silverlight, etc signaled a sign of problems for the web; that it may not be evolving much, that it may be hitting the walls of complexity. </p>
<p>He felt that even JSF/JSP (JavaServer Faces and JavaServer Pages) could be a sign of this pain (these technologies use a component-based approach to develop web apps, similar to ASP.NET, so I&#8217;d add that to his concern). His point was that Java developers appear to be afraid of getting their hands dirty with HTML, JavaScript etc, preferring these components to do it instead. Instead, developers <em>do</em> need to care about markup. These same criticisms apply, in my opinion, to ASP.NET. (During the Q &#038; A session just after his talk, a lot of people voiced concerns about Microsoft&#8217;s dominance slowing down change.)</p>
<h3 id="toc-javascript-the-good-parts">JavaScript: The Good Parts</h3>
<p>By <a href="http://www.crockford.com/">Douglas Crockford</a>, Architect at Yahoo! Inc, a well known JavaScript guru who also came up with JSON!</p>
<p>Perhaps one of the two foremost people on JavaScript, this talk was interesting, because Crockford, despite his knowledge of JavaScript is known for being against the proposed ECMAScript 4 specification (which would be implemented as JavaScript 2). He feels that while the additions proposed are interesting and good, it makes the language quite different, and so should be called something other than JavaScript (else he seems to be for it, from what I can tell!).</p>
<p>He has <a href="http://www.jslint.com/lint.html">written previously</a> that, &#8220;JavaScript is a sloppy language, but inside it there is an elegant, better language&#8221;, and that was a point he was trying to make again, quite effectively, I thought.</p>
<p>This talk looked at a number of things problematic with the language and also what worked so well (e.g. lambda functions, closures, the functional programming aspects of JavaScript, the dynamic and flexible nature of the language, etc.)</p>
<p>One annoying (even dangerous) mistake with the JavaScript language he pointed out was semi-colon insertion, whereby if you omitted the &#8220;;&#8221; at the end of a statement, the parser would add it in for you. While this may have been kinda understandable at the time JavaScript came out (to help non-programmers, etc), it had an impact even on code convention:</p>
<p>While in other languages, coding standard/style is typically a matter of preference, here was an example where opening the curly brace on the same line is a MUST for JavaScript:</p>
<pre><code>return
{
    name : value;
}</code></pre>
<p>Is NOT the same as </p>
<pre><code>return {
    name : value;
}</code></pre>
<p>In the first example, because of semi colon insertion, the interpreter will actually do this:</p>
<pre><code>return <strong>;</strong>
{
    name : value;
}</code></pre>
<p>(It will add a semi colon after return!)</p>
<p>Bizarre, but rests the debate on where to open your curly brace for JavaScript!!</p>
<p>He mentioned the tool he wrote a few years ago, <a href="http://www.jslint.com/">JSLint</a>, that checks your JavaScript much like Lint does for C etc (it will catch the above issue, amongst many other things!). Will be worth looking into further and possibly integrating it into our build processes (which they do with Yahoo&#8217;s YUI, for example).</p>
<p>He also made the controversial statement in the panel discussion that followed, that CSS was shit, which didn&#8217;t go down too well! (Though he also said he is not a designer, or something like that!)</p>
<p>The other concern he raised was that IE 6 in particular was holding back the advancement of JavaScript; that changes were hard to introduce because of the prevalence of this poor quality browser.</p>
<h3 id="toc-discussion-panel">Discussion Panel</h3>
<p>Moderated by Jeremy Keith (the guy who coined the term &#8212; and authored a popular book by the same name &#8212; &#8220;DOM Scripting&#8221;)</p>
<p>Brenden Eich, Stuart Langridge, Alex Russell, and Douglas Crockford were on the panel answering questions raised by the audience. Most were around JavaScript&#8217;s future, what frameworks people were using, and concerns about Microsoft&#8217;s domination of the web (its negative impact on the web developer community and whether it mattered any more or not), etc. Some good topics and debates!</p>
<h3 id="toc-conclusion">Conclusion</h3>
<p>A really good day; lots of ideas and details. Some of the powerful aspects of JavaScript were shown in simple terms.</p>
<p>The last @media conference got me excited enough to finally start this blog. This one gives me a sense of urgency to replace some of my JavaScript code with jQuery <img src='http://www.onenaught.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/37/day-2-media-ajax-november-2007/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Day 1: @media ajax November 2007</title>
		<link>http://www.onenaught.com/posts/36/day1-media-ajax-november-2007</link>
		<comments>http://www.onenaught.com/posts/36/day1-media-ajax-november-2007#comments</comments>
		<pubDate>Thu, 22 Nov 2007 00:04:25 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[General Web Development]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[@media ajax]]></category>
		<category><![CDATA[ajax]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/36/day1-media-ajax-november-2007</guid>
		<description><![CDATA[<p><img src="/wp-content/uploads/at-media-ajax.gif" alt="@media ajax 2007" class="post-img" align="left" /> My impression of day 1 at @media ajax, the ajax/javascript conference with some of the leading figures in this area.</p>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.onenaught.com/wp-content/uploads/at-media-ajax.gif" alt="@media ajax 2007" class="post-img" /> So I went to the <a href="http://www.vivabit.com/atmediaAjax/">@media ajax conference</a> earlier this week, and thought I&#8217;d just write up a quick summary of the event/sessions.</p>
<p>This event was one of the premier JavaScript/ajax events including speakers such as Brendan Eich (Mozilla, and inventor of JavaScript), Douglas Crockford (Yahoo, and creator of JSON), Derek Featherstone (Further Ahead), John Resig (jQuery), Jeremy Keith (author of Bulletproof Ajax), and Dion Almaer &#038; Ben Galbraith (Ajaxian).</p>
<p>Every session was of interest. By no means are these a complete set of notes of everything said, just an overview and my impressions of it:</p>
<p><span id="more-36"></span></p>
<h3 id="toc-overall">Overall</h3>
<p>Great. Good to hear from some of the key people in this field. Though the conference felt more about JavaScript than just AJAX (but that was a good thing IMO).</p>
<p>A number of sessions talked of how JavaScript was hated and considered too basic for serious programmers until just recently and yet, without having really changed that much over the 10 years, is now well-respected, incredibly powerful, and very misunderstood!</p>
<h3 id="toc-the-state-of-ajax">The State of AJAX</h3>
<p>By the guys who run <a href="http://ajaxian.com/">Ajaxian</a>.</p>
<p>Interesting talk noting various improvements in just a few short years, and some of the innovative things that are coming, from Mozilla (<a href="http://www.mozilla.org/projects/tamarin/">Tamarin</a>, <a href="http://ajaxian.com/archives/mozilla-announces-screaming-iron-action-monkeys-tamarin-in-ie">Screaming Monkey</a> etc), Google (<a href="http://gears.google.com/">Gears</a>, <a href="http://code.google.com/webtoolkit/">GWT</a>), various frameworks (<a href="http://jquery.com/">JQuery</a>, <a href="http://developer.yahoo.com/yui/">YUI</a>, <a href="http://dojotoolkit.org/">dojo</a>, etc), and of trends such as AJAX on desktop apps (<a href="http://labs.adobe.com/technologies/air/">Adobe AIR</a>, <a href="http://blog.magnetk.com/2007/03/22/joyent-slingshot/">Slingshot</a>, <a href="http://silverlight.net/">Silverlight</a>, <a href="http://labs.mozilla.com/2007/10/prism/">Prism</a> etc).</p>
<p>They <a href="http://www.i-marco.nl/weblog/archive/2006/06/24/time_breakdown_of_modern_web_d">presented a pie chart</a> showing almost 50% of web developer&#8217;s time was typically wasted on sorting out problems with IE/Microsoft! Made people laugh, because how true it unfortunately is. (It was interesting &#8212; though not unexpected &#8212; that in almost every session there was some note, minor or major, of how much Microsoft/IE had stagnated/held back the web.)</p>
<p>Google Gears&#8217; use of worker pools and other features to improve both security and performance was mentioned, which was quite interesting. (Gears has many things being considered for HTML 5 &#8212; including the much-talked about off-line storage &#8212; but because Gears requires a separate install on the user&#8217;s browser, I hadn&#8217;t really given it much attention. I am certainly interested to learn more now.)</p>
<p>The other point they made was that AJAX-based apps were now raising the bar on web apps; from form to function to the &#8220;wow&#8221; factor. They mentioned an interesting usability study looking at two apps with the same functionality, except one just looked better. They asked people around the world (not just US and/or Europe) which one they thought they were more productive with. They all said the better looking one. Whether it was true or not wasn&#8217;t the point; the wow factor was.</p>
<h3 id="toc-but-im-a-bloody-designer">But I&#8217;m a bloody designer!</h3>
<p>Interface designer <a href="http://donotremove.co.uk/">Mike Stenhouse</a> provided the perspective of a designer who, being comfortable on the design/HTML/CSS end of things in the past, perhaps with simple JavaScript stuff (image rollovers etc) would leave the construction and server-side programming to others. However, with web <em>applications</em> much has changed. For example, more programmers are coming to JavaScript and even &#8220;taking JavaScript away from the designer.&#8221;</p>
<p>He talked about how he found himself being more involved in day to day discussions and decisions and that agile development was a good fit for this changing, even for a designer. He found himself being involved both as a customer representative as well as part of the team, even involved in pairing with developers (not to write code necessarily but to appreciate the coding issues and to allow developers to appreciate the design issues).</p>
<p>It was interesting (and good) to hear a designer talking about the merits of <a href="http://en.wikipedia.org/wiki/Test-driven_development">Test Driven Development</a> and even <a href="http://behaviour-driven.org/">Behaviour Driven Development</a>!</p>
<h3 id="toc-real-world-accessibility-for-ajax-enhanced-web-apps">Real World Accessibility for Ajax-enhanced Web Apps</h3>
<p>By accessibility expert, <a href="http://boxofchocolates.ca/">Derek Featherstone</a>.</p>
<p>While he covered techniques that should be reasonably well known now for people who have been following web standards etc for the last few years, he presented it really well so hopefully those not as interested or aware of the issues should be better armed now.</p>
<p>Fundamentally he reiterated that markup still matters; that the structure of the HTML was still fundamental and should come first.</p>
<h3 id="toc-how-to-destroy-the-web">How To Destroy The Web</h3>
<p>By <a href="http://kryogenix.org/">Stuart Langridge</a>, author and one of the founders of the Web Standards Project&#8217;s <a href="http://www.webstandards.org/action/dstf/">DOM Scripting Task Force</a>.</p>
<p>This was a funny, tongue-in-cheek, look at how not to do web development or further the web.</p>
<h3 id="toc-planning-javascript-and-ajax-for-larger-teams">Planning JavaScript and Ajax for Larger Teams</h3>
<p>By <a href="http://wait-till-i.com/">Christian Heilmann</a>, JavaScript expert, now Yahoo! UK lead web developer, standards evangelist and trainer.</p>
<p>Good discussion on the importance of team development. Also made a point that front end stuff like CSS and JavaScript should be treated as application code; with a build process.</p>
<p>Mentioned tools like <a href="http://www.jslint.com/lint.html">JSLint</a> for quality, <a href="http://developer.yahoo.net/blog/archives/2007/07/high_performanc_8.html">minification</a> and consolidation for performance, all things I have been interested in looking into further.</p>
<p>Another decent idea around team motivation and knowledge sharing was the &#8220;lightning talks&#8221; &#8212; 5 minutes to present a problem, 5 minutes demo the solution, 5 minutes to discuss (and then share with the world, through blogs, wikis etc). We have tried hour long sessions with our teams which are really good, but when our development is fully underway, these are sometimes sacrificed, unfortunately. These shorter &#8220;lightning talks&#8221; are an interesting idea, which I hope we try out.</p>
<p>He also talked about architecting JavaScript (thinking of modules instead of pages, providing configuration capabilities, custom events, etc). All good stuff which I have been trying to do more of lately (not always perfectly though), so nice to see that being mentioned.</p>
<h3 id="toc-afternoon-coffee-break">Afternoon Coffee Break</h3>
<p>No, not a session, but a break! The reason this was useful for me was that as a work colleague and I were talking near the cookies and coffee area, Stuart Langridge came over, so I quickly told him I liked his session and we started talking about various things.</p>
<p>He had very briefly mentioned something called Comet which I asked if he could explain further. All he said was, &#8220;why not ask the guy who invented the term&#8221; pointing to another guy just standing right next to us, Alex Russell (one of the speakers for the second day)!</p>
<p>It was a great discussion on the idea behind <a href="http://alex.dojotoolkit.org/?p=545">Comet</a> (rather than the client polling the server continuously for something, being able to push data and events from the server to the client, all while using the existing HTTP infrastructure, which is not built for this type of communication. In short it involves having a script element request a resource from the server, but the server never returning, just blocking until different messages/events/data needs pushing. Simple in idea but involves some complexities to overcome. I will be trying to look into this further.)</p>
<h3 id="toc-ajax-at-work-a-case-study">Ajax at Work: A Case Study</h3>
<p>By Peter-Paul Koch (ppk), known for his useful <a href="http://www.quirksmode.org/">quirksmode</a> web site of tips and tricks and understanding browser incompatibilities.</p>
<p>Ironically for an ajax conference, the only session that actually looked at the technical aspects of ajax. He compared using XML, JSON, CSV, and HTML as the data being returned from an AJAX request, looking at pros and cons of each. (As expected, ultimately XML or JSON are better than CSV or HTML in most cases, but it all depends on the situation.)</p>
<h3 id="toc-conclusion">Conclusion</h3>
<p>So, all in all, a decent day, getting to hear from some well known people. Can&#8217;t say I technically learned much, but I don&#8217;t think that was the goal of the day as such; more to share ideas and connect.</p>
<p><a href="http://www.onenaught.com/posts/37/day-2-media-ajax-november-2007">Day 2 was for the more technical stuff, and had even more well known people talking</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/36/day1-media-ajax-november-2007/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Microsoft to make Internet Explorer 7 more widely available</title>
		<link>http://www.onenaught.com/posts/34/microsoft-to-make-internet-explorer-7-more-widely-available</link>
		<comments>http://www.onenaught.com/posts/34/microsoft-to-make-internet-explorer-7-more-widely-available#comments</comments>
		<pubDate>Thu, 04 Oct 2007 22:47:22 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[Browsers]]></category>
		<category><![CDATA[General Web Development]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/34/microsoft-to-make-internet-explorer-7-more-widely-available</guid>
		<description><![CDATA[Microsoft is making IE 7 more widely available. IE 7 still has to catch up with the other modern browsers but this seems to be a good thing from a web developer's perspective as IE 6 is so much more buggy. Or is it...?]]></description>
			<content:encoded><![CDATA[<p>The Microsoft Internet Explorer team posted on their blog today a note saying <a href="http://blogs.msdn.com/ie/archive/2007/10/04/internet-explorer-7-update.aspx">they will make IE 7 more widely available</a>: to people who don&#8217;t have genuine windows and all XP users.</p>
<h3 id="toc-why">Why?</h3>
<p>Why is Microsoft doing this? They say that it is because &#8220;Microsoft takes its commitment to help protect the entire Windows ecosystem seriously.&#8221;</p>
<p>My opinion on this is that they are finding that those with cracked/non-genuine Windows are stuck on IE 6 and even though that is not Microsoft&#8217;s fault, the security holes in that browser gives a bad image for Microsoft.</p>
<p>I also wonder if they are doing this to challenge the rising popularity of other browsers such as Firefox and Safari.</p>
<p>Anyway, those are just my initial quick thoughts.</p>
<h3 id="toc-its-a-good-move">Its a good move</h3>
<p>From a web development perspective alone, I think this is a good thing:</p>
<p>For web developers IE6 has long replaced Netscape 4 as the annoying browser to cater for given all its CSS rendering bugs and DOM deficiencies.</p>
<p>IE 7 is a <strong>vast</strong> improvement over IE 6.</p>
<p>The less people using IE 6 the better for them and for us web developers!</p>
<p>That being said, IE 7 is still not up to speed with CSS and DOM support as the other modern browsers but in my opinion requires far less alternative CSS rules for example.</p>
<h3 id="toc-or-is-it">Or is it?&#8230;</h3>
<p>Or, is it a good move?</p>
<p>If Microsoft regains its dominant market share of a few years ago (approx 95%) will it just sit on its browser and not do much with it again, thus slowing down overall progress as before?</p>
<p>(I&#8217;ll expand on this last point in another post!)</p>
<p>To be fair, there are enough signs that Microsoft&#8217;s IE team is far more committed to standards support etc than before, with people like Chris Wilson and Molly Holzschlag and various others there who &#8220;get it.&#8221;</p>
<p>Its near impossible to predict the future, but another way to put the above concern is as follows:</p>
<p>What would I prefer:</p>
<ol>
<li>The current situation with IE 6 so prevelant</li>
<li>Microsoft regaining its dominant near monopoly browser market share with IE 7</li>
<li>IE 7 replacing many instances of IE 6, but being a browser amongst a diverse ecosystem of web browsers all competing by using standards as a basis for innovation, not proprietary stuff as the basis (as was the case in the Netscape 4 vs IE 4+ browser wars)</li>
</ol>
<p>I think I would prefer the 3rd option&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/34/microsoft-to-make-internet-explorer-7-more-widely-available/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>WYSIWYG HTML Editors</title>
		<link>http://www.onenaught.com/posts/28/wysiwyg-html-editors</link>
		<comments>http://www.onenaught.com/posts/28/wysiwyg-html-editors#comments</comments>
		<pubDate>Tue, 25 Sep 2007 22:18:21 +0000</pubDate>
		<dc:creator>Anup Shah</dc:creator>
				<category><![CDATA[General Web Development]]></category>

		<guid isPermaLink="false">http://www.onenaught.com/posts/28/wysiwyg-html-editors</guid>
		<description><![CDATA[WYSIWYG editors for HTML are fraught with problems, as discussed in a previous post. This post is a quick look at why WYSIWYG editors would be important for content producers and offers some links to tools and research that people are doing.]]></description>
			<content:encoded><![CDATA[<h3 id="toc-wysiwyg-bad-for-developers-important-for-content-authors">WYSIWYG &#8212; bad for developers; important for content authors</h3>
<p>A while back I posted on <a href="http://www.onenaught.com/posts/4/should-web-developers-avoid-wysiwyg-editors">whether developers should avoid <abbr title="What you see is what you get">WYSIWYG</abbr> editors or not</a>, and what the general problems are.</p>
<p>However, while WYSIWYG HTML editors can be a hindrance to good quality markup for web developers, WYSIWYG HTML editors can be extremely important for effective Content Management Systems (CMSs) where end users (typically with no HTML knowledge) are often expected to contribute content.</p>
<h3 id="toc-poor-quality-html-from-wysiwyg-editors">Poor quality HTML from WYSIWYG editors</h3>
<p>As alluded to in that previous post, various WYSIWYG editors create very poor quality HTML, which can affect things like accessibility, maintainability, and manageability.</p>
<p>Some of the problems include</p>
<ul>
<li>The continued use of bold, italics and underline buttons because word processors have them! (The intentions of those buttons are to produce presentational markup, rather than structural markup.)</li>
<li>Not providing ability to set headings (or encouraging users to just increase the font size and make the text bold)</li>
<li>Indenting text using HTML elements that were meant for other uses</li>
<li>Being difficult to provide alternative text for images</li>
</ul>
<p>And so on.</p>
<p>Why is all this problematic? In short, tools that process the document cannot offer any additional value to the user.</p>
<p>For example, if a WYSIWYG HTML editor doesn&#8217;t have simple headings support, users will typically increase some text size a few times. While it looks like a heading, it is technically not a heading; this can mean a screen reader cannot offer a useful list of headings to a blind user of the information, and that a site-wide visual design/brand may become harder to maintain if there are various elements used inappropriately to achieve the same effect.</p>
<p>Some of the challenges are due to the WYSIWYG editor providers, while other challenges include the education of the content creators to know about these issues.</p>
<h3 id="toc-but-various-projects-are-addressing-these-concerns">But various projects are addressing these concerns</h3>
<p>Fortunately, there are people trying to address this, so here are a few links (not exhaustive):</p>
<p><a href="http://alastairc.ac">Alastair Campbell</a>, a web usability and accessibility expert, provides some useful resources:</p>
<ul>
<li><a href="http://alastairc.ac/testing/editor_checklist/">WYSIWYG Editor Checklist</a> is intended as a tool to assess and help improve editors. It follows the idea of the <a href="http://www.w3.org/TR/WAI-WEBCONTENT/full-checklist.html">Web Content Accessibility Guidelines 1.0 Checklist</a> from the W3C, which is quite useful.</li>
<li><a href="http://alastairc.ac/category/wysiwyg-editors/">A collection of articles about WYSIWYG editors</a> looks at various issues in depth.</li>
</ul>
<p><a href="http://xstandard.com/">XStandard</a> is one of the better WYSIWYG editors that gets most of the issues and tries to provide a better interface for producing good quality markup, efficiently.</p>
<p><a href="http://www.wymeditor.org/">WYMEditor</a> takes a good approach by using the term WYSIWYM (What you see is what you <em>mean</em>). The idea behind WYMEditor is to concentrate on a web document&#8217;s structure and meaning, while trying to give the user as useful an interface as possible, close to a WYSIWYG editor. This project is in early phases, but looks quite promising.</p>
<p><a href="http://tinymce.moxiecode.com/">TinyMCE</a> produces decent markup and offers semantic as well as visual styling. It is used by WordPress as the WYSIWYG HTML editor, too.</p>
<p><a href="http://www.fckeditor.net/">FCKEditor</a> seems to produce decent markup too, offering semantic as well as visual styling.</p>
<p>Are there any others projects you know of that follow modern web standards principles for such editors?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.onenaught.com/posts/28/wysiwyg-html-editors/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
