<?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>A Noted Path by Theodore Nguyen-Cao &#187; web</title>
	<atom:link href="http://www.theodorenguyen-cao.com/tag/web/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.theodorenguyen-cao.com</link>
	<description>Personal blog of Theodore Nguyen-Cao</description>
	<lastBuildDate>Wed, 21 Jul 2010 15:40:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=abc</generator>
		<item>
		<title>Checkboxes in Stripes and Spring MVC</title>
		<link>http://www.theodorenguyen-cao.com/2009/03/29/checkboxes-in-stripes-and-spring-mvc/</link>
		<comments>http://www.theodorenguyen-cao.com/2009/03/29/checkboxes-in-stripes-and-spring-mvc/#comments</comments>
		<pubDate>Sun, 29 Mar 2009 06:42:01 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[geekery]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[tutorials]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[spring]]></category>
		<category><![CDATA[stripes]]></category>

		<guid isPermaLink="false">http://www.theodorenguyen-cao.com/?p=270</guid>
		<description><![CDATA[When building dynamic web sites with lots of javascript UI components being created on the client, understanding how the web framework you&#8217;re using will process the request and what must be done to update fields accordingly is even more important. Specifically, checkboxes have always been a pain to deal with. The gotcha with checkboxes are [...]]]></description>
			<content:encoded><![CDATA[<p>When building dynamic web sites with lots of javascript UI components being created on the client, understanding how the web framework you&#8217;re using will process the request and what must be done to update fields accordingly is even more important.</p>
<p>Specifically, checkboxes have always been a pain to deal with.  The gotcha with checkboxes are if a checkbox isn&#8217;t checked, the request doesn&#8217;t send the parameter so it requires some additional checks to detect that the user deselected something that was there to update the field accordingly.  I&#8217;ve been playing around with the <a href="http://www.stripesframework.org">Stripes framework</a> and ran into this issue.  </p>
<p>With Stripes, you can render a checkbox using their JSP tag:</p>
<pre name="code" class="html">
&lt;stripes:checkbox checked="true" name="property1" value="yes"/&gt;
&lt;stripes:checkbox checked="true" name="property2" value="no"/&gt;
</pre>
<p>When the &#8220;checked&#8221; value is equal to &#8220;value&#8221; value, Stripes will render the checkbox as checked.  So with the code shown, two checkboxes will be shown with the first checked and the second unchecked. </p>
<p>If a user reverses this by unchecking the first, checking the second, and submit the form, the HTTP request will only see that <code>property2=no</code>.  Before the form was submitted, &#8220;property1&#8243; had a value of &#8220;yes&#8221;. Now, &#8220;property1&#8243; won&#8217;t even appear in the request parameters, so we have to do special handling to check for the absent of the parameter to update &#8220;property1&#8243; to whatever value it should be when it is not checked.</p>
<p>In Spring MVC with form binding, checkboxes are dealt with a little differently. Using Spring MVC&#8217;s <a href="http://static.springframework.org/spring/docs/2.0.x/reference/spring-form.tld.html">form JSP tag</a>, you can do:</p>
<pre name="code" class="html">
  &lt;form:checkbox path="property1" value="yes"/&gt;
  &lt;form:checkbox path="property2" value="no"/&gt;
</pre>
<p>Assuming your command bean is named &#8220;person&#8221;, this will generate the following HTML:</p>
<pre name="code" class="html">
        &lt;input name="person.property1" type="checkbox" value="yes"/&gt;
        &lt;input type="hidden" value="1" name="_person.property1"/&gt;
        &lt;input name="person.property2" type="checkbox" value="no"/&gt;
        &lt;input type="hidden" value="1" name="_person.property2"/&gt;
</pre>
<p>As noted by the <a href="http://static.springframework.org/spring/docs/2.5.5/reference/mvc.html">docs</a>, </p>
<blockquote><p>What you might not expect to see is the additional hidden field after each checkbox. When a checkbox in an HTML page is not checked, its value will not be sent to the server as part of the HTTP request parameters once the form is submitted, so we need a workaround for this quirk in HTML in order for Spring form data binding to work. The checkbox tag follows the existing Spring convention of including a hidden parameter prefixed by an underscore (&#8220;_&#8221;) for each checkbox. By doing this, you are effectively telling Spring that â€œthe checkbox was visible in the form and I want my object to which the form data will be bound to reflect the state of the checkbox no matter whatâ€.</p></blockquote>
<p>Spring MVC  also provides a <a href="http://static.springframework.org/spring/docs/2.0.x/reference/spring-form.tld.html#spring-form.tld.checkboxes">&#8220;checkboxes&#8221; tag</a> which allows you to render a list of checkbox boxes without having to wrap the &#8220;checkbox&#8221; tag around a JSTL forEach.</p>
<p>Hopefully, that gives you some insight into how to work with checkboxes in Stripes and Spring MVC.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2009/03/29/checkboxes-in-stripes-and-spring-mvc/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Run Firefox 2 and Firefox 3</title>
		<link>http://www.theodorenguyen-cao.com/2008/07/05/run-firefox-2-and-firefox-3/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/07/05/run-firefox-2-and-firefox-3/#comments</comments>
		<pubDate>Sat, 05 Jul 2008 20:59:38 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/07/05/run-firefox-2-and-firefox-3/</guid>
		<description><![CDATA[Gah, why would you want to run both? Well, Firebug is the suck in Firefox 3. I&#8217;ve been doing a lot of javascript/ajax development lately. When using Firefox 3 and the Firebug console, I get the following error occasionally: commandLine.evaluate FAILS: [Exception... "Security Manager vetoed action" nsresult: "0x80570027 (NS_ERROR_XPC_SECURITY_MANAGER_VETO)" location: "JS frame :: chrome://firebug/content/commandLine.js :: [...]]]></description>
			<content:encoded><![CDATA[<p>Gah, why would you want to run both? Well, Firebug is the suck in Firefox 3. I&#8217;ve been doing a lot of javascript/ajax development lately.</p>
<p>When using Firefox 3 and the Firebug console, I get the following error occasionally:</p>
<pre class="console">
commandLine.evaluate FAILS: [Exception... "Security Manager vetoed action" nsresult: "0x80570027 (NS_ERROR_XPC_SECURITY_MANAGER_VETO)" location: "JS frame :: chrome://firebug/content/commandLine.js :: <top_level> :: line 100" data: no]
</pre>
<p>Lifehacker had a nice <a href="http://lifehacker.com/396607/multifirefox-runs-firefox-2-and-3-side-by-side" target="_blank">post</a> on how to run Firefox 2 and 3.</p>
<p>For most cases Firefox 3 is just fine.  But for the serious javascript coder, Firebug just isn&#8217;t ready for prime time in Firefox 3.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/07/05/run-firefox-2-and-firefox-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Be part of history &#8211; Download Firefox 3</title>
		<link>http://www.theodorenguyen-cao.com/2008/06/17/be-part-of-history-download-firefox-3/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/06/17/be-part-of-history-download-firefox-3/#comments</comments>
		<pubDate>Tue, 17 Jun 2008 19:33:18 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[geekery]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/06/17/be-part-of-history-download-firefox-3/</guid>
		<description><![CDATA[Make history.  It&#8217;s out. Update: Aw, yea!]]></description>
			<content:encoded><![CDATA[<p>Make <a href="http://spreadfirefox.com/en-US/worldrecord/" target="_blank">history</a>.  It&#8217;s <a href="http://www.mozilla.com/en-US/" target="_blank">out</a>.</p>
<p>Update:</p>
<p>Aw, yea!<br />
<center><br />
<a href="http://www.spreadfirefox.com/en-US/worldrecord/certificate_form"><img src="http://blog.notedpath.com/wp-content/uploads/2008/06/picture-3.png" alt="firefox_download_cert" /></a><br />
</center></p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/06/17/be-part-of-history-download-firefox-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>KML &#8211; the new mapping standard</title>
		<link>http://www.theodorenguyen-cao.com/2008/04/14/kml-the-new-mapping-standard/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/04/14/kml-the-new-mapping-standard/#comments</comments>
		<pubDate>Tue, 15 Apr 2008 03:12:53 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[geekery]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/04/14/kml-the-new-map-standard/</guid>
		<description><![CDATA[The Open Geospatial Consortium just announced that KML has been adopted as an open standard. KML stands for Keyhole Markup Language, originally designed by Keyhole who was acquired by Google back in 2004. Keyhole&#8217;s Earth Viewer product was reborn as what we know today as Google Earth. I first came across KML when I was [...]]]></description>
			<content:encoded><![CDATA[<p>The Open Geospatial Consortium just <a href="http://www.opengeospatial.org/pressroom/pressreleases/857" target="_blank">announced</a> that KML has been adopted as an open standard. KML stands for Keyhole Markup Language, originally designed by Keyhole who was acquired by Google back in 2004.  Keyhole&#8217;s Earth Viewer product was reborn as what we know today as Google Earth.  I first came across KML when I was working on some data visualization using Google Earth.  I found it to be very expressive and easy to use. You can do neat things like stream dynamic KML to animate the map or add overlays on the map.</p>
<p>It&#8217;s interesting to see how Google Earth/Maps&#8217;s popularity has allowed KML to become the international standard.  It will be even more interesting to see how quickly the standard is adopted by many of the geo-visualization products out there.  While I don&#8217;t think it will be &#8220;<a href="http://googleblog.blogspot.com/2008/04/kml-html-of-geographic-content.html" target="_blank">the HTML of geographic content</a>&#8220;, I do think this standardization will open up the market for new products that build/support KML, pushing KML to its limits as we have done with HTML.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/04/14/kml-the-new-mapping-standard/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>DSL for UML Diagrams?</title>
		<link>http://www.theodorenguyen-cao.com/2008/03/19/dsl-for-uml-diagrams/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/03/19/dsl-for-uml-diagrams/#comments</comments>
		<pubDate>Thu, 20 Mar 2008 03:47:26 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[geekery]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/03/19/dsl-for-uml-diagrams/</guid>
		<description><![CDATA[Domain-specific languages are becoming more and more popular. I across websequencediagram.com which really illustrates the power of building DSLs to tackle very specific problems. I don&#8217;t spend my time creating many UML sequence diagrams now a days but if I ever have to, I&#8217;ll be remembering this web app.]]></description>
			<content:encoded><![CDATA[<p><a href="http://en.wikipedia.org/wiki/Domain-specific_programming_language" target="_blank">Domain-specific languages</a> are becoming more and more popular.  I across <a href="http://www.websequencediagrams.com/" target="_blank">websequencediagram.com</a> which really illustrates the power of building DSLs to tackle very specific problems.  I don&#8217;t spend my time creating many UML sequence diagrams now a days but if I ever have to, I&#8217;ll be remembering this web app.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/03/19/dsl-for-uml-diagrams/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Javascript Password Revealer using Prototype</title>
		<link>http://www.theodorenguyen-cao.com/2008/02/12/javascript-password-revealer-using-prototype/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/02/12/javascript-password-revealer-using-prototype/#comments</comments>
		<pubDate>Wed, 13 Feb 2008 04:03:43 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/02/12/javascript-password-revealer-using-prototype/</guid>
		<description><![CDATA[Inspired by the latest Coding Horror post, here&#8217;s an code snippet that allows you to implement a password revealer using the Prototype JavaScript library. function togglePassword(elem){ var e=$(elem); e.type=='password' ? e.type='input' : e.type='password'; } Check it out in action below. &#38;amp;amp;lt;br /&#38;amp;amp;gt; Check it out in action &#38;amp;amp;lt;a href=&#8221;http://static.notedpath.com/password_revealer.html&#8221;&#38;amp;amp;gt;here&#38;amp;amp;lt;/a&#38;amp;amp;gt;.&#38;amp;amp;lt;br /&#38;amp;amp;gt; I wouldn&#8217;t mind seeing more [...]]]></description>
			<content:encoded><![CDATA[<p>Inspired by the latest Coding Horror <a href="http://www.codinghorror.com/blog/archives/001056.html" target="_blank">post</a>, here&#8217;s an code snippet that allows you to implement a password revealer using the <a href="http://www.prototypejs.org/" target="_blank">Prototype</a> JavaScript library.</p>
<pre name="code" class="javascript">
<script type="text/javascript">

function togglePassword(elem){

        var e=$(elem);

        e.type=='password' ? e.type='input' : e.type='password';

}
</script></pre>
<p>Check it out in action <a href="http://static.notedpath.com/password_revealer.html">below</a>.</p>
<p><center><iframe src="http://static.notedpath.com/password_revealer.html" border="0" frameborder="0" height="115" width="500" style="overflow:auto;">&amp;amp;amp;lt;br /&amp;amp;amp;gt; Check it out in action &amp;amp;amp;lt;a href=&#8221;http://static.notedpath.com/password_revealer.html&#8221;&amp;amp;amp;gt;here&amp;amp;amp;lt;/a&amp;amp;amp;gt;.&amp;amp;amp;lt;br /&amp;amp;amp;gt; </iframe><br />
</center><br />
I wouldn&#8217;t mind seeing more web forms adding this feature for password fields.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/02/12/javascript-password-revealer-using-prototype/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Using JMeter for load testing</title>
		<link>http://www.theodorenguyen-cao.com/2008/02/10/using-jmeter-for-load-testing/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/02/10/using-jmeter-for-load-testing/#comments</comments>
		<pubDate>Sun, 10 Feb 2008 19:00:37 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/02/10/using-jmeter-for-load-testing/</guid>
		<description><![CDATA[I came across JMeter a while back but never got a chance to try it out. From the JMeter website: Apache JMeter is a 100% pure Java desktop application designed to load test functional behavior and measure performance. It was originally designed for testing Web Applications but has since expanded to other test functions. This [...]]]></description>
			<content:encoded><![CDATA[<p>I came across <a href="http://jakarta.apache.org/jmeter/" target="_blank">JMeter</a> a while back but never got a chance to try it out. From the JMeter website:</p>
<blockquote><p><em>  Apache JMeter  is a 100% pure Java desktop application designed to load test functional behavior and measure performance. It was originally designed for testing Web Applications but has since expanded to other test functions.</em></p></blockquote>
<p>This weekend I was able to test load on my <a href="https://manage.slicehost.com/customers/new?referrer=90780688" target="_blank">256 slice</a> which this blog is running on.  Here&#8217;s what I did:</p>
<ol>
<li><strong>Download the binary</strong><br />
You can get the binary <a href="http://jakarta.apache.org/site/downloads/downloads_jmeter.cgi" target="_blank">here</a>.</li>
<li> <strong>Unzip the tarball/zip file</strong><br />
I extracted it file to <code>/Users/theo/tools/jakarta-jmeter-2.3.1</code></li>
<li><strong>Start up JMeter</strong><br />
Go to the <code>bin</code> directory.  Run <code>jmeter.sh</code> (<code>jmeter.bat</code> if using Windows) from the command line.</li>
<li> <strong>Create a Test Plan</strong><br />
Just give a name and any description you want for your test plan.<a href="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_create_test_plan.png"><img src="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_create_test_plan.png" alt="jmeter_create_test_plan" height="273" width="449" /></a></li>
<li> <strong>Create a Thread Group</strong><br />
A thread group allows you to specify the amount of load you want to simulate.  Select your test plan from the left Tree view, right-click, and select Add -&gt; Thread Group.</p>
<p>Configurable fields include:</p>
<ul>
<li>Number of threads &#8211; the number of connections or users you want to simulate</li>
<li>Ramp up period &#8211; the amount of time in seconds to take to reach the number of threads specified.  If you  choose 0, all of the threads will be created at the start of the test.</li>
<li>Loop count &#8211; you can specify to loop indefinitely or provide a number of times to run through the test.</li>
</ul>
<p><a href="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_create_thread_group.png"><img src="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_create_thread_group.png" alt="jmeter_create_thread_group" height="273" width="449" /></a></li>
<li><strong>Add a Sampler</strong><br />
A sampler is a type of request you want to make.  In this example, I used an HTTP request to test load to a web server.  It&#8217;s good to note JMeter supports multiple types of samplers including web services, JMS, and JDBC.  Add a sampler by selecting the Thread Group you just created, right-click, select Add -&gt; Sampler -&gt; HTTP Request.</p>
<p>Configurable properties include:</p>
<ul>
<li>Server Name &#8211; what the ip or url is to the server the request it to</li>
<li>Port &#8211; the port the  server is listening to</li>
<li>Protocol &#8211; the protocol (http, https, etc)</li>
<li>Method &#8211; HTTP method (POST,GET, PUT, DELETE, etc)</li>
<li>Path &#8211; the URL path to request</li>
</ul>
<p><a href="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_create_http_request.png"><img src="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_create_http_request.png" alt="jmeter_create_http_request" height="271" width="450" /></a></li>
<li><strong>Add a Listener<br />
</strong>A listener allows you to collect data points and display them in some fashion like a graph or a table.  I used the Graph Results listener by selecting the Thread Group, right-click, select Add -&gt; Listener -&gt; Graph Results.</li>
<li><strong>Run the test!</strong><br />
Now we are ready to run the test. From the file menu bar, select Run -&gt;Start.  You will be prompted to save your test plan.  You can save it or just hit &#8220;No&#8221;.  You should see data points begin to be plotted on the Graph Result or whatever listener you selected.</p>
<p><a href="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_graph_results.png"><img src="http://blog.notedpath.com/wp-content/uploads/2008/02/jmeter_graph_results.png" alt="jmeter_graph_results" height="249" width="450" /></a><br />
I monitored the usage from my slice as well and this is what top showed me:</p>
<p><a href="http://blog.notedpath.com/wp-content/uploads/2008/02/slice_top_load_test.png" title="slice_top_load_test"><img src="http://blog.notedpath.com/wp-content/uploads/2008/02/slice_top_load_test.png" alt="slice_top_load_test" height="276" width="450" /></a></p>
<p>You can see the 5 threads we specified in the Thread Group taking up 5 apache processes.</li>
<li><strong>Interpret the results</strong><br />
Tests are worthless without interpreting the results.  So, what the heck does this graph tell me?  Pretty good documentation can be found <a href="http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Graph_Results" target="_blank">here</a>. Basically, given the load scenario we have setup, my slice can handle ~643 requests/minute or ~11 requests/second.  I am not sure what kind of numbers I should be getting but these seem pretty good to me. One last thing to note is that JMeter is not a web browser so these metrics don&#8217;t include rendering time or execution of any JavaScript.</li>
</ol>
<p>Overall, JMeter seems to be a great open source tool to test different kinds of load on servers.  I look forward to trying it out at work.  One last thing I came across is JMeter integration with your Ant build process.  Check that out <a href="http://www.programmerplanet.org/pages/projects/jmeter-ant-task.php" target="_blank">here</a>. I would like to hear about other people&#8217;s experiences with JMeter, too.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/02/10/using-jmeter-for-load-testing/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Importing new Blogger to WordPress</title>
		<link>http://www.theodorenguyen-cao.com/2008/01/27/importing-new-blogger-to-wordpress/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/01/27/importing-new-blogger-to-wordpress/#comments</comments>
		<pubDate>Sun, 27 Jan 2008 06:36:20 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/01/27/importing-new-blogger-to-wordpress/</guid>
		<description><![CDATA[Thanks to the WordPress plugin found here, I&#8217;ve been able to import my old blogger posts to WordPress. So far, it&#8217;s looking good!]]></description>
			<content:encoded><![CDATA[<p>Thanks to the WordPress plugin found <a href="http://www.romantika.name/v2/2007/01/31/import-new-blogger-to-wordpress/">here</a>, I&#8217;ve been able to import my <a href="http://duyvu.blogspot.com">old blogger</a> posts to WordPress. So far, it&#8217;s looking good!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/01/27/importing-new-blogger-to-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dynamically targeted links</title>
		<link>http://www.theodorenguyen-cao.com/2008/01/17/dynamically-targeted-links/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/01/17/dynamically-targeted-links/#comments</comments>
		<pubDate>Thu, 17 Jan 2008 15:20:14 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/01/17/dynamically-targeted-links/</guid>
		<description><![CDATA[In the previous post, I quickly created a widgetized blog feed. However, the dynamically generated HTML included links that would open in the same window that the links was on. Under normal circumstances, this is the best user experience. However since Clearspring generates HTML-based feeds in an iframe, clicking on any of the links in [...]]]></description>
			<content:encoded><![CDATA[<p>In the <a href="http://blog.notedpath.com/2008/01/15/fun-with-widgets/">previous post</a>, I quickly created a widgetized blog feed.  However, the dynamically generated HTML included links that would open in the same window that the links was on.  Under normal circumstances, this is the best user experience. However since Clearspring generates HTML-based feeds in an iframe,  clicking on any of the links in the widget caused the page to be rendered in the small, confined space of 300&#215;236 pixels.</p>
<p>I know I could have used <code>document.getElementsByTagName('a')</code> but I was wondering if there was a nicer way to grab all the links on a page.  Googling around pointed me to this <a href="http://richardbowles.tripod.com/javascript/section9/lesson9.htm">post</a>.  I can get all the links on a page by using <code>document.links</code>, which returns an array of the links on a page as DOM objects.  I haven&#8217;t tested this on all browsers, but that&#8217;s pretty sweet.</p>
<p>Here&#8217;s the code in it&#8217;s entirety to make all links on a page open up in a new window:</p>
<pre name="code" class="javascript">
&lt;script type="text/javascript"&gt;
var links = document.links;
for( var i = 0 ; i &lt; links.length ; i++ ) {
   links[i].setAttribute('target','_blank');
}
&lt;/script&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/01/17/dynamically-targeted-links/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fun with widgets</title>
		<link>http://www.theodorenguyen-cao.com/2008/01/15/fun-with-widgets/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/01/15/fun-with-widgets/#comments</comments>
		<pubDate>Tue, 15 Jan 2008 06:01:11 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/01/15/fun-with-widgets/</guid>
		<description><![CDATA[I came across a Clearspring back a months ago when they were TechCrunch&#8217;d and more recently, I came across Wigetized.com, made by a fellow slichoster. I wanted to try out both and I thought it would be interesting to combine the powers of both services. I created my widgetized blog feed from wigitized.com, created a [...]]]></description>
			<content:encoded><![CDATA[<p>I came across a <a href="http://www.clearspring.com">Clearspring</a> back a months ago when they were TechCrunch&#8217;d and more recently, I came across <a href="http://wigitize.com/">Wigetized.com</a>, made by a fellow slichoster.</p>
<p>I wanted to try out both and I thought it would be interesting to combine the powers of both services.</p>
<p>I created my widgetized blog feed from wigitized.com, created a widget cname, updated my apache2 config, created a new directory, and pasted in the generated wigetized html into a new file. Oh, and I bounced apache2.</p>
<p>And TA-DA! <a href="http://widget.notedpath.com">A widgetized feed!</a></p>
<p>Next step was to create a new Clearspring Widget from this.  Clearspring has done a good job of making this ridiculously easy.  You have a couple of options of how to create widget (flash, HTML, js, image). I went with HTML since I had HTML was just to provide the URL to the HTML and a name for the widget.</p>
<p>Once I had the widget added to the Clearspring platform, all I really had to do was publish it and now I have a Clearspring tracked widget.<br />
<center> <script src="http://widgets.clearspring.com/o/478c43354e2e8352/478c4bae52a242b8/478c43354e2e8352/60c221d6/widget.js" type="text/javascript"></script> </center><br />
Next, I&#8217;ll be interested in see how I can leverage the platform in different ways to make this widget &#8220;viral&#8221; and what sort of analytics come with Clearspring to help me track its viralocity (did I make that word up?).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/01/15/fun-with-widgets/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Google Syntax Highlighter for WP</title>
		<link>http://www.theodorenguyen-cao.com/2008/01/12/google-syntax-highlighter-for-wp/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/01/12/google-syntax-highlighter-for-wp/#comments</comments>
		<pubDate>Sun, 13 Jan 2008 01:33:13 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/01/12/google-syntax-highlighter-for-wp/</guid>
		<description><![CDATA[I used to use WP-Syntax but I think this looks oh so nicer! public class Hello { public static void main(String[] args) { System.out.println("Hello World!"); } } Check it out at here.]]></description>
			<content:encoded><![CDATA[<p>I used to use <a href="http://blog.notedpath.com/2007/08/19/hello-world-java/">WP-Syntax</a> but I think this looks oh so nicer!</p>
<pre name="code" class="java">
public class Hello {
  public static void main(String[] args) {
    System.out.println("Hello World!");
  }
}</pre>
<p>Check it out at <a href="http://wordpress.org/extend/plugins/google-syntax-highlighter/">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/01/12/google-syntax-highlighter-for-wp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox 3.0 Beta, Web Developer, Firebug</title>
		<link>http://www.theodorenguyen-cao.com/2008/01/12/firefox-30-beta-web-developer-firebug/</link>
		<comments>http://www.theodorenguyen-cao.com/2008/01/12/firefox-30-beta-web-developer-firebug/#comments</comments>
		<pubDate>Sat, 12 Jan 2008 20:13:07 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2008/01/12/firefox-30-beta-web-developer-firebug/</guid>
		<description><![CDATA[I&#8217;ve recently moved to Firefox 3 on my MacBook Pro. The first thing I noticed was pretty much all of my Firefox plugins stopped working. This didn&#8217;t really bother me until I started developing on the laptop. The two things I really missed were Web Developer and FireBug. After a little bit of googling, I [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve recently moved to <a href="http://www.mozilla.com/en-US/firefox/all-beta.html">Firefox 3</a> on my MacBook Pro.  The first thing I noticed was pretty much all of my Firefox plugins stopped working.  This didn&#8217;t really bother me until I started developing on the laptop.  The two things I really missed were Web Developer and FireBug.</p>
<p>After a little bit of googling, I was able to find other people with the same problem and fixes.  While these are not official releases, they seem to be working just fine for me.</p>
<p>Check them out below:</p>
<ul>
<li><a href="http://files.mybannermaker.com/personal/WebDev_3.xpi">Web Developer for FireFox 3</a> &#8211; <a href="http://devhints.wordpress.com/2007/12/01/web-developer-on-firefox-3-incl-minefield/">DevHints</a></li>
<li><a href="http://fireclipse.xucia.com/files/fireclipse/firebug-1.1.0b10.xpi">FireBug for FireFox 3</a> &#8211; <a href="http://fireclipse.xucia.com/">Fireclipse</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2008/01/12/firefox-30-beta-web-developer-firebug/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Back in business!</title>
		<link>http://www.theodorenguyen-cao.com/2007/09/10/back-in-business/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/09/10/back-in-business/#comments</comments>
		<pubDate>Tue, 11 Sep 2007 01:21:41 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/09/10/back-in-business/</guid>
		<description><![CDATA[I rebuilt my slice from scratch after screwing up my installations of ruby and rubygems. Good thing I had the WP-DB-Backup or else I would have lost all of my posts!]]></description>
			<content:encoded><![CDATA[<p>I rebuilt my slice from scratch after screwing up my installations of ruby and rubygems.  Good thing I had the <a href="http://wordpress.org/extend/plugins/wp-db-backup/">WP-DB-Backup</a> or else I would have lost all of my posts!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/09/10/back-in-business/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache2.2 up and running finally!</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/27/apache22-up-and-running-finally/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/27/apache22-up-and-running-finally/#comments</comments>
		<pubDate>Tue, 28 Aug 2007 03:53:20 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/08/27/apache22-up-and-running-finally/</guid>
		<description><![CDATA[Yay! I got apache upgraded to 2.2 from 2.0. It was a lot easier after I was told by Aaron that Feisty has 2.2 in their apt-get repositories. I just had to update from Dapper to Feisty. Prior to updating I did have to comment out all of the repositories I had added to my [...]]]></description>
			<content:encoded><![CDATA[<p>Yay! I got apache upgraded to 2.2 from 2.0.  It was a lot easier after I was told by Aaron that Feisty has 2.2 in their apt-get repositories.  I just had to update from Dapper to Feisty.  Prior to updating I did have to comment out all of the repositories I had added to my <code>/etc/apt/sources.list</code>.  I was running into some broken wgets otherwise.</p>
<p>After commenting out the additional repository lines, I just followed the steps <a href="http://wiki.slicehost.com/doku.php?id=upgrade_ubuntu_dapper_-_edgy_-_feisty">here</a> and viola! apache2.2 comes up.</p>
<p>I did have to reinstall mod_jk for apache2.2 but that was a <a href="http://www.howtoforge.com/apache2_tomcat5_mod_jk_integration">easy</a>.</p>
<p>And the day is mine.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/27/apache22-up-and-running-finally/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>apache2/mod_proxy_balancer woes (part 2)</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/26/apache2mod_proxy_balancer-woes-part-2/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/26/apache2mod_proxy_balancer-woes-part-2/#comments</comments>
		<pubDate>Mon, 27 Aug 2007 01:42:47 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/08/26/apache2mod_proxy_balancer-woes-part-2/</guid>
		<description><![CDATA[Well, I got to like the second step before I hit another roadblock. Looks like kodefoo&#8217;s repository only supports binary-i386 releases. Too bad my slice is on an AMD64 machine which means I need the amd64 release. I guess if I want to cluster mongrel with apache, I&#8217;ll have to compile from source. Sigh&#8230; Prior [...]]]></description>
			<content:encoded><![CDATA[<p>Well, I got to like the second step before I hit another roadblock.  Looks like kodefoo&#8217;s repository only supports binary-i386 releases.  Too bad my slice is on an AMD64 machine which means I need the amd64 release.  I guess if I want to cluster mongrel with apache, I&#8217;ll have to compile from source.  Sigh&#8230;</p>
<p>Prior to hitting this road block, I ran <code>apt-get remove apache2</code> and it didn&#8217;t remove apache2 from my slice even though it said it did. So that&#8217;s a little confusing. I continued with the kodefoo tutorial regardless until I came across the problem noted above.  I&#8217;ll eventually have to figure out how to do a clean remove of apache2.</p>
<p>At this point, I think I am just going to try to get a single mongrel served up through apache2.  Hopefully, this will be easier&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/26/apache2mod_proxy_balancer-woes-part-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>apache2/mod_proxy_balancer woes (part 1)</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/26/apache2-woes/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/26/apache2-woes/#comments</comments>
		<pubDate>Sun, 26 Aug 2007 19:01:35 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/08/26/apache2-woes/</guid>
		<description><![CDATA[So I&#8217;ve still been trying to get mod_proxy_balancer installed. I tried just getting a compiled mod_proxy_balancer.so and drop it into my existing apache2 install but upon start up I get: Cannot load /usr/lib/apache2/modules/mod_proxy_balancer.so into server: /usr/lib/apache2/modules/mod_proxy_balancer.so: undefined symbol: proxy_hook_post_request Looks like I have to do a clean uninstall and reinstall of apache2 from source. I&#8217;ll [...]]]></description>
			<content:encoded><![CDATA[<p>So I&#8217;ve still been trying to get mod_proxy_balancer installed.  I tried just getting a compiled mod_proxy_balancer.so and drop it into my existing apache2 install  but upon start up I get:</p>
<p><code>Cannot load /usr/lib/apache2/modules/mod_proxy_balancer.so into server: /usr/lib/apache2/modules/mod_proxy_balancer.so: undefined symbol: proxy_hook_post_request</code></p>
<p>Looks like I have to do a clean uninstall and reinstall of apache2 from source.  I&#8217;ll have to resetup svn (svn_dvn) and all my virtual hosts so this blog is going to be MIA while I go through this process.</p>
<p>I can&#8217;t wait until the Ubuntu repositories update apache2 to 2.2 so mod_proxy_balancer support will be as simple as <code>apt-get install apache2</code>.</p>
<p>I think the next step is to remove my existing apache2 install and give <a href="http://www.kodefoo.com/2007/2/18/deploying-rails-on-ubuntu-dapper/">kodefoo&#8217;s tutorial</a> a shot.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/26/apache2-woes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Pretty WordPress themes</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/19/pretty-wordpress-themes/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/19/pretty-wordpress-themes/#comments</comments>
		<pubDate>Mon, 20 Aug 2007 00:27:44 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/08/19/pretty-wordpress-themes/</guid>
		<description><![CDATA[After I installed WordPress, the first thing I did was go in search for a WordPress theme. I started off at LifeHacker. After a search for all things wordpressy, I came across a post for 83 Beautiful WordPress Themes You (Probably) Haven&#8217;t Seen. After scrolling down a bit, I found Peaceful Rush which is a [...]]]></description>
			<content:encoded><![CDATA[<p>After I installed WordPress, the first thing I did was go in search for a WordPress theme.  I started off at <a href="http://www.lifehacker.com">LifeHacker</a>.  After a search for all things wordpressy, I came across a post for <a href="http://www.smashingmagazine.com/2007/02/09/83-beautiful-wordpress-themes-you-probably-havent-seen/">83 Beautiful WordPress Themes You (Probably) Haven&#8217;t Seen</a>.  After scrolling down a bit, I found <a href="http://www.wpdesigner.com/2007/01/17/peaceful-rush-wordpress-theme/">Peaceful Rush</a> which is a great match with the title of this blog.  So far, I think it&#8217;s looking good <img src='http://www.theodorenguyen-cao.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/19/pretty-wordpress-themes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hello, World &#8211; Java</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/19/hello-world-java/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/19/hello-world-java/#comments</comments>
		<pubDate>Sun, 19 Aug 2007 18:13:38 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/08/19/hello-world-java/</guid>
		<description><![CDATA[Trying out the WP-Syntax WordPress plugin: public class Hello { public static void main(String[] args) { System.out.println("Hello World!"); } } Check it out at: http://wordpress.org/extend/plugins/wp-syntax/]]></description>
			<content:encoded><![CDATA[<p>Trying out the WP-Syntax WordPress plugin:</p>
<pre lang="java">
public class Hello {
  public static void main(String[] args) {
    System.out.println("Hello World!");
  }
}</pre>
<p>Check it out at: <a href="http://wordpress.org/extend/plugins/wp-syntax/">http://wordpress.org/extend/plugins/wp-syntax/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/19/hello-world-java/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Google Sitemap Generator</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/19/google-sitemap-generator/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/19/google-sitemap-generator/#comments</comments>
		<pubDate>Sun, 19 Aug 2007 17:12:57 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/2007/08/19/google-sitemap-generator/</guid>
		<description><![CDATA[Here&#8217;s a pretty cool WordPress plugin that lets Google know about your blog: http://www.arnebrachhold.de/2005/06/05/google-sitemaps-generator-v2-final]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a pretty cool WordPress plugin that lets Google know about your blog:<br />
<a href="http://www.arnebrachhold.de/2005/06/05/google-sitemaps-generator-v2-final" target="_blank">http://www.arnebrachhold.de/2005/06/05/google-sitemaps-generator-v2-final </a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/19/google-sitemap-generator/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fresh start!</title>
		<link>http://www.theodorenguyen-cao.com/2007/08/18/fresh-start/</link>
		<comments>http://www.theodorenguyen-cao.com/2007/08/18/fresh-start/#comments</comments>
		<pubDate>Sat, 18 Aug 2007 23:46:25 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[geekery]]></category>
		<category><![CDATA[personal]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.notedpath.com/?p=3</guid>
		<description><![CDATA[After trying to keep a blog numerous times already, I am committed to keep this one going! It took me awhile to get setup after rebuilding my slice (I am hosted by SliceHost). Most of the time was spent having to google the commands I had to run and figuring out missing apache modules since [...]]]></description>
			<content:encoded><![CDATA[<p>After trying to keep a blog numerous times already, I am committed to keep this one going!</p>
<p>It took me awhile to get setup after rebuilding my slice (I am hosted by <a href="http://www.slicehost.com" target="_blank">SliceHost</a>).  Most of the time was spent having to google the commands I had to run and figuring out missing apache modules since this is all new to me.  It&#8217;s been a good learning experience though <img src='http://www.theodorenguyen-cao.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>But after 4 hours, I&#8217;ve setup the following</p>
<ul>
<li>256mb Ubuntu slice</li>
<li>apache2</li>
<li>mysql</li>
<li>subversion</li>
<li>php</li>
<li>ruby/rails</li>
</ul>
<p>Next steps are to get Java and Tomcat installed, as well as a sample Rails app up and running.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2007/08/18/fresh-start/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
