<?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>User First Web &#187; Javascript</title>
	<atom:link href="http://userfirstweb.com/category/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://userfirstweb.com</link>
	<description>A blog about putting people before technology</description>
	<lastBuildDate>Thu, 29 Sep 2011 05:39:15 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.3</generator>
		<item>
		<title>Smart Optimizer</title>
		<link>http://userfirstweb.com/275/smart-optimizer/</link>
		<comments>http://userfirstweb.com/275/smart-optimizer/#comments</comments>
		<pubDate>Fri, 06 Jun 2008 14:04:11 +0000</pubDate>
		<dc:creator>Jason Grigsby</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[optimizer]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[speedupyoursite]]></category>

		<guid isPermaLink="false">http://userfirstweb.com/?p=275</guid>
		<description><![CDATA[One of the bigger problems I see in the performance space is that a lot of the value of current content management systems and blogging tools is the ability to add widgets or plugins from a lot of different places. These plugins often do not provide compressed and cacheable versions of their content. In order [...]]]></description>
			<content:encoded><![CDATA[<p>One of the bigger problems I see in the performance space is that a lot of the value of current content management systems and blogging tools is the ability to add widgets or plugins from a lot of different places. These plugins often do not provide compressed and cacheable versions of their content.</p>
<p>In order to get more people to adopt the methods of creating faster web pages, we need to make it easier for them to do so while still a making it easy for them to adhere to performance guidelines. Basically, make it possible for them to eat cat and lose weight at the same time.</p>
<p>I&#8217;ve spent part of last evening looking for plugins for WordPress that will find any javascript or css files, combine them into a single file, minify and gzip them, and then set far future expires headers. I&#8217;ve got a dream plugin in mind and none of them are quite living up to my fantasy.</p>
<p>One solution that comes close to being my dream is a piece of software called <a href="http://farhadi.ir/works/smartoptimizer">Smart Optimizer</a>. Smart Optimizer used to be called JSmart. It was a project that hadn&#8217;t had any updates since July 7, 2006 until two weeks ago when the project was revitalized and the name changed.</p>
<p>Smart Optimizer will:</p>
<ul>
<li>Set up rewrite rules to intercept any calls to css or js files</li>
<li>Minify, gzip any css or js files</li>
<li>Creates static files on the server for css and js that are gzipped and set for caching</li>
<li>Concatenate css or js files into a single file</li>
</ul>
<p>It&#8217;s an interesting tool that I don&#8217;t think a lot of people know of. Take a look.</p>
]]></content:encoded>
			<wfw:commentRss>http://userfirstweb.com/275/smart-optimizer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Speed Up Your AJAX With Google AJAX Libraries</title>
		<link>http://userfirstweb.com/273/speed-up-your-ajax-with-google-ajax-libraries/</link>
		<comments>http://userfirstweb.com/273/speed-up-your-ajax-with-google-ajax-libraries/#comments</comments>
		<pubDate>Wed, 04 Jun 2008 04:55:35 +0000</pubDate>
		<dc:creator>Jason Grigsby</dc:creator>
				<category><![CDATA[AJAX]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[libraries]]></category>

		<guid isPermaLink="false">http://userfirstweb.com/?p=273</guid>
		<description><![CDATA[Dion Almaer of Google and Ajaxian.com announced late last week the AJAX Libraries API. If you use AJAX, you&#8217;ll want to pay attention to this announcement. What does it mean? Popular AJAX libraries including: jQuery prototype script.aculo.us MooTools dojo are now being hosted on Google&#8217;s servers for use on your site or applications. Why would [...]]]></description>
			<content:encoded><![CDATA[<p>Dion Almaer of Google and <a href="http://ajaxian.com/archives/announcing-ajax-libraries-api-speed-up-your-ajax-apps-with-googles-infrastructure">Ajaxian.com announced</a> late last week the <a href="http://googleajaxsearchapi.blogspot.com/2008/05/speed-up-access-to-your-favorite.html">AJAX Libraries API</a>. If you use AJAX, you&#8217;ll want to pay attention to this announcement. What does it mean?</p>
<p>Popular AJAX libraries including:</p>
<ul>
<li>jQuery</li>
<li>prototype</li>
<li>script.aculo.us</li>
<li>MooTools</li>
<li>dojo</li>
</ul>
<p>are now being <strong>hosted on Google&#8217;s servers for use on your site or applications</strong>. Why would you link to a file hosted on Google&#8217;s server? Because it is optimized for speed by providing the libraries in the following way:</p>
<ul>
<li>Gzipped</li>
<li>Minified</li>
<li>Far future expires headers to increase caching</li>
<li>Delivered using Google&#8217;s extensive content delivery network</li>
</ul>
<p>They are providing multiple versions of each library and even include a javascript loader for the libraries. For more on the benefits of this service, check out <a href="http://www.stevesouders.com/blog/2008/05/27/google-ajax-libraries-api/">Steve Souder&#8217;s coverage</a> and Dion&#8217;s <a href="http://www.stevesouders.com/blog/2008/05/27/google-ajax-libraries-api/">extensive information on Ajaxian</a>.</p>
<p>If you are using any of these AJAX libraries, you would be foolish not to seriously consider taking advantage of this service.</p>
]]></content:encoded>
			<wfw:commentRss>http://userfirstweb.com/273/speed-up-your-ajax-with-google-ajax-libraries/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New, Faster Version of jQuery Released</title>
		<link>http://userfirstweb.com/272/new-faster-version-of-jquery-released/</link>
		<comments>http://userfirstweb.com/272/new-faster-version-of-jquery-released/#comments</comments>
		<pubDate>Wed, 04 Jun 2008 04:28:45 +0000</pubDate>
		<dc:creator>Jason Grigsby</dc:creator>
				<category><![CDATA[AJAX]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[ajaxian]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[optimization]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[speedupyoursite]]></category>

		<guid isPermaLink="false">http://userfirstweb.com/?p=272</guid>
		<description><![CDATA[&#8220;A new release of jQuery is out — 1.2.6, skipping directly from 1.2.3. Most noteworthy are the performance improvements.&#8221; via Ajaxian. Further details in the release notes.]]></description>
			<content:encoded><![CDATA[<p>&#8220;A new release of jQuery is out — 1.2.6, skipping directly from 1.2.3. Most noteworthy are the <a href="http://ajaxian.com/archives/jquery-release-126-performance-improvements-and-dimensions-plugin-added-to-core">performance improvements</a>.&#8221; via Ajaxian. Further details in the <a href="http://docs.jquery.com/Release:jQuery_1.2.6">release notes</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://userfirstweb.com/272/new-faster-version-of-jquery-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Logouts &amp; Form-based HTTP Basic Authentication</title>
		<link>http://userfirstweb.com/23/logouts-form-based-http-basic-authentication/</link>
		<comments>http://userfirstweb.com/23/logouts-form-based-http-basic-authentication/#comments</comments>
		<pubDate>Sun, 19 Aug 2007 22:44:24 +0000</pubDate>
		<dc:creator>Jason Grigsby</dc:creator>
				<category><![CDATA[AJAX]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Zope]]></category>

		<guid isPermaLink="false">http://userfirstweb.com/23/logouts-form-based-http-basic-authentication/</guid>
		<description><![CDATA[There are many advantages to HTTP Basic Authentication, but despite these advantages, web developers have turned almost exclusively to using cookie-based authentication because of some limitations in how HTTP Basic Authentication can be implemented. Until recently, there has been no way to for developers to control the login form nor provide a way for users [...]]]></description>
			<content:encoded><![CDATA[<p>There are many advantages to HTTP Basic Authentication, but despite these advantages, web developers have turned almost exclusively to using cookie-based authentication because of some limitations in how HTTP Basic Authentication can be implemented. Until recently, there has been no way to for developers to control the login form nor provide a way for users to log out.</p>
<p>The advantages of using HTTP Basic Authentication are easier integration. In particular, mod_auth_mysql for Apache makes it possible to easily password-protect areas based on usernames, passwords and roles stored in a central authentication database. The main alternative for authentication, cookie-based authentication, provides a higher barrier for integration projects.</p>
<p>Despite the integration advantages, most web developers use cookie-based authentication because they want to control the user experience of logging in. When logging in using HTTP Basic Authentication, the browser shows a login prompt. Developers have no control over the look of this login prompt; therefore, there is no ability to add useful information like links to retrieve forgotten passwords.<br />
<span id="more-23"></span><br />
After several unsuccessful login attempts, HTTP Basic Authentication redirects to a 401 error page. Only at this point can developers provide further instructions to assist the user. And with some browsers (ahem.. Safari), the 401 page will not be rendered if the user cancels their login attempt.</p>
<p>Once someone logs in, there is no way to log them out short of quitting the browser. <a href="http://httpd.apache.org/docs/1.3/howto/auth.html">Apache&#8217;s FAQs</a> provide the best explanation of the limitation:</p>
<blockquote>
<h3>      How do I log out?</h3>
<p>Since browsers first started implementing basic     authentication, website administrators have wanted to know how     to let the user log out. Since the browser caches the username     and password with the authentication realm, as described     earlier in this tutorial, this is not a function of the server     configuration, but is a question of getting the browser to     forget the credential information, so that the next time the     resource is requested, the username and password must be     supplied again. There are numerous situations in which this is     desirable, such as when using a browser in a public location,     and not wishing to leave the browser logged in, so that the     next person can get into your bank account.</p>
<p>However, although this is perhaps the most frequently asked     question about basic authentication, thus far none of the major     browser manufacturers have seen this as being a desirable     feature to put into their products.</p>
<p>Consequently, the answer to this question is, you can&#8217;t.     Sorry.</p></blockquote>
<p>Because my company uses HTTP Basic Authentication, I&#8217;ve become very good at explaining why we can&#8217;t have a form in the web page for logging in and why we can&#8217;t provide a log out button.</p>
<p>A couple of years ago, John Keith (our CTO) and I theorized that if we could log the user into the same realm using credentials that were only valid for a single page that we could mimic log out behavior. We explored trying to set the credentials on the server, but found that this only worked in Apache 2.0.</p>
<p>Basically we hit a brick wall until a couple of months ago. Thankfully, the increased emphasis on web services has caused a resurgence in HTTP Auth interest. If you have a password-protected API, you can&#8217;t assume that the client will accept cookies. In fact, it is unlikely that the client will accept cookies so you have to find an authentication alternative.</p>
<p>We&#8217;ve been experimenting with a new technique that allows for both form-based HTTP Basic Auth login boxes as well as log out buttons. It works using AJAX to take the usernames and passwords from the form and pass log the user in via the XmlHttpRequest object.</p>
<p>A similar technique logs a user out by logging the user into a page with credentials that are only valid for that page. The user never truly logs out, but the effect is the same. Until the user supplies their original credentials, they will be unable to see anything other than the one page.</p>
<p>I&#8217;m pleased to say that we&#8217;re having some success with these techniques and are using them to solve a long-standing customer issue. Details on the technique we&#8217;ve been basing our development on were <a href="http://www.peej.co.uk/articles/http-auth-with-html-forms.html">originally published by Paul James</a>. I highly recommend taking a look at some of Paul&#8217;s other articles on RESTful implementations and HTTP caching.</p>
<p>If you&#8217;re using HTTP Basic Authentication, you should look into these techniques immediately. Your users will thank you for it.</p>
<h3></h3>
]]></content:encoded>
			<wfw:commentRss>http://userfirstweb.com/23/logouts-form-based-http-basic-authentication/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>WYSIWYG Editor for Safari</title>
		<link>http://userfirstweb.com/20/wysiwyg-editor-for-safari/</link>
		<comments>http://userfirstweb.com/20/wysiwyg-editor-for-safari/#comments</comments>
		<pubDate>Fri, 17 Aug 2007 21:23:43 +0000</pubDate>
		<dc:creator>Jason Grigsby</dc:creator>
				<category><![CDATA[AJAX]]></category>
		<category><![CDATA[Emerging Technology]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://userfirstweb.com/20/wysiwyg-editor-for-safari/</guid>
		<description><![CDATA[A few years back I helped build a content management system. At the time, Internet Explorer on PC was the only browser we could use for WYSIWYG editing. As a Mac user, I struggled with the fact that I was delivering a product that I could never use on a regular basis. At the time, [...]]]></description>
			<content:encoded><![CDATA[<p>A few years back I helped build a content management system. At the time, Internet Explorer on PC was the only browser we could use for WYSIWYG editing. As a Mac user, I struggled with the fact that I was delivering a product that I could never use on a regular basis.</p>
<p>At the time, the great promise was sections of the DOM II specification on range. Bugzilla listed support for this part of the specification on its future work. I signed up for a list and monitored the ticket waiting for the day when Mozilla would support WYSIWYG in-browser editing.</p>
<p>Today I read that the Yahoo UI team has <a href="http://yuiblog.com/blog/2007/08/13/rte-notes/">finally bent Safari to its will to support WYSIWYG editing</a>. We&#8217;ve come a long ways since I was hanging out on the Mozilla developer lists and asking questions about the range implementation. Now that someone has conquered Safari, we are close to assuming that this foundation piece of the read/write web is available to all users.</p>
]]></content:encoded>
			<wfw:commentRss>http://userfirstweb.com/20/wysiwyg-editor-for-safari/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>YUI Compressor, Web Site Speed</title>
		<link>http://userfirstweb.com/10/yui-compressor-web-site-speed/</link>
		<comments>http://userfirstweb.com/10/yui-compressor-web-site-speed/#comments</comments>
		<pubDate>Tue, 14 Aug 2007 16:14:14 +0000</pubDate>
		<dc:creator>Jason Grigsby</dc:creator>
				<category><![CDATA[AJAX]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://userfirstweb.com/10/yui-compressor-web-site-speed/</guid>
		<description><![CDATA[Via Ajaxian I learned the Yahoo has released a new javascript compressor that reduces file sizes 18%. Compression of web site code is something that too many web site developers ignore. A few years ago, our CTO and I read Andrew King&#8217;s Speed Up Your Site book and became consumed with improving performance of our [...]]]></description>
			<content:encoded><![CDATA[<p>Via <a href="http://ajaxian.com/archives/yui-compressor-the-latest-minification-tool">Ajaxian</a> I learned the Yahoo has released a new <a href="http://www.julienlecomte.net/blog/2007/08/13/introducing-the-yui-compressor/">javascript compressor</a> that reduces file sizes 18%. Compression of web site code is something that too many web site developers ignore.</p>
<p>A few years ago, our CTO and I read Andrew King&#8217;s <a href="http://www.speedupyoursite.com">Speed Up Your Site</a> book and became consumed with improving performance of our customer web sites. We decreased download time for one site by 75%. These changes prevented us from hitting our network capacity long enough to move to a new hosting facility where we weren&#8217;t constrained by bandwidth.</p>
<p>What amazes me is how frequently developers ignore the simple things that can be done to speed up their web applications. Most web servers contain options to supply their content in gzipped form. This option alone can save tremendous time for users and bandwidth costs for companies.</p>
<p>I have a short list of books that I wish everyone who develops online would take the time to read. Speed Up Your Site is near the top of that list.</p>
<p>P.S. I was pleased to find that my new hosting environment appears to be using gzip by default. The home page would be 19K uncompressed, but is delivered to the browser as a 4K gzipped file.</p>
]]></content:encoded>
			<wfw:commentRss>http://userfirstweb.com/10/yui-compressor-web-site-speed/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->
