<?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>Ajax Bestiary &#187; Development</title>
	<atom:link href="http://www.ajaxbestiary.com/tag/development/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ajaxbestiary.com</link>
	<description>AJAX Development, News, Techniques &#38; More</description>
	<lastBuildDate>Wed, 01 Feb 2012 12:46:54 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Getting Started With Chrome Frame</title>
		<link>http://www.ajaxbestiary.com/2011/06/06/getting-started-with-chrome-frame/</link>
		<comments>http://www.ajaxbestiary.com/2011/06/06/getting-started-with-chrome-frame/#comments</comments>
		<pubDate>Tue, 07 Jun 2011 02:47:24 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Browsers]]></category>
		<category><![CDATA[Chrome]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Internet Explorer]]></category>
		<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[Chrome frame]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Trident]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/?p=416</guid>
		<description><![CDATA[As a follow up to my last post, I thought I&#8217;d put out an instruction on actually creating a Google Chrome retreat. Step 1: Add a Chrome Frame header to your site. Add this to the head of the Chrome Frame dependent pages: &#60;meta http-equiv="X-UA-Compatible" content="chrome=1"&#62;. If this isn&#8217;t practical, You can also configure your [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>As a follow up to my last post, I thought I&#8217;d put out an instruction on actually creating a Google Chrome retreat.</p>
<h3>Step 1: Add a Chrome Frame header to your site.</h3>
<p>Add this to the head of the Chrome Frame dependent pages:</p>
<p><code>&lt;meta</code> <code>http-equiv</code><code>=</code><code>"X-UA-Compatible"</code> <code>content</code><code>=</code><code>"chrome=1"</code><code>&gt;. </code></p>
<p>If this isn&#8217;t practical, You can also configure your server to send an HTTP header of</p>
<p><code>X-UA-Compatible: </code><code>chrome=1</code></p>
<p>I advise against this approach, however because server configs won&#8217;t be immediately available to other users on a site.  By its nature, a Chrome Frame retreat should be considered a reasonably unique event.  It&#8217;s good to clearly document this dependency for anyone else who may need to debug things later.  Once you&#8217;ve started to retreat, make sure you&#8217;re applying the header to every page of the site.  The two engines render things differently and you may create an inconsistent experience for your users if they are transitioning between Chrome Frame and Trident environments frequently.  In my experience, border-radius and drop shadow toggling on and off is a pretty strong &#8220;It&#8217;s Broken&#8221; signal for end users.</p>
<p>Step 2: Identify your Dependency Wall.</p>
<ol>
<li>Identify the range of pages / screens in your web app that you can&#8217;t support in IE.</li>
<li>Identify the navigation routes to those pages.</li>
<li>Leverage the routes to find natural locations for gatekeepers.
<ol>
<li>
<ol>
<li>Login Screens (the perfect location)</li>
<li>Tutorial Screens (A natural context fit for users)</li>
<li>An Advanced Mode (Similar to the &#8220;enriched mode&#8221; Microsoft uses for ActiveX requiring cloud apps).</li>
</ol>
</li>
</ol>
<ul>
<li>If you&#8217;re lucky, this will be a screen somewhere beyond your conversion pipeline.</li>
</ul>
</li>
<li>Create an interception event for IE users.  You can bake this into your app, but the easy way is with conditional comments.
<ol>
<li>Identify the Dom Nodes in your layout that must be presented to the user for them to progress.</li>
<li>&lt;div id=&#8217;loginbox&#8217;&gt;&#8230;&lt;/div&gt;</li>
<li>Create a conditional comment to hide the nodes and prompt the user to install Chrome Frame.</li>
</ol>
<ol>
<li>Be careful of z-index.  The chrome install iframe doesn&#8217;t work well if IE is floating some other content node on top of the install button.</li>
<li>UN-INSTALL chrome frame once you&#8217;ve tested your retreat perimeter.  This is a big deal for ongoing development as you won&#8217;t be testing in IE otherwise.</li>
<li>Becareful about your conversion pipeline.  Your key selling points may be behind the perimeter, but the act of demanding Chrome Frame is a pretty severe barrier to forward movement.</li>
</ol>
</li>
<p><code>&lt;html&gt;<br />
&lt;body&gt; &lt;div id='prompt'&gt;&lt;/div&gt;</code><code> &lt;!--[if IE]&gt;</code><br />
<code> &lt;script</code> <code>type</code><code>=</code><code>"text/javascript"</code><br />
<code> src</code><code>=</code><code>"http://ajax.googleapis.com/ajax/libs/chrome-frame/1/CFInstall.min.js"</code><code>&gt;</code><code>&lt;/script&gt;</code><br />
<code> &lt;style&gt;<br />
#loginBox{<br />
display:none;<br />
}<br />
&lt;/style&gt; </code><span style="color: #351c75;"></span><br />
<code> &lt;script&gt; </code></p>
<p><code> window.attachEvent("onload", function() {</code><br />
<code> </code><code>CFInstall</code><code>.</code><code>check</code><code>({</code><br />
<code> mode: </code><code>"inline"</code><code>, </code><br />
<code> </code><code>}); </code> });<br />
<code> &lt;/script&gt; </code><code> &lt;![endif]--&gt;</code><br />
<code>&lt;/body&gt;<br />
&lt;/html&gt;</code></p>
<h3>Other Lessons Learned</h3>
<p>Here&#8217;s a few lessons learned from deploying this.</p>
<p>&nbsp;</ol>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2011/06/06/getting-started-with-chrome-frame/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Notes On My First Few Days With Hype</title>
		<link>http://www.ajaxbestiary.com/2011/06/02/notes-on-my-first-few-days-with-hype/</link>
		<comments>http://www.ajaxbestiary.com/2011/06/02/notes-on-my-first-few-days-with-hype/#comments</comments>
		<pubDate>Thu, 02 Jun 2011 10:39:35 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Tools]]></category>
		<category><![CDATA[Animation]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Hype]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/?p=407</guid>
		<description><![CDATA[For those of you not aware, Hype is a new OSX app for building interactive HTML5 in a Timeline / WYSIWYG interface. It&#8217;s not the first product in the space (Sencha Animator), it&#8217;s the first well publicized version 1.0 I&#8217;ve come across.  It&#8217;s also pretty reasonably priced at 29.99 a seat. First the good points: [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>For those of you not aware,<a href="http://tumultco.com/hype/"> Hype is a new OSX app for building interactive HTML5 in a Timeline / WYSIWYG interface.</a></p>
<p>It&#8217;s not the first product in the space (<a href="http://www.sencha.com/products/animator/demos/">Sencha Animator</a>), it&#8217;s the first well publicized version 1.0 I&#8217;ve come across.  It&#8217;s also pretty reasonably priced at 29.99 a seat.</p>
<h3>First the good points:</h3>
<ul>
<li><strong>Ease of use</strong>: This is definitely a pretty straightforward tool in this regard.</li>
<li><strong>Interoperability:</strong> The Hype API and ability to execute arbitrary javascript inside the page DOM make this a great option for extending the capabilities of an existing web app.  I&#8217;d obviously like it to be richer, but it&#8217;s a decent compromise for a rev 1 product.</li>
<li><strong>OS integration:</strong> For those of us on OSX, the drag and drop support  and polished UI are incredibly nice.</li>
</ul>
<h3>So what needs improvement:</h3>
<ul>
<li><strong>Animation along a path with key frames</strong>:  I realize this isn&#8217;t as embodied in css3 transforms as other options, but <a href="http://developer.yahoo.com/yui/examples/animation/control.html">YUI Animation</a> and Sencha Animator do it, so It&#8217;s demonstrably possible.</li>
<li><strong>Dynamic Sprite creation:</strong> The fact we can play arbitrary timelines from javascript is nice, but I would like to be able to add timelines to the frame.</li>
<li><strong>Direct Sprite manipulation:</strong> Changing sprite colors or the text in a block might be useful.</li>
</ul>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2011/06/02/notes-on-my-first-few-days-with-hype/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Using the jQuery data method as a local datastore</title>
		<link>http://www.ajaxbestiary.com/2009/10/15/using-the-jquery-data-method-as-a-local-datastore/</link>
		<comments>http://www.ajaxbestiary.com/2009/10/15/using-the-jquery-data-method-as-a-local-datastore/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 23:37:37 +0000</pubDate>
		<dc:creator>Dave Mahon</dc:creator>
				<category><![CDATA[Article]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/?p=346</guid>
		<description><![CDATA[At some point, we all have to store datasets on the client. We can clutter the namespace with ever more variables and try really hard to avoid collisions. We can cram variables into some local object that we’re using in the normal execution of our script anyway. We can attach custom attributes to HTML nodes, [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>At some point, we all have to store datasets on the client. We can clutter the namespace with ever more variables and try really hard to avoid collisions. We can cram variables into some local object that we’re using in the normal execution of our script anyway. We can attach custom attributes to HTML nodes, violating the sacrosanct purity of XHTML.</p>
<p>Or we can attach the document-specific variables, in script (thus keeping those automated validators happy), to the document itself. This fairly intuitive approach has not been given the notice it deserves.</p>
<p>Some advantages:</p>
<ol>
<li><span style="color: #333333;">Arbitrary value names can be assigned and we can basically assign as many of these variables as we want.</span></li>
<li><span style="color: #333333;">They can be applied to anything jQuery can access, meaning that we can rapidly assign values to entire sets of DOM nodes without having to add CSS classes or clutter the markup.</span></li>
<li><span style="color: #333333;">They can be dynamically added, accessed, changed and removed at will, without network transfers.</span></li>
</ol>
<p><span style="color: #333333;">There is the disadvantage that they are not persistent across page loads, but we’ve lived with that problem for a long, long time, haven’t we?</span></p>
<p>So how do we use this handy method? <a href="http://docs.jquery.com/Internals/jQuery.data">The documentation</a> is pretty clear cut, but I’ll give a slightly more grounded example:</p>
<p>My HTML is very simplistic in this example:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
</pre></td><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">body</span>&gt;</span>
 <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">span</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;stats&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">span</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">button</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;add&quot;</span>&gt;</span>Add Data Point<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">button</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">button</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;reset&quot;</span>&gt;</span>Reset Set<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">button</span>&gt;</span>
 <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
 <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;data&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">body</span>&gt;</span></pre></td></tr></table></div>

<p>The JavaScript is similarly intuitive:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;">appExample <span style="color: #339933;">=</span> <span style="color: #009900;">&#123;</span>
 addDataPoint<span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  <span style="color: #003366; font-weight: bold;">var</span> dat <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">getDataSet</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  dat<span style="color: #009900;">&#91;</span>dat.<span style="color: #660066;">length</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> Math.<span style="color: #660066;">floor</span><span style="color: #009900;">&#40;</span>Math.<span style="color: #660066;">random</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">*</span><span style="color: #CC0000;">101</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#data'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'points'</span><span style="color: #339933;">,</span> dat<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
 resetDataSet<span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#data'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">removeData</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'points'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
 dataSize<span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  <span style="color: #003366; font-weight: bold;">var</span> dat <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">getDataSet</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #000066; font-weight: bold;">return</span> dat.<span style="color: #660066;">length</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
 getDataSet<span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  <span style="color: #003366; font-weight: bold;">var</span> dat <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#data'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'points'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>undefined <span style="color: #339933;">==</span> dat<span style="color: #009900;">&#41;</span> <span style="color: #000066; font-weight: bold;">return</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
  <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>Array <span style="color: #339933;">!=</span> dat.<span style="color: #660066;">constructor</span><span style="color: #009900;">&#41;</span> <span style="color: #000066; font-weight: bold;">return</span> <span style="color: #009900;">&#91;</span>dat<span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
  <span style="color: #000066; font-weight: bold;">return</span> dat<span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
 updateDisplay<span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#stats'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">text</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'Data Points: '</span> <span style="color: #339933;">+</span> <span style="color: #009900;">&#40;</span>lim <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">dataSize</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #003366; font-weight: bold;">var</span> tmp <span style="color: #339933;">=</span> <span style="color: #3366CC;">''</span><span style="color: #339933;">;</span>
  <span style="color: #003366; font-weight: bold;">var</span> dat <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">getDataSet</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #000066; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">var</span> i <span style="color: #339933;">=</span> <span style="color: #CC0000;">0</span><span style="color: #339933;">;</span> i <span style="color: #339933;">&lt;</span> lim<span style="color: #339933;">;</span> i<span style="color: #339933;">++</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
   tmp <span style="color: #339933;">+=</span> dat<span style="color: #009900;">&#91;</span>i<span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
   <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>i <span style="color: #339933;">&lt;</span> lim <span style="color: #339933;">-</span> <span style="color: #CC0000;">1</span><span style="color: #009900;">&#41;</span> tmp <span style="color: #339933;">+=</span> <span style="color: #3366CC;">','</span><span style="color: #339933;">;</span>
  <span style="color: #009900;">&#125;</span>
  $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#data'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">text</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'['</span> <span style="color: #339933;">+</span> tmp <span style="color: #339933;">+</span> <span style="color: #3366CC;">']'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
$<span style="color: #009900;">&#40;</span>document<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">ready</span><span style="color: #009900;">&#40;</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
 appExample.<span style="color: #660066;">updateDisplay</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#add'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">bind</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'click'</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  appExample.<span style="color: #660066;">addDataPoint</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  appExample.<span style="color: #660066;">updateDisplay</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#reset'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">bind</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'click'</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  appExample.<span style="color: #660066;">resetDataSet</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  appExample.<span style="color: #660066;">updateDisplay</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<p>In this case, I’m storing everything as an array in points. While I’m storing randomly generated integers, you can just as easily store entire objects, opening the possibility of a JSON solution.</p>
<p>Note that we can identify those objects lacking the chosen dynamic attribute by <em>calling it</em> and testing for undefined.</p>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2009/10/15/using-the-jquery-data-method-as-a-local-datastore/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Backup Systems</title>
		<link>http://www.ajaxbestiary.com/2007/11/26/backup-systems/</link>
		<comments>http://www.ajaxbestiary.com/2007/11/26/backup-systems/#comments</comments>
		<pubDate>Mon, 26 Nov 2007 15:23:10 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Process]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/2007/11/26/backup-systems/</guid>
		<description><![CDATA[This is a bit off topic for this blog, but is something that has very much been on my mind lately.  I&#8217;ve been maintaining an archive of all of my work over the past 12 years.  Everything from coursework to UI markups, Personal Notes to SVN repositories all lived in a set of redundant 750 [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>This is a bit off topic for this blog, but is something that has very much been on my mind lately.  I&#8217;ve been maintaining an archive of all of my work over the past 12 years.  Everything from coursework to UI markups, Personal Notes to SVN repositories all lived in a set of redundant 750 gb external hard drives.  Over the years , I&#8217;ve found these archives to be an invaluable asset (especially with modern desktop search tools).  Last monday, those drives were stolen.</p>
<p>Although I can cope without the data, I need to start compiling a new personal archive &amp; I&#8217;m curious what other people have done for backup systems &amp; how you deal with offsite backup of personal data.</p>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2007/11/26/backup-systems/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Standardizing On A Framework</title>
		<link>http://www.ajaxbestiary.com/2007/10/16/standardizing-on-a-framework/</link>
		<comments>http://www.ajaxbestiary.com/2007/10/16/standardizing-on-a-framework/#comments</comments>
		<pubDate>Tue, 16 Oct 2007 19:56:06 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Article]]></category>
		<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/2007/10/16/standardizing-on-a-framework/</guid>
		<description><![CDATA[Organizational standards are wonderful things.  They enforce consistency, help insure institutional competence and can dramatically reduce the learning curve to get additional staff up to speed on a project.  At the same time, in the world of AJAX standards can be too slow to adapt to a constantly changing landscape.  How do you strike a [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>Organizational standards are wonderful things.  They enforce consistency, help insure institutional competence and can dramatically reduce the learning curve to get additional staff up to speed on a project.  At the same time, in the world of AJAX standards can be too slow to adapt to a constantly changing landscape.  How do you strike a balance between flexibility and consistency?</p>
<p><span id="more-123"></span> <span style="font-weight: bold">Project Specific Framework Selection</span></p>
<p>This is one of the most common approaches and is definitely the most flexible.  Project specific standards basically let the needs of a given project describe the choice of frameworks.  A project needing lots of animation and color manipulation may be built using mootools, a complex RIA may be built using dojo &amp; a simpler project may use prototype or jQuery.  The problem with this approach is the frequent need to learn new API&#8217;s &amp; potential to develop overly superficial knowledge of toolkits that may lead to unnecessarily cumbersome solutions.</p>
<p style="font-weight: bold">Selection of Approved Frameworks</p>
<p>A step beyond project specific framework selection is the adoption of 2 &#8211; 4 approved frameworks within an organization.  In this arrangement, you try to achieve a balance between project appropriateness and standardization.  Usually the frameworks are chosen to accommodate different scales of projects.  A natural breakdown is the use of prototype &amp; scriptaculous where scriptaculous may not be used in every project.  Another breakdown may combine a simple framework like prototype with a RIA platform like Dojo &amp; an intermediate toolkit like jQuery.  In any event, it&#8217;s usually a good idea to pick platforms with similar coding styles &amp; api&#8217;s to maximize the transference of skills between projects.</p>
<p><span style="font-weight: bold">Standardizing on a Single Framework</span></p>
<p>This is definitely a popular approach and prevents any problems with developers needing to relearn things to get up to speed on different projects. Unfortunately, it&#8217;s a very high risk approach as toolkits frequently aren&#8217;t optimal for every project (e.g. dojo for a brochureware site and prototype for a webmail client).  There&#8217;s also the unfortunate possibility of a framework transitioning to an inappropriate licensing model or being abandoned as well.</p>
<p><span style="font-weight: bold">Standardized Coding Practices</span></p>
<p>This is a strategy that can be adopted independent of your framework strategy.  basically, since so many of the various frameworks share constructs and they are all based on javascript.   Adopting a set of coding standards can dramatically simplify collaborative development.  Some of the strategies to consider are:</p>
<ul>
<li>Standardized Naming Conventions (camelcase, underscore etc.)</li>
<li>Standardized File Names</li>
<li>Standardized Function Names</li>
<li>Comment Formating</li>
<li>Chaining limits</li>
</ul>
<p>We&#8217;ll discus coding standards more in the future, but since I&#8217;ve had several recent discussions on adopting a standard for my organization.  I thought I&#8217;d share some of our thoughts with you.</p>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2007/10/16/standardizing-on-a-framework/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Roll Your Own JS Framework: Is It Necessary?</title>
		<link>http://www.ajaxbestiary.com/2007/10/08/roll-your-own-js-framework-is-it-necessary/</link>
		<comments>http://www.ajaxbestiary.com/2007/10/08/roll-your-own-js-framework-is-it-necessary/#comments</comments>
		<pubDate>Mon, 08 Oct 2007 15:47:04 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Article]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Toolkit Profile]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/2007/10/08/roll-your-own-js-framework-is-it-necessary/</guid>
		<description><![CDATA[Dustin Diaz recently posted about Rolling out your own javascript interface in his blog. http://www.dustindiaz.com/roll-out-your-own-interface/  While his code is nice and clean and it does provide what he was hoping to achieve: There are times when using a JavaScript library is called for. Building large web applications that use a wide array of utility functions [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>Dustin Diaz recently posted about Rolling out your own javascript interface in his blog.</p>
<p><a href="http://www.dustindiaz.com/roll-out-your-own-interface/">http://www.dustindiaz.com/roll-out-your-own-interface/ </a></p>
<p>While his code is nice and clean and it does provide what he was hoping to achieve:</p>
<blockquote><p>There are times when using a JavaScript library is called for. Building large web applications that use a wide array of utility functions that help aid in developing multi-tiered class systems, advanced UI components, complex event models, and heavy use of DOM scripting helpers. Yep. Those are all great.<br />
However, there are other times when you don’t need all that. And often what we end up doing is just importing a few of our favorite functions as globals, and work off those. But what ends up happening in this case is that we lose the particular style that these libraries offer.</p></blockquote>
<p>In essence, he&#8217;s offering a light weight solution to the fundamental issue persistent to all javascript development: (&#8220;javascript sucks&#8221;). His solution is to coble together a light weight version of prototype containing only what he needs.</p>
<p>My questions are three fold:</p>
<ol>
<li>Is rolling your own framework worth it? The new generation of code profilers for the various toolkits can dramatically decrease download size and focus on the functionality needed.</li>
<li>Is there sufficient demand for a new ultra light weight toolkit to address these issues?</li>
<li>Why not use full toolkits:  Many of them are small enough in compressed form not to make a noticeable difference in load times.</li>
</ol>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2007/10/08/roll-your-own-js-framework-is-it-necessary/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Excellent Resource for Learning MooTools</title>
		<link>http://www.ajaxbestiary.com/2007/10/04/excellent-resource-for-learning-mootools/</link>
		<comments>http://www.ajaxbestiary.com/2007/10/04/excellent-resource-for-learning-mootools/#comments</comments>
		<pubDate>Thu, 04 Oct 2007 19:56:38 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[mootools]]></category>
		<category><![CDATA[Resource]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/2007/10/04/excellent-resource-for-learning-mootools/</guid>
		<description><![CDATA[This has been out there for quite a while now, but I thought it should be included in the bestiary out of completeness. http://clientside.cnet.com]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>This has been out there for quite a while now, but I thought it should be included in the bestiary out of completeness.</p>
<p><a href="http://clientside.cnet.com">http://clientside.cnet.com</a></p>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2007/10/04/excellent-resource-for-learning-mootools/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>JSONP Robust, CrossDomain JSON</title>
		<link>http://www.ajaxbestiary.com/2007/09/11/jsonp-robust-crossdomain-json/</link>
		<comments>http://www.ajaxbestiary.com/2007/09/11/jsonp-robust-crossdomain-json/#comments</comments>
		<pubDate>Tue, 11 Sep 2007 16:41:46 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[JSON]]></category>

		<guid isPermaLink="false">http://www.ajaxbestiary.com/2007/09/11/jsonp-robust-crossdomain-json/</guid>
		<description><![CDATA[Basically, here&#8217;s the idea.&#160; Instead of relying solely on the remote host to provide you with your JSON files, JSONP is a standardized way for requesting formating for the JSON data that allows the client to inject code at the beginning of files produced by the server.&#160; It&#8217;s not a perfect solution but it does [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>Basically, here&#8217;s the idea.&nbsp; Instead of relying solely on the remote host to provide you with your JSON files, JSONP is a standardized way for requesting formating for the JSON data that allows the client to inject code at the beginning of files produced by the server.&nbsp; It&#8217;s not a perfect solution but it does help circumvent some of hobbles placed on Javascript based mashups by security sandboxes.</p>
<p><a href="http://bob.pythonmac.org/archives/2005/12/05/remote-json-jsonp/">Remote JSON &#8211; JSONP</a></p>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2007/09/11/jsonp-robust-crossdomain-json/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What To Expect From An AJAX toolkit</title>
		<link>http://www.ajaxbestiary.com/2007/08/22/what-to-expect-from-an-ajax-toolkit/</link>
		<comments>http://www.ajaxbestiary.com/2007/08/22/what-to-expect-from-an-ajax-toolkit/#comments</comments>
		<pubDate>Wed, 22 Aug 2007 13:52:13 +0000</pubDate>
		<dc:creator>Don Albrecht</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Toolkit Profile]]></category>

		<guid isPermaLink="false">http://www.dademsolutions.com/ajaxbeast/?p=18</guid>
		<description><![CDATA[There&#8217;s a myriad of AJAX frameworks out there to streamline the development of interactive sites. While methods of implementation vary and the functionality toolkits offer can vary dramatically. All toolkits fundamentally provide you with certain key features. Basic Features Simplified AJAX calls. All frameworks streamline the way in which you process POST and GET requests [...]]]></description>
			<content:encoded><![CDATA[
<!-- google_ad_section_start -->
<p>There&#8217;s a myriad of AJAX frameworks out there to streamline the development of interactive sites.  While methods of implementation vary and the functionality toolkits offer can vary dramatically.  All toolkits fundamentally provide you with certain key features.<br />
Basic Features</p>
<ul>
<li><span style="font-weight: bold">Simplified AJAX calls</span>.  All frameworks streamline the way in which you process POST and GET requests by abstracting away the cross browser descrepancies.</li>
<li><span style="font-weight: bold">Improved DOM Access.</span>  All frameworks improve interactions with the DOM through performance benefits and improved API calls.</li>
<li><span style="font-weight: bold">Object Orientation / Elements</span>.  All frameworks provide a level of object oriented abstraction to simplify and structure coding as well as some level of abstraction for DOM nodes.</li>
<li><span style="font-weight: bold">JSON Support. </span> Most if not all frameworks provide strong support for the JSON data interchange standard.</li>
</ul>
<p><big style="font-weight: bold">Advanced Features<br />
</big>There are also some advanced features common to most if not all frameworks.<big style="font-weight: bold"><br />
</big></p>
<ul>
<li><span style="font-weight: bold">Drag &amp; Drop. </span> Most frameworks provide tools for manipulating elements via drag &amp; drop.</li>
<li><span style="font-weight: bold">Animation. </span> Many frameworks provide animation tools to enhance the interface.  These can vary dramatically between toolkits in performance &amp; available effects, however.</li>
<li><span style="font-weight: bold">Event Handling.</span>  Since the default javascript event model can be slow and buggy at times.  Most frameworks abstract away the default event system with a new slots &amp; sockets approach.</li>
</ul>
<p><img src="http://www.ajaxbestiary.com/?voyeur=1"></p>
<!-- google_ad_section_end -->
]]></content:encoded>
			<wfw:commentRss>http://www.ajaxbestiary.com/2007/08/22/what-to-expect-from-an-ajax-toolkit/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

