<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">

    <title type="text">Blog</title>
    <subtitle type="text">Blog:</subtitle>
    <link rel="alternate" type="text/html" href="/archive/" />
    <link rel="self" type="application/atom+xml" href="http://www.easy-reader.net/site/atom/" />
    <updated>2010-02-25T16:56:53Z</updated>
    <rights>Copyright (c) 2010, Aaron Gustafson</rights>
    <generator uri="http://expressionengine.com/" version="1.6.8">ExpressionEngine</generator>
    <id>tag:,2010:01:18</id>


    <entry>
      <title>A new &#8220;onload&#8221; scheme</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2010/01/18/a-new-onload-scheme" />
      <id>tag:,2010:/archive/1.370</id>
      <published>2010-01-18T23:30:52Z</published>
      <updated>2010-02-25T14:28:53Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="programming"
        scheme="http://www.easy-reader.net/site/C157/"
        label="programming" />
      <content type="html"><![CDATA[
        <p>A few projects back, I decided to rethink our JavaScript organization strategy and came up with a new technique that, I think, helps us better manage behaviors from page to page.</p>

<p>For years, when I needed page-specific interactions, I would either embed the JS (unobtrusively, of course) at the bottom of the page or externalize it to a separate page-specific file. In some sites, that became a difficult setup to manage because we were juggling so many files and we were also forcing our users to download each of those files individually.</p>

<p>Looking for a better way to manage all of the code, I built <a href="http://github.com/easy-designs/FunctionHandler.js">FunctionHandler</a>. This script takes lets you declare blocks of JavaScript and then target them at pages based on the <code class="html">id</code> attribute on the <code class="html">body</code> element. When the targeted <code class="html">id</code> is encountered, the code block is executed on DOM ready. Here's a quick example:</p>

&#123;exp:gist id="313553" file="gistfile1.js"&#125;

<p>As you can see, using it is pretty simple: you make a call to FunctionHandler's <code class="javascript">register</code> method and pass it two arguments. The first is an array of the <code class="html">id</code> values you want this code block to execute on and the second is an anonymous function that wraps your code block.</p>

<p>What we've found really nice about this setup is that it encourages you to create discrete JavaScript components while, at the same time, easily allowing you to adjust the pages that those components run on by simply adding to or subtracting from the <code class="html">id</code> stack. You can even blanket every page with a given script by supplying a string value of "*" as the initial argument:</p>

&#123;exp:gist id="313553" file="gistfile2.js"&#125;

<p>Anyway, I just wanted to take a brief moment to share this script because we've found it pretty handy. Perhaps you will too.</p>

<p>PS - FunctionHandler is available in 3 flavors: native JS, jQuery, and Prototype.</p>
      ]]></content>
    </entry>

    <entry>
      <title>Getting TinyMCE to respect empty alt attributes</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2009/09/21/getting-tinymce-to-respect-empty-alt-attributes" />
      <id>tag:,2009:/archive/1.150</id>
      <published>2009-09-21T13:37:04Z</published>
      <updated>2010-02-25T14:34:05Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="programming"
        scheme="http://www.easy-reader.net/site/C157/"
        label="programming" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p>This one took a little futzing around and digging through the <a href="http://tinymce.moxiecode.com/punbb/">TinyMCE forum</a>&nbsp;to figure out, but it's been nagging at me for a while. By default (or at least in the default configuration provided under the <a href="http://leevigraham.com/cms-customisation/expressionengine/lg-tinymce/">LG TinyMCE extension for ExpressionEngine</a>), <a href="http://tinymce.moxiecode.com/">TinyMCE</a> will remove the <code class="html">alt</code> attribute if it is empty. Obviously, for accessibility and validation reasons, this is highly undesirable and needs correcting. Thankfully, the fix is pretty simple: add the following to your <a href="http://wiki.moxiecode.com/index.php/TinyMCE:Configuration">TinyMCE configuration options</a>:</p>

&#123;exp:gist id="313562"&#125;

<p>I choose to add these options right after declaring my cleanup/output options but before the remainder of the configuration. If you choose to tack these options on at the end, just remember to remove the trailing comma.</p>
      ]]></content>
    </entry>

    <entry>
      <title>RIP XHTML 2</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2009/07/09/rip-xhtml2" />
      <id>tag:,2009:/archive/1.142</id>
      <published>2009-07-09T13:46:51Z</published>
      <updated>2010-02-25T14:33:52Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="coding"
        scheme="http://www.easy-reader.net/site/C158/"
        label="coding" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p>I wasn't planning to weigh in much on this subject, but I've been asked by several people for my thoughts, so here we go...</p>
<p>This <a href="http://www.w3.org/News/2009#item119">decision by the W3C to not renew the charter for the XHTML 2 Working Group</a> has, rather unfortunately, brought out the worst in the Web standards community. Sure, as a community, we're prone to holy wars over seemingly inconsequential things&mdash;<code>abbr</code> vs. <code>acronym</code>, use vs. abuse of definition lists, etc.&mdash;but this move has sparked a particularly ugly fight between proponents of XHTML and its detractors (primarily those folks who think it's pointless to use XHTML if you aren't serving it with an XML MIME type).<br /><br />Personally, I have mixed feelings about the decision. I think there were a lot of good ideas in XHTML 2 (everything can be a link, for one), but it also had a number of shortcomings. I feel much the same about HTML 5; some of the new elements make a lot of sense, but others seem to be solving a problem that really wasn't there to begin with.<br /><br />In the end, I think this is probably a good move for the W3C as it will, hopefully, allow them to reallocate resources to projects that need them.<br /><br />But does it mean I think XHTML is a failure? No.<br /><br />I think XHTML was a phenomenal success as it made us look at HTML in a new light. It forced us to think about how we marked up documents and applied much-needed pressure on developers to make smarter decisions. Without it, I dare say the Web standards movement would never have gotten as much traction as it did and we would still be in the midst of the browser war started more than a dozen years ago.</p>
      ]]></content>
    </entry>

    <entry>
      <title>We&#8217;re back (sort of)</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2009/04/22/were-back-sort-of" />
      <id>tag:,2009:/archive/1.58</id>
      <published>2009-04-22T12:05:14Z</published>
      <updated>2010-02-25T14:30:16Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="business"
        scheme="http://www.easy-reader.net/site/C154/"
        label="business" />
      <content type="html"><![CDATA[
        <p>After making a ridiculously stupid mistake by axing the server that hosted this blog (without checking that I had actually moved it to the new server and without making sure I had a backup of the DB), Easy! Reader is back. Sort of. Thankfully, I had a backup from late '06 and I haven't been an incredibly prolific blogger in the time since that backup. And, thanks to the Internet Archive, it looks like we should be able to recover all but one article (my last post, from about a year ago) from the ether. It may take a little time, but we should have it all up in the next few weeks.</p>
<p>So what's going on? Well, a lot.</p>
<p>For one, we've relocated from New Haven, CT to Chattanooga, TN after being urged to visit by <a href="http://shauninman.com">Mr. Shaun Inman</a> and his lovely bride <a href="http://morellc.com">Leslie</a> and falling in love with this awesome city. We made the move in August of last year and, after spending a few months in an apartment, have bought a house and will be moving in this weekend. Chattanooga is an amazing place. There's always something going on, it has a wonderful art scene and tech community, and is nestled in the mountains, right along the Tennessee River. It has many of the perks of Portland, OR and San Francisco, CA (other cities we considered moving to), but at 1/4-1/3 the cost. I couldn't ask for a better place to live.</p>
<p>Since relocating, Easy! Designs has also been growing. We've taken on two interns -- Matt Turnure and Sean McCarthy -- and have been joined full-time by both Dave Stewart (who I had previously worked with in CT) and Matt Harris (an excellent developer from the UK), so expect to be hearing from them on this site soon as well. In addition to our client work, we've been busily coding away on a few products of our own that should hopefully see the light of day in the coming year. We're also working on a relaunch of our own website and this blog.</p>
<p>Finally, there's <a href="http://eCSStender.org">eCSStender</a>. I've been working on this project for ages and it's currently in a closed beta. Things are progressing smoothly on its development though and I expect it will be ready for its initial public release in the coming weeks.</p>
<p>Anyway, that's the nickel tour of the changes. I apologize profusely for rendering this blog pretty useless with my error, but hopefully we'll have it all back up and running shortly.</p>
<p>PS - If you happen to have an archive of my blog post on IE8 Standards Mode, please forward a copy of it to me. I can't seem to find it even though it appears to be somewhere in the Google Cache.</p>
      ]]></content>
    </entry>

    <entry>
      <title>Automatically opting&#45;in to IE8&#8217;s Standards Mode</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2008/02/25/automatically-opting-in-to-ie-standards-mode" />
      <id>tag:,2008:/archive/1.371</id>
      <published>2008-02-26T01:18:58Z</published>
      <updated>2010-02-25T14:33:59Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="coding"
        scheme="http://www.easy-reader.net/site/C158/"
        label="coding" />
      <category term="design"
        scheme="http://www.easy-reader.net/site/C156/"
        label="design" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p><img style="float: left; margin-right: 10px;" src="/img/posts/wasp-logo.png" alt="Web standards Project" />As some of you have <a href="http://www.webstandards.org/2008/02/24/wasp-round-table-ie8s-default-version-targeting-behavior/">read</a> (or <a href="http://www.webstandards.org.nyud.net/files/wasp_ie8_round_table_discussion_final.mp3">heard</a>), WaSP organized a Round Table discussion on IE8&#8217;s standards mode and its default behavior of opting-out any sites that don&#8217;t engage in <a href="http://www.alistapart.com/articles/beyonddoctype">version targeting</a>. We discussed a few different aspects of the issues this presents for standards-aware developers (and progress on the web in general) and discussed a few tacks Microsoft could take to make IE8 more standardista-friendly.</p>

<p>One proposal that, to me, appeared to hold the most promise was one that involved extending IE8&#8217;s scheme of automatically opting-in unknown valid DOCTYPEs to also include Strict DOCTYPEs of <abbr title="HyperText Markup Language">HTML</abbr> and <abbr title="eXtensible HyperText Markup Language">XHTML</abbr> currently in use. The current proposal hinges on the relative popularity (or unpopularity) of a given DOCTYPE: unrecognized DOCTYPEs are assumed to be future or custom DOCTYPEs and will automatically be opted-in to the latest and greatest standards mode of any given future version of <abbr title="Internet Explorer">IE</abbr>; that is, <strong>until</strong> that DOCTYPE becomes &#8220;popular&#8221; enough to warrant associating it with a given version of <abbr title="Internet Explorer">IE</abbr>. This, in a nutshell, means that if a new DOCTYPE were to come along after IE8 launches&#8212;say, <abbr title="HyperText Markup Language">HTML</abbr> 5&#8212;IE8 would render it in standards mode, but if that DOCTYPE became &#8220;popular&#8221; before IE9 came out, IE9 would likely act as though it was IE8 when rendering those pages.</p>

<p>Chris Wilson did not have numbers on the relative popularity of Strict mode DOCTYPEs vs. Transitional and Frameset on either <abbr title="HyperText Markup Language">HTML</abbr> or <abbr title="eXtensible HyperText Markup Language">XHTML</abbr>, but given that most authoring tools do not automatically generate Strict documents, it is a strong possibility that the popularity of Strict mode DOCTYPEs may make them a candidate for being automatically opted-in to standards mode, at least in IE8. That would be great news for standards-aware developers who want IE8&#8217;s standards improvements, but don&#8217;t want to engage in version targeting.</p>
      ]]></content>
    </entry>

    <entry>
      <title>Server&#45;side FigureHandler thoughts</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/10/11/server-side-figurehandler-thoughts" />
      <id>tag:,2007:/archive/1.5</id>
      <published>2007-10-11T13:19:53Z</published>
      <updated>2010-02-25T14:30:54Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="coding"
        scheme="http://www.easy-reader.net/site/C158/"
        label="coding" />
      <category term="design"
        scheme="http://www.easy-reader.net/site/C156/"
        label="design" />
      <category term="programming"
        scheme="http://www.easy-reader.net/site/C157/"
        label="programming" />
      <content type="html"><![CDATA[
        <p>In reaction to <a href="http://www.alistapart.com/articles/figurehandler/">my latest article for A List Apart</a>, on <a href="http://code.google.com/p/easy-designs/wiki/FigureHandler">FigureHandler</a>, many folks have <a href="http://www.alistapart.com/comments/figurehandler?page=1#8">boldly claimed that this sort of thing</a> <a href="http://www.alistapart.com/comments/figurehandler?page=2#17">should be done server-side</a>. Below are my thoughts on the matter as posted as a comment in <a href="http://www.alistapart.com/comments/figurehandler/">the article&#8217;s discussion thread</a>.</p>
<blockquote cite="http://www.alistapart.com/comments/figurehandler?page=2#18">
<p>Many of you have brought up that this should be done server-side and, while I agree that it <em>could</em>, it would need to be done in the most flexible way possible (which many won&#8217;t bother with). You see, what this script allows quite easily is redesign; a designer can change page layout&#8212;"of an entire site <strong>or</strong> section by section&#8212;"without ever having to touch the back-end. It also allows for different columns to receive different figure classification schema.</p>
<p>If this were done on the content-entry side (as some have suggested), the image classifications would be stored in the database (or <abbr title="eXtensible Markup Language">XML</abbr> or whatever) along with the rest of the content <abbr title="HyperText Markup Language">HTML</abbr>. That means that if the design were to shift to a wider column (for example), the figures that once occupied a half-column, may no longer continue to do so, making the classifications hard-coded in the <abbr title="HyperText Markup Language">HTML</abbr> incorrect.</p>
<p>The only way to truly do this flexibly on the back end (as far as I can see) is to leave the classification step to be handled by a function which pre-processes the page output, dynamically assigning the classifications to each figure based on values obtained from the <abbr title="Cascading Style Sheets">CSS</abbr> for that page. Essentially, the script would need to go through the same steps as the JavaScript, but it would need to be able to go the extra step of determining applicable <abbr title="Cascading Style Sheets">CSS</abbr> rules to obtain the column width. Thankfully, most server-side languages support some means of <abbr title="Document Object Model">DOM</abbr> walking (albeit sometimes in less-than-desirable ways), but, as far as I know, none have a <abbr title="Cascading Style Sheets">CSS</abbr> parser, so you&#8217;d likely need to write that as well. From a server overhead point-of-view, I imagine that preprocessing would be fairly costly (most <abbr title="Document Object Model">DOM</abbr>-related stuff is), but the output for each page could be cached, reducing it somewhat.</p>
<p>If you&#8217;re interested in doing something like this, goodonya. I&#8217;ve built you a pretty decent roadmap for implementation, but I don&#8217;t imagine it will be easy to get it up and running. That said, I wish you luck&#8230;it would be yet another great tool for enabling designers to create consistent layouts with figures.</p>
</blockquote>
      ]]></content>
    </entry>

    <entry>
      <title>Alex Russell is not a heretic</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/09/10/alex-russell-is-not-a-heretic" />
      <id>tag:,2007:/archive/1.6</id>
      <published>2007-09-10T21:39:05Z</published>
      <updated>2010-02-25T14:32:06Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="animation"
        scheme="http://www.easy-reader.net/site/C155/"
        label="animation" />
      <category term="coding"
        scheme="http://www.easy-reader.net/site/C158/"
        label="coding" />
      <category term="design"
        scheme="http://www.easy-reader.net/site/C156/"
        label="design" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p>First off, let me preface this by saying I just got back to the East Coast after catching a red-eye from San Francisco on Saturday night, so if I seem a bit incoherent, that&#8217;s likely why.</p>
<p>In perhaps the most intellectually-stimulating session at <a href="http://therichwebexperience.com">The Rich Web Experience</a>, <a href="http://alex.dojotoolkit.org">Alex Russell</a> (of <a href="http://dojotoolkit.org">Dojo Toolkit</a> fame) tackled the topic of <a href="http://alex.dojotoolkit.org/?p=622">Standards Heresy</a>.</p>
<p>For those who are not aware, Alex was once a staunch standards advocate who has turned to what he considers, &#8220;the dark side.&#8221; In truth, he&#8217;s sick and tied of the dysfunctional nature of the <abbr title="World Wide Web Consortium">W3C</abbr> and other similar organizations and I can&#8217;t say I blame him. As his session pointed out, the <abbr title="World Wide Web Consortium">W3C</abbr> has 60+ paid, full-time staff and yet we saw literally no movement on either (X)<abbr title="HyperText Markup Language">HTML</abbr> or <abbr title="Cascading Style Sheets">CSS</abbr> for over five years. <em>That</em> is a travesty.</p>
<p>In my opinion, fault lies not with the individuals on the various committees and sub-committees, but rather, with the process. And this isn&#8217;t just a problem in the <abbr title="World Wide Web Consortium">W3C</abbr>, an organization comprised almost entirely of representatives from the various software vendors (Microsoft, <abbr title="America Online">AOL</abbr>, Opera, etc.) which pay tens of thousands a year to take part. Look at what&#8217;s happening with JavaScript 2 in ECMA. Or HTML5 for that matter&#8212;"just because it is an &#8220;open&#8221; organization which &#8220;anyone can join&#8221; doesn&#8217;t make the WHAT WG any better. They are all flawed because the process is flawed, and I think that is Alex&#8217;s main point (despite his assertion that the WHAT WG is not dysfunctional).</p>
<p>So why is the process flawed? Well, for one, spec writing is largely an academic undertaking. In many cases there are invited experts in a Working Group (such as Andy Clarke in the <abbr title="Cascading Style Sheets">CSS</abbr> one), but, for the most part, specs are written by people who are not in the trenches. As Alex rightly points out, in fact, many times, the specs are nothing more than an official blessing of some proprietary technique or technology created by a member company. And good ideas that may be very useful to designers or developers are lost because of internal politics or because a browser vendor thinks it would be &#8220;too hard&#8221; to implement.</p>
<p>Which brings me to Alex&#8217;s &#8220;heresy.&#8221; In his session, he proudly declared himself a heretic because he sees a need for innovation in (X)<abbr title="HyperText Markup Language">HTML</abbr> which is currently unavailable because the specs are not evolving quickly enough. I feel his pain, but I think he is looking at the problem the wrong way. He sees the spec (and web standards in general) as stifling innovation. I see web standards as facilitating innovation. After all, were it not for the firm foundation of well-formed documents and a unified <abbr title="Document Object Model">DOM</abbr> (no matter how piecemeal the implementations), we&#8217;d still be writing spaghetti code whenever we tried to do anything with JavaScript. It is because of web standards that we can write clean JavaScript and that we can make truly innovative interactions that take us beyond what is allowed for in the specs themselves.</p>
<p>But back to Alex&#8217;s complaint&#8230;as his example of how Dojo is heretical, he showed this code example:</p>
<pre><code>&#60;div dojoType="dijit.form.HorizontalSlider"
     name="horizontal1"
     onChange="dojo.byId('slider1input').value=arguments[0];"
     value="10"
     maximum="100"
     minimum="0"
     showButtons="false"
     intermediateChanges="true"
     style="width:50%; height: 20px;"
     id="slider1">
  ...
&#60;/div></code></pre>
<p>The problem that Dojo is attempting to solve here is the inclusion of a slider form control, which does not exist under <a href="http://w3.org/TR/html4/interact/forms.html">the current <abbr title="HyperText Markup Language">HTML</abbr> Forms spec</a>. In order to function, the widget requires several custom attributes to be placed on the element to provide information to assist in the creation of that slider. The fact that Alex &#8220;cannot&#8221; add these attributes to the document and maintain <abbr title="eXtensible HyperText Markup Language">XHTML</abbr> validity is a major source of annoyance for him and part of why he has decided that validation is no longer important.</p>
<p>But the truth is that Alex could make any or all of these attributes available to whatever elements he wants and still have a validating document by simply creating a <abbr title="Document Type Definition">DTD</abbr> (based on any existing (X)<abbr title="HyperText Markup Language">HTML</abbr> one) to include them. After all, the X in <abbr title="eXtensible HyperText Markup Language">XHTML</abbr> stands for extensible&#8230;the language is meant to be improved. Sure, there are some standardistas who think we shouldn&#8217;t muck about with the standards, but the powers that be put that extensibility in there for a reason (and I don&#8217;t think it was just as a tease). By extending the language to mix in features we desperately need, we drive innovation and, who knows, perhaps someone will take notice and add our extensions into the next version, thereby driving the evolution of the language so many of us desperately want.</p>
<p>The same goes for <abbr title="Cascading Style Sheets">CSS</abbr>. The <abbr title="World Wide Web Consortium">W3C</abbr> made <abbr title="Cascading Style Sheets">CSS</abbr> extensible by allowing for custom properties utilizing the <code>-*-</code> syntax. Chances are, you&#8217;ve come across this when implementing <code>-moz-border-radius</code> or <code>-webkit-border-radius</code> (which, honestly, both seem superfluous to me when the CSS3 spec includes <code>border-radius</code> as an actual property&#8230;why not just support that?). In my mind, this is ripe for use in extension of <abbr title="Cascading Style Sheets">CSS</abbr>, not by individual browser vendors (as that is proprietary and closed), but by us (in an open, cross-browser/cross-platform way) to achieve what we want or need that <abbr title="Cascading Style Sheets">CSS</abbr> currently does not offer us. That was the basis for my work on gFSS (an experiment in presentational Flash generated from <abbr title="Cascading Style Sheets">CSS</abbr>, debuted at Web Directions North this year) and another project I will be releasing in the next few months.</p>
<p>So, long story, long, I don&#8217;t think that Alex is a heretic. I think he can make a solid case for extending the language (and the interface) of the web for his particular needs (or the needs of his toolkit) as long as he backs it up with documentation in the form of a custom <abbr title="Document Type Definition">DTD</abbr>.</p>
<h3>An aside</h3>
<p>I do have one problem with what Alex wants, however (or at least what he chooses as a code example) and that problem is the extension of the language, but rather the way in which it was done (i.e. the DIV in his example will degrade to nothing without JavaScript enabled). <a href="http://dojotoolkit.org/book/dojo-book-0-4/part-8-internationalization-and-accessiblity/accessibility/web-accessibility-issu">Dojo supports WAI-ARIA</a> to improve the accessibility of this and many other widgets, which is commendable, but that extra markup is only generated when the Dojo methods are run. If JavaScript is turned off in his example, no form control is available whatsoever.</p>
<p>What I&#8217;d prefer to see is something like this:</p>
<pre><code>&#60;select class="dojo-form-horizontalSlider"
        name="horizontal1"
        showButtons="false"
        intermediateChanges="true"
        id="slider1">
  &#60;option>0&#60;/option>
  &#60;option>5&#60;/option>
  &#60;option selected="selected">10&#60;/option>
  ...
  &#60;option>100&#60;/option>
&#60;/select></code></pre>
<p>There&#8217;s nothing that could keep Dojo from parsing that bit of <abbr title="eXtensible HyperText Markup Language">XHTML</abbr> and gleaning from it what it needs to make the slider. And now, when Dojo doesn&#8217;t run, there is a degradable interface for the user to adjust the setting. Sure, it may not be nearly as nice, but at least it works. Plus, it allows Dojo to be added as a progressive enhancement, which is what it should be.</p>
<p>And to make this valid syntax, the Dojo team just needs to augment the <abbr title="eXtensible HyperText Markup Language">XHTML</abbr> 1.0 Strict <abbr title="Document Type Definition">DTD</abbr> like this to include the custom attributes:</p>
<pre><code>&#60;!ENTITY % Boolean
  "(true | false)"
  >
...
&#60;!-- attributes for Dojo Toolkit
  showButtons           display buttons (boolean)
  intermediateChanges   display intermediate steps (boolean)
-->
&#60;!ENTITY % dojo-attrs
  "showButtons          %Boolean    #IMPLIED
   intermediateChanges  %Boolean    #IMPLIED"
  >
...
&#60;!ATTLIST select
  %attrs;
  name        CDATA          #REQUIRED
  size        %Number;       #IMPLIED
  multiple    (multiple)     #IMPLIED
  disabled    (disabled)     #IMPLIED
  tabindex    %Number;       #IMPLIED
  onfocus     %Script;       #IMPLIED
  onblur      %Script;       #IMPLIED
  onchange    %Script;       #IMPLIED
  %dojo-attrs;
  ></code></pre>
<p>Sure, it takes a little extra work, but at least it gives users of the Dojo Toolkit the ability to validate their documents, which will help reduce potential <abbr title="Cascading Style Sheets">CSS</abbr> and JavaScript conflicts and errors (just one of the many benefits of web standards). Beyond that, it takes advantage of the extensibility of the language to facilitate innovation, and isn&#8217;t innovation what we all really want to see?</p>
      ]]></content>
    </entry>

    <entry>
      <title>A better createElementWithName()</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/08/27/a-better-createelementwithname" />
      <id>tag:,2007:/archive/1.59</id>
      <published>2007-08-27T15:44:36Z</published>
      <updated>2010-02-25T14:32:37Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="programming"
        scheme="http://www.easy-reader.net/site/C157/"
        label="programming" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p>Back in 2005, I wrote <a href="http://www.easy-reader.net/archives/2005/09/02/death-to-bad-dom-implementations/">a piece about <abbr title="Internet Explorer">IE</abbr>&rsquo;s abysmal generation of <code>NAME</code>d elements via the <abbr title="Document Object Model">DOM</abbr></a> (which, interestingly enough, has proven to be one of the most popular posts on the blog, pointing to the fact that this is an obvious pain point for many <abbr title="Document Object Model">DOM</abbr> scripters out there). The the time, I wrote</p>
<pre class="js"><code>function createElementWithName( type, name ){
  var element;
  // First try the <abbr title="Internet Explorer">IE</abbr> way; if this fails then use the standard way
  if( document.all ){
    element =
      document.createElement( '&lt; '+type+' name="'+name+'" /&gt;' );
  }else{
    element = document.createElement( type );
    element.setAttribute( 'name', name );
  }
  return element;
}</code></pre>
<p>It was a complete hack, but it worked. More importantly, however, it began a discussion of a better way to fix the problem in a cross-browser way. The best solution offered was <a href="http://www.arantius.com/" rel="external">Anthony Lieuallen</a>&rsquo;s very efficient one-time function definition:</p>
<pre class="js"><code>function createElementWithName(){}
(function(){
  try {
    var el=document.createElement( '&lt;div name="foo"&gt;' );
    if( 'DIV'!=el.tagName ||
        'foo'!=el.name ){
      throw 'create element error';
    }
    createElementWithName = function( tag, name ){
      return document.createElement( '&lt;' + tag + ' name="' +
        name + '"&gt;&lt;/' + tag + '&gt;' );
    }
  }catch( e ){
    createElementWithName = function( tag, name ){
      var el = document.createElement( tag );
      // setAttribute might be better here ?
      el.name = name;
      return el;
    }
  }
})();</code></pre>
<p>And now <a href="http://lojic.com/blog/" rel="external">Brian Adkins</a> has refactored the script to be even fewer lines of code:</p>
<pre class="js"><code>var createElementWithName = ( function(){
  try {
    var el = document.createElement( '&lt;div name="foo"&gt;' );
    if( el.tagName !== 'DIV' || el.name !== 'foo' ){
      throw 'create failed';
    }
    return function( tag, name ){
      return document.createElement( '&lt;' + tag + ' name="' +
        name + '"&gt;&lt;/' + tag + '&gt;' );
    };
  }catch( e ){
    return function( tag, name ){
      var el = document.createElement( tag );
      el.setAttribute( 'name', name );
      return el;
    };
  }
})();</code></pre>
<p>Geat job Brian, thanks for sharing.</p>
      ]]></content>
    </entry>

    <entry>
      <title>Tipr, now with added txt</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/07/29/tipr-now-with-added-txt" />
      <id>tag:,2007:/archive/1.60</id>
      <published>2007-07-29T19:50:52Z</published>
      <updated>2010-02-25T14:32:53Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="business"
        scheme="http://www.easy-reader.net/site/C154/"
        label="business" />
      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="programming"
        scheme="http://www.easy-reader.net/site/C157/"
        label="programming" />
      <content type="html"><![CDATA[
        <p>So, as it turns out, <a href="http://tipr.mobi">this little app I built for myself</a> is actually useful to other folks.</p>
<p>Over the 3 weeks since it launched, I&rsquo;ve been keeping an eye on the traffic patterns, reviews, and mentions of Tipr across the intarwebs, but I&rsquo;ve also been busily adding some new features, which brings me to this post. I knew people with iPhones and other capable mobile browsers were quite happy with Tipr, but folks without a mobile browser or with a sucky one were not, in my opinion, getting as much out of Tipr as I&rsquo;d like them to. I wanted to correct that.</p>
<p>My first thought was to create an SMS service for Tipr, but there&rsquo;s no way I can afford to rig up a server capable of receiving and replying to SMS messages and I certainly could not afford to pay the $1000-2000/month for an SMS short code (after all, I&rsquo;m not making any money on this thing). Then the answer dawned on me: <a href="http://twitter.com">Twitter</a>.</p>
<p><img class="alt-feature" src="http://farm2.static.flickr.com/1228/942768366_aae7fe823b_o.png" /></p>
<p>Since Twitter offers an SMS interface (40404 once you register your mobile), I could simply piggy back on their service to offer Tipr via SMS. All I had to do was build a TwitterBot capable of receiving and responding to messages. Lots of folks have built <abbr title="Instant Message">IM</abbr> bots in the past, but there weren&rsquo;t that many TwitterBots and there was even less information about building one. Even with the odds stacked against me, however, after about an hour of reading <a href="http://groups.google.com/group/twitter-development-talk/web/api-documentation">the Twitter <abbr title="Application Programming Interface">API</abbr> documentation</a> and 6 hours of actual programming, I had built a working <abbr title="Hypertext PreProcessor">PHP</abbr>-based TwitterBot class.</p>
<p>The whole thing works using Twitter&rsquo;s direct message functionality and runs several independent services to do things like reciprocate friendships, check the inbox, process responses, and send messages back. Unfortunately, the <abbr title="Application Programming Interface">API</abbr> was only able to get me so far, so I did have to resort to a little hackery to get some of it to work, but in the end, the Tipr TwitterBot, which sits on top of my generic TwitterBot class is pretty solid and quite responsive &mdash; even with the 70 <abbr title="Application Programming Interface">API</abbr> calls in 60 minutes limitation, most messages receive a response in approximately 45 seconds (depending on your network and whether Twitter is releasing a new feature and takes the service offline for a few minutes).</p>
<p>Overall, I&rsquo;m pretty happy with the results and the early beta testers seem to be liking it as well. Hopefully some of you out there will find it as useful (if not more so) than the web interface. If you&rsquo;re on Twitter, <a href="http://tipr.mobi/twitter.php">give it a shot</a> and let me know what you think.</p>
      ]]></content>
    </entry>

    <entry>
      <title>New Easy! app: Tipr</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/07/12/new-easy-app-tipr" />
      <id>tag:,2007:/archive/1.61</id>
      <published>2007-07-12T19:07:05Z</published>
      <updated>2010-02-25T14:33:06Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="business"
        scheme="http://www.easy-reader.net/site/C154/"
        label="business" />
      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <content type="html"><![CDATA[
        <p>Those of you who&rsquo;ve been paying attention to the apps that came out of <a href="http://barcamp.org/iPhoneDevCamp">iPhoneDevCamp</a> (or who are using <a href="http://applists.com">Applists</a>, <del><a href="http://web.archive.org/web/20071225132153/appmarks.com/main/">AppMarks</a>,</del> or any of the other iPhone web app aggregators/launchers) are probably already aware, but we just launched our first micro-application named &ldquo;Tipr&rdquo; last week.</p>
<p><a href="http://tipr.mobi">Tipr is a super-simple web-based tip calculator</a> aimed at mobile devices. You simply enter the bill total and choose a percentage to tip and Tipr does the rest, giving you the tip amount and the total. As an added benefit, the total is always converted to a palindrome to make it easy to spot fraudulent adjustment of your tip amount or total when scanning your credit card or bank statement.</p>
<p>Tipr started off as a tool for me, really. I have been doing the palindrome thing for over a year now and, even with the calculator on my phone, it takes a minute or so for me to calculate out the tip amount to end up with a palindrome for a total. To speed things up a bit for myself, I built Tipr and it&rsquo;s proven quite useful. I hope you will find it useful too.</p>
<p>We&rsquo;re trying to keep Tipr pretty simple, but if you have recommendations for improving it, let us know by leaving a comment.</p>
      ]]></content>
    </entry>

    <entry>
      <title>Wouldn&#8217;t it be nice?</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/06/27/wouldnt-it-be-nice" />
      <id>tag:,2007:/archive/1.62</id>
      <published>2007-06-27T21:25:26Z</published>
      <updated>2010-02-25T14:33:27Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="coding"
        scheme="http://www.easy-reader.net/site/C158/"
        label="coding" />
      <category term="design"
        scheme="http://www.easy-reader.net/site/C156/"
        label="design" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p><img alt=" " class="alt-feature" src="http://farm2.static.flickr.com/1025/641641966_705587ae5b.jpg?v=0" /></p>
<p>Over the last two years, I&rsquo;ve been wishing for just one thing in CSS: rotation. There&rsquo;s been some discussion about it on the <abbr title="World Wide Web Consortium">W3C</abbr> lists, etc. but no one has made a solid pitch for it yet. Inspired a bit by <a href="http://www.stuffandnonsense.co.uk/archives/css3_multi-column_thriller.html">Andy&rsquo;s modest <code>column-rule-image</code> proposal</a>, I drafted <a href="/docs/CSS-rotation.pdf">a spec for <abbr title="Cascading Style Sheets">CSS</abbr> 3 Rotation</a> [<abbr title="Portable Document Format">PDF</abbr>] back in February. I showed it to a few folks at Web Directions North and got some good feedback.</p>
<p>Out of those discussions, I also realized we really needed a text-wrapping property in <abbr title="Cascading Style Sheets">CSS</abbr> 3, so I also drafted <a href="/docs/CSS-polygonal-margins.pdf">a spec for <abbr title="Cascading Style Sheets">CSS</abbr> 3 Polygonal Margins</a> [<abbr title="Portable Document Format">PDF</abbr>]. The idea is based on the polygons we used for image maps back in the day and would allow complete control over how text wraps around an element.</p>
<p>Anyway, I&rsquo;ve sat on these for a while and I figured now was as good a time as any to unveil them to the world and solicit your feedback. So what do you think? Could you use this sort of control in your everyday <abbr title="Cascading Style Sheets">CSS</abbr> work? How would you want to see it work? Do you think the plans I&rsquo;ve outlined offer enough flexibility?</p>
      ]]></content>
    </entry>

    <entry>
      <title>Whoops&#8230;</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/06/26/whoops" />
      <id>tag:,2007:/archive/1.63</id>
      <published>2007-06-26T16:58:19Z</published>
      <updated>2010-02-25T14:35:20Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <content type="html"><![CDATA[
        <p>I was doing a little server cleanup and moved this site&rsquo;s folder, forgetting to set the new folder up for mod_rewrite, so permalinks have been broken for the last week or so. Everything is better now (I hope). Please let me know if you notice any lingering issues.</p>
      ]]></content>
    </entry>

    <entry>
      <title>WebVisions wrapped</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/05/04/webvisions-wrapped" />
      <id>tag:,2007:/archive/1.64</id>
      <published>2007-05-04T17:58:13Z</published>
      <updated>2010-02-25T14:37:14Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="business"
        scheme="http://www.easy-reader.net/site/C154/"
        label="business" />
      <category term="presentations"
        scheme="http://www.easy-reader.net/site/C160/"
        label="presentations" />
      <content type="html"><![CDATA[
        <p>I just wrapped my presentation at WebVisions and have posted the slides for my talk, titled &ldquo;Learning to Love Forms,&rdquo; up on <a href="http://www.slideshare.net">SlideShare</a>. I have also embedded them below (though the formatting is a bit off on some of the longer sidebars).</p>
<p>I&rsquo;d like to thank everyone who attended and especially those who asked the challenging questions. Hopefully this was a good start to my campaign for getting people to embrace forms instead of running from them.</p>
<p>For those of you who couldn&rsquo;t attend, enjoy the slides. I will post the audio for the session as soon as it&rsquo;s available.</p>
<p>
<object data="https://s3.amazonaws.com:443/slideshare/ssplayer.swf?id=45589&amp;doc=learning-to-love-forms-webvisions-07-21033" height="348" type="application/x-shockwave-flash" width="425">
<param name="src" value="https://s3.amazonaws.com:443/slideshare/ssplayer.swf?id=45589&amp;doc=learning-to-love-forms-webvisions-07-21033" />
</object>
</p>
      ]]></content>
    </entry>

    <entry>
      <title>&#8220;Ruining&#8221; reactions</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/04/08/ruining-reactions" />
      <id>tag:,2007:/archive/1.65</id>
      <published>2007-04-08T16:49:55Z</published>
      <updated>2010-02-25T14:39:57Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="business"
        scheme="http://www.easy-reader.net/site/C154/"
        label="business" />
      <category term="books &amp; articles"
        scheme="http://www.easy-reader.net/site/C161/"
        label="books &amp; articles" />
      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="accessibility"
        scheme="http://www.easy-reader.net/site/C164/"
        label="accessibility" />
      <category term="programming"
        scheme="http://www.easy-reader.net/site/C157/"
        label="programming" />
      <category term="web standards"
        scheme="http://www.easy-reader.net/site/C159/"
        label="web standards" />
      <content type="html"><![CDATA[
        <p>There&rsquo;s been <a href="http://www.alistapart.com/comments/ruininguserexperience/">some great discussion</a> surrounding <a href="http://www.alistapart.com/articles/ruininguserexperience/">my latest article for <cite>A List Apart</cite></a>. It is amazing to see how some people get the idea of progressive enhancement and some just don&rsquo;t (or perhaps refuse to).</p>
<p>Many folks brought up the point that having requirements for a web-based application is akin to having requirements for a desktop one.  I couldn&rsquo;t agree more, which is why, while discussing some of the shortsighted design choices made by the folks at <a href="http://lala.com">Lala.com</a>, I said</p>
<blockquote cite="http://www.alistapart.com/articles/ruininguserexperience/">
<p>For a closed application or service, this might be acceptable, but for a public website it&rsquo;s a disaster.</p>
</blockquote>
<p>&ldquo;Public website&rdquo; is the key there. Lala.com is open to the world. To see the homepage, browse around, or search you don&rsquo;t have to sign up; you don&rsquo;t have to agree to do anything. The public-facing portion of the website is open to everyone, so it should be <em>open to everyone</em>.</p>
<p>When you start talking about closed applications, such as GMail or Basecamp or a <abbr title="Content Management System">CMS</abbr>, it is acceptable to create a set of requirements for your users. After all, they are <em>choosing</em> to use your service. Keep in mind, however, that even when introducing flashy JavaScript-based functionality you should still be keeping your markup clean and semantic and that you should do your best to follow at least the basic accessibility guidelines, especially if you are charging for your app. Even Google came to the realization that they needed a non-<abbr title="JavaScript">JS</abbr> version of GMail, so you should never rule out having to go that route. And planning for it from the beginning makes it a hell of a lot easier to implement.</p>
<p>One active member of the discussion I&rsquo;d like to single out is Jean McGuire. Her comments have been very thoughtful and I&rsquo;d like to take a moment to share a wonderful analogy she made:</p>
<blockquote cite="http://www.alistapart.com/comments/ruininguserexperience?page=2#15">
<p>For example, if you owned an outdoor goods store, wouldn&rsquo;t it be a cool idea to have the entrance on the second floor, and have a climbing wall in front to get to it? That would be new! different! unique! But, even leaving out handicapped accessibility requirements (and how much the <span class="caps">UPS</span> guy would hate you) do you think any store owner would be that bloody stupid?</p>
<p>Sure, maybe most of the customers would be experienced climbers and would have no problem with the wall. Some might even think it&rsquo;s fun, not just annoying. But what about the non-climbers shopping for birthday presents for climbers? What about the person who just needs fifty meters of really good rope? What about the person bringing a spouse&rsquo;s sleeping bag in to get a new zipper? What about the climber with one arm in a cast? For that matter, what about the newspaper reporter coming to do a local business profile on your store? (aka a search engine spider)</p>
</blockquote>
<p>Isn&rsquo;t that just fantastic?</p>
<p>I am really happy that this piece has garnered so many reactions and had gotten people both talking and, most importantly, thinking.</p>
      ]]></content>
    </entry>

    <entry>
      <title>Naked again</title>
      <link rel="alternate" type="text/html" href="http://www.easy-reader.net/archives/2007/04/04/naked-again" />
      <id>tag:,2007:/archive/1.66</id>
      <published>2007-04-04T23:06:14Z</published>
      <updated>2010-02-25T14:40:16Z</updated>
      <author>
            <name>Aaron Gustafson</name>
            <email>aaron@easy-designs.net</email>
                  </author>

      <category term="design &amp; development"
        scheme="http://www.easy-reader.net/site/C151/"
        label="design &amp; development" />
      <category term="coding"
        scheme="http://www.easy-reader.net/site/C158/"
        label="coding" />
      <category term="design"
        scheme="http://www.easy-reader.net/site/C156/"
        label="design" />
      <content type="html"><![CDATA[
        <p>That&rsquo;s right, we&rsquo;ve dropped our <abbr title="Cascading Style Sheets">CSS</abbr> to celebrate <a href="http://naked.dustindiaz.com/"><abbr title="Cascading Style Sheets">CSS</abbr> Naked Day</a>. Your turn.</p>
      ]]></content>
    </entry>


</feed>