<?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>23rd World &#187; Coding</title>
	<atom:link href="http://23rdworld.com/category/coding/feed/" rel="self" type="application/rss+xml" />
	<link>http://23rdworld.com</link>
	<description>The public notebook of Mahalie Stackpole, Web Developer.</description>
	<lastBuildDate>Fri, 07 Oct 2011 18:43:02 +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>Polyfill Fixin&#8217;</title>
		<link>http://23rdworld.com/2011/10/07/polyfill-fixin/</link>
		<comments>http://23rdworld.com/2011/10/07/polyfill-fixin/#comments</comments>
		<pubDate>Fri, 07 Oct 2011 18:42:02 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Browsers]]></category>
		<category><![CDATA[Coding]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=319</guid>
		<description><![CDATA[When my coworker @gigabo bothers to talk, gold nuggets of dev best practices start dropping left and right. I try write them down quickly to look up later (I always try to RTFM so as to keep the well flowing). I realized I might as well log the fruit of my efforts here&#8230; Today&#8217;s nugget: [...]]]></description>
			<content:encoded><![CDATA[<p>When my coworker @gigabo bothers to talk, gold nuggets of dev best practices start dropping left and right. I try write them down quickly to look up later (I always try to RTFM so as to keep the well flowing). I realized I might as well log the fruit of my efforts here&#8230; </p>
<p>Today&#8217;s nugget:<br />
In reference to the bug that causes default text served to an input to populate again if a user types too fast.</p>
<blockquote><p>&quot;Oh great, when we fix it, it will be reused by all of our apps &#8211; it&#8217;s a polyfill fix!&quot;</p></blockquote>
<p>I thought a polyfill was when you apply color to polygon. Is my front-end background obvious now?</p>
<p>Bo <a href="https://github.com/Modernizr/Modernizr/wiki/HTML5-Cross-Browser-Polyfills" title="HTML5 Cross-browser polyfills">heard it</a> from <a href="http://paulirish.com/?s=polyfill">Paul Irish</a>, the more commonly known gold-nugget dropping web dev.</p>
<p>No need to recreate the wheel, just read this: <a href="http://remysharp.com/2010/10/08/what-is-a-polyfill/">What is a polyfill?</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2011/10/07/polyfill-fixin/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Announcing the Walk Score Plugin for WordPress</title>
		<link>http://23rdworld.com/2011/08/10/announcing-the-walk-score-wordpress-plugin/</link>
		<comments>http://23rdworld.com/2011/08/10/announcing-the-walk-score-wordpress-plugin/#comments</comments>
		<pubDate>Wed, 10 Aug 2011 21:54:27 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Coding]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=303</guid>
		<description><![CDATA[Testing the new Walk Score plugin for WordPress (coincidentally, my first publicly released plugin). Below you should see a map showing the White House in Washington DC. Embed code for the map above: &#91;walk-score-map address="1450 Pennsylvania Avenue Northwest, Washington DC" format="vertical" size="small"&#93; Now the Sydney Opera House, following the embed code used to create it: [...]]]></description>
			<content:encoded><![CDATA[<p>Testing the new <a href="http://www.walkscore.com/professional/word-press.php">Walk Score plugin</a> for <a href="http://wordpress.org/">WordPress</a> (coincidentally, my first publicly released plugin). Below you should see a map showing the White House in Washington DC.</p>
<p><iframe width='500' height='500' src="http://23rdworld.com/wp-content/plugins/walk-score/frame-maker.php?id=3237b59f59174541a76291922c4137df&a=1450 Pennsylvania Avenue Northwest, Washington DC&o=v&s=s" scrolling='no' style='overflow:hidden' frameborder='0' class='wspi'></iframe></p>
<p>Embed code for the map above:<br />
<code>&#91;walk-score-map address="1450 Pennsylvania Avenue Northwest, Washington DC" format="vertical" size="small"&#93;</code></p>
<p>Now the Sydney Opera House, following the embed code used to create it:</p>
<p><code>&#91;walk-score-map address="Macquarie St, Sydney New South Wales 2000, Australia" format="horizontal" size="small"&#93;</code></p>
<p><iframe width='500' height='300' src="http://23rdworld.com/wp-content/plugins/walk-score/frame-maker.php?id=3237b59f59174541a76291922c4137df&a=Macquarie St, Sydney New South Wales 2000, Australia&o=h&s=s" scrolling='no' style='overflow:hidden' frameborder='0' class='wspi'></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2011/08/10/announcing-the-walk-score-wordpress-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tips on Install of WordPress on Mac OSX</title>
		<link>http://23rdworld.com/2011/07/29/tips-on-install-of-wordpress-on-mac-osx/</link>
		<comments>http://23rdworld.com/2011/07/29/tips-on-install-of-wordpress-on-mac-osx/#comments</comments>
		<pubDate>Sat, 30 Jul 2011 00:51:50 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Coding]]></category>
		<category><![CDATA[Content Management]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=272</guid>
		<description><![CDATA[Prerequisites / WordPress Dependencies Local Apache web server with PHP &#038; Mysql. If you don&#8217;t already have your local dev environment set up, consider installing MAMP or MAMP Pro. MAMP is a one-click install which will provide you with a clean, isolated stack for local development that has Mysql and PHP pre-configured. Another benefit of [...]]]></description>
			<content:encoded><![CDATA[<h2>Prerequisites / WordPress Dependencies</h2>
<p>Local Apache web server with PHP &#038; Mysql.</p>
<p>If you don&#8217;t already have your local dev environment set up, consider installing <a href="http://www.mamp.info">MAMP or MAMP Pro</a>. MAMP is a one-click install which will provide you with a clean, isolated stack for local development that has Mysql and PHP pre-configured. Another benefit of MAMP is that it is very popular so there are countless tutorials and examples to follow.</p>
<p>If for some reason you don&#8217;t want to use MAMP or you&#8217;ve already configured your local enviro somewhat but you still need PHP and/or MySQL, check out this article: <a href="http://www.thermalexposure.com/2010/09/02/install-and-configure-wordpress-on-mac-os-x-snow-leopard-step-by-step/#comment-59">Install and Configure WordPress on Mac OS X Snow Leopard Step-By-Step</a> by awilliams of Thermal Exposure. It takes you from zero to WordPress using Leopard&#8217;s built-in Apache server, although I do recommend you supplement these instructions with these tips and my other article <a href="http://23rdworld.com/2011/07/29/install-mysql-for-local-dev-on-mac-osx-10-6">Install Mysql for Local Dev on Mac OSX 10.6</a></p>
<h2>Download WordPress</h2>
<p>Download and extract <a href="http://wordpress.org/">the latest WordPress</a> package.</p>
<p>Move it somewhere good like in your /Sites/ folder (most usual place but depends on your config, it can go anywhere you desire so long as your local web server is configured to look there).</p>
<p>I moved mine to <code>/users/me/Sites/wordpress</code> and renamed &#8216;wordpress&#8217; to &#8216;wptest.loc&#8217; resulting in: <code>/users/me/Sites/wptest.loc</code>. You can rename it whatever you want &#8211; probably the name of your project or client&#8217;s site is a good idea.</p>
<p>WordPress needs permission to modify files during installation and runs as user &#8220;_www&#8221; so make sure it can do this.<br />
<code>
<pre>cd /Users/me/Sites/
sudo chown -R _www wptest.loc
sudo chmod -R g+w wptest.loc</pre>
<p></code></p>
<h2>Create a Database</h2>
<p>Now we need a database, a database user and a password. Technically you can use any user or add WordPress tables to an existing database but I like to keep things separate so it&#8217;s easy to port elsewhere or start over without worrying about wrecking other things. I&#8217;m going to create a database called wptest, database user named wptest_user. You can do this using a GUI (phpMyAdmin, etc.) but I guarantee you cannot do that faster than I can type this ;)</p>
<p><code>
<pre>
bash > mysql -u root -p
mysql > create database wptest;
mysql > GRANT ALL ON wptest.* TO wptest_user@localhost IDENTIFIED BY "secretpassword";
mysql > exit</pre>
<p></code></p>
<h2>Configure Site Address</h2>
<p>Remember how I renamed the <code>wordpress</code> folder to <code>wptest.loc</code>? This is because I plan on accessing it in the browser via http://wptest.loc instead of http://127.0.0.1/ or http://localhost.</p>
<p>To do this I use Virtual Hosts in my environment and point the virtual domains to my local IP address in my hosts file. It&#8217;s confusing at first but once you do it a time or two it will be second nature. It&#8217;s important if you&#8217;d like to work on multiple sites on your local environment concurrently and don&#8217;t want to rely on weird subdirectories or other work-arounds that wouldn&#8217;t easily port to a live web server.</p>
<p><a href="http://brassblogs.com/tutorials/setting-up-virtual-hosts-on-mamp">Setting Up Virtual Hosts on MAMP</a> explains how to set this system up. I provide only abbreviated steps below (MAMP not assumed).</p>
<h3>Setting up Virtual Hosts (in short)</h3>
<ul>
<li>In your httpd.conf file there should lines like this:<br />
<code>
<pre># Virtual Hosts
Include /path/to/your/httpd-vhosts.conf</pre>
<p></code></li>
<li>In your httpd-vhosts.conf file there should be a line like this:<br />
<code>
<pre>NameVirtualHost *:80
Include /path/to/your/httpd-vhosts.conf</pre>
<p></code></li>
</ul>
<h3>Create A Virtual Host</h3>
<p>Now, whenever you want to create a new virtual (local only) site:</p>
<ul>
<li>In your httpd-vhosts.conf file add an entry like this:<br />
<code>
<pre>&lt;VirtualHost *>
    ServerName wptest.loc
    DocumentRoot "/Users/me/Sites/wptest.loc"
  &lt;Directory "/Users/me/Sites/wptest.loc">
    Order allow,deny
    Allow from all
    DirectoryIndex index.php index.html
  &lt;/Directory>
&lt;/VirtualHost></pre>
<p></code></li>
<li>In your hosts file (mine is /etc/hosts) add another entry for your local IP:<br />
<code>
<pre>127.0.0.1    wptest.loc</pre>
<p></code></li>
</ul>
<h2>Install WordPress</h2>
<p>Point your browser to http://wptest.loc</p>
<p>If no config file is found you can edit it yourself, <code>wp-config-sample.php</code> as <code>wp-config.php</code> and adding the correct information for the database you created. Try using <code>172.0.0.1</code> as the Dataase Host if <code>localhost</code> doesn&#8217;t work.</p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2011/07/29/tips-on-install-of-wordpress-on-mac-osx/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Adding TinyMCE to EE Wiki</title>
		<link>http://23rdworld.com/2010/03/01/adding-tinymce-to-ee-wiki/</link>
		<comments>http://23rdworld.com/2010/03/01/adding-tinymce-to-ee-wiki/#comments</comments>
		<pubDate>Mon, 01 Mar 2010 23:31:04 +0000</pubDate>
		<dc:creator>Administrator</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Content Management]]></category>
		<category><![CDATA[ExpressionEngine]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[ee]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[tinymce]]></category>
		<category><![CDATA[wiki]]></category>
		<category><![CDATA[wysiwyg]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=230</guid>
		<description><![CDATA[Having found several requests in the forums and no tutorials online or in documentation, I&#8217;ve documented the steps I took to add the TinyMCE editor to my ExpressionEngine wiki. I am using the EEDocs wiki theme to provide documentation for my users. Here are very quick and dirty instructions to add TinyMCE to your EE [...]]]></description>
			<content:encoded><![CDATA[<p>Having found several requests in the forums and no tutorials online or in documentation, I&#8217;ve documented the steps I took to add the TinyMCE editor to my ExpressionEngine wiki. </p>
<p>I am using the EEDocs wiki theme to provide documentation for my users. Here are very quick and dirty instructions to add TinyMCE to your EE Wiki which basically follows the <a href="http://wiki.moxiecode.com/index.php/TinyMCE:Installation">default instructions</a> provided by the <a href="http://wiki.moxiecode.com/index.php/TinyMCE:Index">TinyMCE Wiki</a>.</p>
<ul>
<li>
<p><strong>Download <a href="http://sourceforge.net/projects/tinymce/">TinyMCE</a>, extract it.</strong></p>
</li>
<li>
<p><strong>Upload the TinyMCE to your webserver, note the path.</strong></p>
</li>
<li>
<p><strong>Find the default PHP file for the EE wiki theme you are using</strong>. Mine was in my siteroot/themes/wiki_themes/eedocs/ folder and is called eedocs.php. The default them would be in the themes folder under wiki_themes/default/default.php. Open this in the editor of your choice. You may want to create a backup copy in case you need to revert later.</p>
</li>
<li>
<p><strong>Add the following code to the &lt;head&gt; area</strong>:</p>
<p><code>&lt;script type="text/javascript" src="http://yoursite.com/yourpathto/tinymce/jscripts/tiny_mce/tiny_mce.js"&gt;&lt;/script&gt;</code>
<p>Note you may want to test that path in your browser and make sure it is linking to the tiny_mce.js path as intended.</p>
</li>
<li>
<p><strong>Add the following inline script to the &lt;head&gt; area </strong>:</p>
<p> <code>&lt;script type="text/javascript"&gt;<br />
tinyMCE.init({<br />
	mode : "textareas"<br />
});<br />
&lt;/script&gt;</code></li>
</ul>
<p>This will turn all of your textareas into TinyMCE editor fields. There are many other ways to configure this, you could specify exactly which textareas to use TinyMCE, for example. For all your TinyMCE customization options, see <a href="http://wiki.moxiecode.com/index.php/TinyMCE:Installation">the TinyMCE wiki</a> and for help knowing where to put what, check out the <a href="http://expressionengine.com/docs/index.html">ExpressionEngine User Guide</a> section on the <a href="http://expressionengine.com/docs/modules/wiki/wiki_templates.html">Wiki Theme Template</a>. </p>
<p>I can&#8217;t say I&#8217;ve done extensive testing yet, but the default TinyMCE install has not (so far) interfered with wiki markup at all, which is to say that [[Category:Foo::Bar]] and regular [[wiki links]] seem to be working happily.</p>
<p>Screenshot:<br />
<a href="http://www.flickr.com/photos/mahalie/4399117261/sizes/o/" title="ExpressionEngine Wiki with TinyMCE by mahalie, on Flickr"><img src="http://farm5.static.flickr.com/4028/4399117261_45cd019b0e.jpg" width="500" height="494" alt="ExpressionEngine Wiki with TinyMCE" /></a></p>
<p class="warning"><strong>Update:</strong> Installed the <a href="http://markitup.jaysalvat.com/home/">MarkItUp</a></strong> editor in a similar fashion, I like it a lot more than TinyMCE out of the box. May be looking at <a href="http://slateinfo.blogs.wvu.edu/plugins/textile_editor_helper">Textile Editor Helper (TEH)</a> and <a href="http://ckeditor.com/">CKEditor</a> as well, so check back for a WYSIWYG / markup editor showdown. In the meantime, consider what you need a WYSIWYG for and what markup under the hood you&#8217;re willing to live with in the long-term before settling on a solution for your site &#8211; here&#8217;s a good article that sums up that issue: <a href="http://redcloth.org/articles/wysi-dangerous-why-wysiwyg-editors-are-bad-for-your-website/">WYSI-dangerous: Why WYSIWYG  editors are bad for your website</a> on redcloth.org.</p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2010/03/01/adding-tinymce-to-ee-wiki/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to Fix Your ExpressionEngine RSS Template</title>
		<link>http://23rdworld.com/2009/12/23/how-to-fix-your-expressionengine-rss-template/</link>
		<comments>http://23rdworld.com/2009/12/23/how-to-fix-your-expressionengine-rss-template/#comments</comments>
		<pubDate>Thu, 24 Dec 2009 00:46:05 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Accessibility (SEO)]]></category>
		<category><![CDATA[Coding]]></category>
		<category><![CDATA[Content Management]]></category>
		<category><![CDATA[ExpressionEngine]]></category>
		<category><![CDATA[RSS]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Web Standards]]></category>
		<category><![CDATA[cms]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[documentation]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[instructions]]></category>
		<category><![CDATA[lamp development]]></category>
		<category><![CDATA[reference]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=212</guid>
		<description><![CDATA[I began investigating the fascinating minutia of RSS when I couldn't find a reasonable answer in the EE forums to why Google Reader was re-posting every updated post on my site even thought the entry dates hadn't changed. As I went through the prevalent templates floating around the EE community line-by-line I noticed several things [...]]]></description>
			<content:encoded><![CDATA[<p>I began investigating the fascinating minutia of RSS when I couldn't find a reasonable answer in the EE forums to why <a class="zem_slink freebase/en/google_reader" href="http://www.google.com/reader" title="Google Reader" rel="homepage">Google Reader</a> was re-posting every updated post on my site even thought the entry dates hadn't changed. As I went through the prevalent templates floating around the EE community line-by-line I noticed several things that could be improved upon. The only critical fix, in my opinion, is removal of seconds from the dates in the &lt;item /> section. If you want your feed to validate you'll want to add the atom namespace. The rest are optional improvements.</p>

<p>If you want to skip the wheres and whys, I've posted the the <a href="http://snipplr.com/view/25353/ee-default-rss-template-fixed/">updated (fixed)</a> and <a href="http://snipplr.com/view/25354/ee-rss-template-improved/">improved RSS</a> templates on Snipplr.com and in their entirety at the end of this article.</p>

<h2>Existing RSS templates for ExpressionEngine</h2>
<ul>
	<li><a href="http://expressionengine.com/templates/source/category/feeds/">ExpressionEngine &gt; Downloads &gt; Template Library &gt; Feeds</a> - this template will be the basis of my recommendations, most other templates I've found seem to be derivative of this one.</li>
<li><a href="http://www.ablognotlimited.com/articles/customizing-expressionengine-rss-template/">Customizing ExpressionEngine RSS 2.0 Template</a> - an oft-referred to article at 'A Blog Not Limited' which provides some good updates and tweaks but that still keeps a lot of the original template intact.</li>
</ul>

<h2>Resources</h2>
<ul>
	<li><a href="http://www.rssboard.org/rss-specification">RSS 2.0 Specification</a></li>
	<li><a href="http://feedvalidator.org/">Feed Validator</a></li>
	<li>ExpressionEngine User Guide
    <ul>
     <li><a href="http://expressionengine.com/docs/modules/rss/index.html">RSS Module Tags</a></li> 
     <li><a href="http://expressionengine.com/docs/templates/date_variable_formatting.html">Date Variable Formatting</a></li>   
    </ul>
  </li>
  <li><a href="http://expressionengine.com/downloads/details/xml_encode/">EE XML Encode Plugin Information</a></li>
</ul>

<h2>Methodology</h2>
<p>I'm not going for a PHD in online syndication, I just wanted my <a href="http://en.wikipedia.org/wiki/RSS" title="RSS" rel="wikipedia">RSS feeds</a> to be error-free, work as expected in major aggregators and to use  best-practices which could be determined within a somewhat low threshold of research pain. In addition to referring first to the RSS 2.0 specifications, I used the RSS feeds of some really large websites to serve as examples, making the assumption (I know) that these sites have probably done thorough research on this topic. Often my choices were the result of seeing if these "big players" were all doing the same thing. All the feeds are major sites with the exception of the Flickr blog. The Flickr blog is using <a href="http://wordpress.com" title="WordPress.com" rel="homepage">WordPress.com</a>. I figured with their huge user-base not only would the feeds have been thoroughly vetted, most aggregators will be able to read them due to the sheer volume of WordPress-powered sites out there. Also I chose a WordPress.com feed instead of a self-hosted installation of WP to make sure it was the well-tested standard feed. The feeds I used are:</p>
<ul>
  <li><a href="http://feeds.nytimes.com/nyt/rss/HomePage">The New York Times Home Page Feed</a></li>
  <li><a href="http://newsrss.bbc.co.uk/rss/newsonline_world_edition/front_page/rss.xml">BBC News | News Front Page | World Edition Feed</a></li>
  <li><a href="http://rss.cnn.com/rss/cnn_topstories.rss">CNN.com Top Stories Feed</a></li>
  <li><a href="http://pheedo.msnbc.msn.com/id/3034600/device/rss/">MSNBC.com Women's Helath Feed</a></li>
  <li><a href="http://blog.flickr.net/en/feed/">Flickr Blog Feed</a></li>
</ul>

<h2>RSS Feed Breakdown</h2>
<h3>Feed Format: RSS vs. Atom</h3>
<p>As of mid-2005, the two most likely candidates are <a href="http://en.wikipedia.org/wiki/RSS">RSS 2.0</a> and <a href="http://en.wikipedia.org/wiki/Atom_%28standard%29">Atom 1.0</a>. Google reader supports either fully and they suggest choosing one or the other (not both) because most RSS readers support all major formats and offering both can confuse users. The Atom syndication format, whose creation was in part motivated by a desire to get a clean start free of the issues surrounding RSS, has been adopted as <a href="http://en.wikipedia.org/wiki/IETF">IETF</a> Proposed Standard <a href="http://tools.ietf.org/html/rfc4287">RFC 4287</a> and is used by Google. However, RSS 2.0 was the first to support enclosures and has captured the podcasting audience and is the recommended format in the <a href="http://www.apple.com/itunes/podcasts/specs.html">iTunes podcasts specs</a>.</p>
<p>I generally do as Google does when it comes to web optimization, and I am a big fan of standards. In some regards I would call Atom "the higher path". That said, I am also a big fan of simplicity and ease-of-use so I'm going with RSS 2.0 because:</p>
<ul>
  <li>I already  hand-built an RSS 2.0 feed for podcasting (well, for iTunes) so would rather learn one standard / keep all feeds similarly formatted.</li>
  <li>One less term that could potentially confuse end-users and "web lite" folk who might inherit my work later on.</li>
  <li>A lot of really big sites that have probably carefully considered this topic went with RSS 2.0, including NYTimes.com, AListApart.com, Ebay.com, news.BBC.co.uk, and CNN.com.</li>
</ul>
<h3>RSS XML Namespaces</h3>
Here's where my first change kicks in. If you aren't actually USING a namespace in your RSS feed there's no need to include it - it's just cruft.
<h3>Before</h3>
<code>&lt;rss version="2.0"<br />
    xmlns:dc="http://purl.org/dc/elements/1.1/"<br />
    xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"<br />
    xmlns:admin="http://webns.net/mvcb/"<br />
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"<br />
    xmlns:content="http://purl.org/rss/1.0/modules/content/"&gt;</code>
<h3>After</h3>
<code>&lt;rss version="2.0"<br />
    xmlns:dc="http://purl.org/dc/elements/1.1/"&gt;</code>
<h3>Even Better</h3>
<code>&lt;rss version="2.0"<br />
    xmlns:dc="http://purl.org/dc/elements/1.1/"<br />
    xmlns:atom="http://www.w3.org/2005/Atom"&gt;</code>    
<p>The namespaces <a href="http://web.resource.org/rss/1.0/modules/syndication/">sy</a> and <a href="http://web.resource.org/rss/1.0/modules/content/">content</a> aren't used at all and can just be removed. Optional: I chose to remove <code>xmlns:admin="http://webns.net/mvcb/"</code> and the only tag that used it, <code>&lt;admin:generatorAgent rdf:resource="http://expressionengine.com/" /&gt;</code> - removing the <a href="http://web.resource.org/rss/1.0/modules/admin/">admin</a> namespace also eliminated <a href="http://www.w3.org/TR/1999/REC-rdf-syntax-19990222/">rdf</a>, which admin namespace depends on.</p>
<p>I'm not saying any of the removed namespaces are bad, just unnecessary. For example, <a href="http://web.resource.org/rss/1.0/modules/admin/">admin</a> is a very common namespace, but if you leave it in you should update the URI to include the EE version number (dynamically) and add the <code>&lt;admin:errorReportsTo rdf:resource="URI"/&gt;</code> pointing to a valid email address for errors. It may be beneficial to aggregators in reporting statistical reporting of web frameworks and content management systems delivering aggregated RSS feeds.</p>
<p>I rather admire the efficency and simplicity of the namespace declarations used by NYTimes.com, CNN.com and others - so again, this is personal choice.</p>
<p>The third option (even better) adds the <a href="http://www.w3.org/2005/Atom">atom</a> namespace. The default EE RSS feed will not <a href="http://feedvalidator.org">validate</a> because it lacks the required atom:link tag containing the URI of the feed itself. There is some debate on whether this is actually necessary (some say the validator is wrong, not the lack of the atom tag)- read the article <a href="http://workbench.cadenhead.org/news/3284/adding-atomlink-your-rss-feed">Adding Atom:Link to Your RSS Feed</a> for background on this.</p>
<p>Depending on your site's content, your SEO practices and target audience, it is likely that you may need additional namespaces. A media-rich site, for example, would benefit from the <a href="http://video.search.yahoo.com/mrss/mrss">media</a> namespace. The media namespace is used to syndicate video, images and other media and can open up your feed to consumption by media-rich aggregators and services like <a href="http://developer.cooliris.com/?p=full">Cooliris</a> and <a href="http://video.search.yahoo.com/">Yahoo Video Search</a>.</p>
<h3>Channel Area</h3>
<p>Most of the default template makes perfect sense - just make sure to take a look at your feed output to make sure all the EE fields used have valid values. Also, make sure you want to the {weblog_foo} tags - if you are providing a site feed that combines multiple sections you will probably want to hand-edit many of the tags in the channel area.</p>
<h3>Dates</h3>
<p class="warning"><strong>Important tip: make sure your feed is correctly reporting the timestamp of your entry date.</strong> If the seconds are changing on an item whenever you make an update this will cause many aggregators, including Google Reader, to repost the entry to your RSS feed. Either take the seconds off the time or replace '%s' with an arbitrary static value like '15'.</p>
<p>A search for 'RSS Updates' in the <a href="http://expressionengine.com/forums/">EE Forums</a> will reveal that many people have had this problem. I tested all the date fields in my feeds (see <a href="http://expressionengine.com/forums/viewthread/138996/#686193">this thread</a> for details) and found that although the entry date day, hour and minute doesn't change on update (as expected), the seconds do! This weird behavior has something to do with how the dates are stored in the database and/or how the date is interpreted by EEs date tags. What it means is that if you go back and edit a post from three years ago, some aggregators will repost the item to your RSS feed even though you did not change the entry date. This can be especially troubling if you like to go back and tweak a post a lot right after publishing - you may go to your feed reader to see it reposted several times in a row.</p>
<!--
<p>So, FIX the second &lt;dc:date&gt; line, change the {gmt_entry_date} format to <code>"%Y-%m-%dT%H:%i%Q"</code>. As noted above, you could also put in a static number for seconds.</p>
-->
<h4>pubDate vs. dc:date</h4>
<p>&lt;pubDate&gt; is part of the <a href="http://www.rssboard.org/rss-specification">RSS 2.0 spec</a>. A lot of feeds out there still use &lt;dc:date&gt; and this either because they kept it from their RSS 1.0 template (for which dc:date was the only option) or they really like the very popular <a href="http://dublincore.org/documents/dces/">Dublin Core namespace</a> or they prefer it because of the <a href="http://www.w3.org/TR/NOTE-datetime">ISO 8601 date format</a> which is much more prevalent than the (really old, as in <a href="http://www.faqs.org/rfcs/rfc822.html">ARPANET old</a>!) <a href="http://feedvalidator.org/docs/error/InvalidRFC2822Date.html">RFC 822 date format</a> that &lt;pubDate&gt; uses. On one hand it makes sense to stay with the spec and pull in namespace elements only as required. On the other hand, it makes sense to provide output in the most reusable way (updated date format). Feed readers parse either just fine, so this is judgment call on your part. Here's an agrument for each:
</p><ul>
<li><a href="http://bradchoate.com/weblog/2003/06/21/rss">bradchoate.com/weblog/2003/06/21/rss</a></li>
<li><a href="http://diveintomark.org/archives/2003/06/21/history_of_rss_date_formats">diveintomark.org/archives/2003/06/21/history_of_rss_date_formats</a></li>
</ul>
<p>Based on my own survey of the feeds referenced above, I opted to switch to &lt;pubDate&gt;, replacing &lt;dc:date /&gt; in the channel with:
</p><p><code>&lt;pubDate&gt;{gmt_date format="%D, %d %M %Y %H:%i:%s %T"}&lt;/pubDate&gt;</code></p>
And replacing &lt;dc:date /&gt; in the item declaration(s) with:
<p><code>&lt;pubDate&gt;{gmt_entry_date format=&qout;%D, %d %M %Y %H:%i %T"}&lt;/pubDate&gt;</code></p>
<h3>Item &lt;title ... /&gt;</h3>
<p>The default tag is fine, but if your content people keep putting special characters in their titles (like mine do) then you might want to add the <code>protect_entities="yes"</code> attribute to the <code>{exp:xml_encode}</code> tag. For example the main EE site I work on uses &amp;#187; (») and &amp;amp; (&amp;) a lot in titles.</p>
<p>Even after protecting entities I was still having a heck of a time getting a trademark (™) symbol that is used on a site in many post titles and in a category to consistently display on both the webpage and in RSS feed aggregators - after some digging I realized the character entity that was being used (&amp;#x2122;) for it was not the <a href="http://sitening.com/extras/utf-8-character-html-encoding/">UTF-8</a> reference (&amp;#8482;) specified as the encoding for both the RSS and XHTML. So, make sure you (or your content editors) use the correct character encoding entities for special characters!</p>
<h3>Item &lt;guid ... /&gt;</h3>
<p>As formated in the <a href="http://expressionengine.com/templates/source/category/feeds/">official EE RSS template</a> the <code>&lt;guid&gt;</code> is not a permalink, and therefore should have  <code>isPermaLink="false"</code> attribute added to it. Of course you could use your actual permalink and then you could leave that off or change it to "true".</p>
<blockquote>"We recommend the use of the Atom and RSS 2.0 elements to unambiguously identify items. An item that is updated should keep its original ID, and a new item should never reuse an older item's ID. Changing IDs unnecessarily may result in duplicate items, and reusing IDs may cause some items to be hidden. <a href="http://www.taguri.org/">"Tag URIs"</a> make good IDs, since they don't change even when you need to reorganize your links." - <a href="http://www.google.com/help/reader/publishers.html#feeds">Google Reader Tips for Publishers &gt; Implementing Feeds</a></blockquote>  
<p>The above recommendatio explains the multi-posting of an entry on update issue I referred to earlier. Because of this, you will probably want to remove the '%s' from the formatting attribute as well. So, change the <code>gmt_entry_date</code> format string in the &lt;guid&gt; line to <code>"%H:%iZ"</code>.</p>
<p>Optionally, you could just use the actual URI of your article and change the <code>isPermalink</code> attribute to true. EE won't let you post two items with the same URL title within a weblog/channel, so you are pretty safe there (EE adds a number to the end of URL title if one already exists).</p>
<h3>Item &lt;description.../&gt;</h3>
<p>This line is technically fine, but most people will change this to allow HTML formatting of their entries: <code>&lt;description&gt;&lt;![CDATA[{summary}{body}]]&gt;&lt;/description&gt;</code>. This is what displays the bulk of your entry item and where most of your site-specific customization will happen, <a href="http://www.ablognotlimited.com/articles/customizing-expressionengine-rss-template/">Customizing ExpressionEngine RSS 2.0 Template</a> on 'A Blog Not Limited' is a great resource for this.</p>
<h3>Categories</h3>
The template uses &lt;dc:subject&gt;. Your feed will be more interoperable with other systems and make more sense programatically if each category is in its own tag. You can do this using the &lt;dc:subject&gt; format, or you can switch to using the &lt;category&gt; tag for each as provided for in the RSS 2.0 spec.
<h4>Original Template</h4>
<p>Code:</p> 
  <p><code>&lt;dc:subject&gt;{exp:xml_encode}{categories backspace="1"}{category_name}, {/categories}{/exp:xml_encode}&lt;/dc:subject&gt;</code></p>
<p>Result:</p>
  <p><code>&lt;dc:subject&gt;Architecture, Science, Workplace&lt;/dc:subject&gt;</code></p>
<h4>Separate using &lt;dc:subject&gt;</h4>
<p>Code:</p> 
  <p><code>{categories}&lt;dc:subject&gt;{exp:xml_encode}{category_name}{/exp:xml_encode}&lt;/dc:subject&gt;{/categories}</code></p>
<p>Result:</p>
  <p><code>&lt;dc:subject&gt;Architecture&lt;/dc:subject&gt;<br />
  &lt;dc:subject&gt;Science&lt;/dc:subject&gt;<br />
  &lt;dc:subject&gt;Workplace&lt;/dc:subject&gt;</code></p>
<h4>Separate using &lt;category&gt;</h4>
<p>Code:</p> 
<p><code>{categories}&lt;category&gt;{exp:xml_encode}{category_name}{/exp:xml_encode}&lt;/category&gt;{/categories}</code></p>
<p>Result:</p>
<p><code>&lt;category&gt;Architecture&lt;/category&gt;<br />
&lt;category&gt;Science&lt;/category&gt;<br />
&lt;category&gt;Workplace&lt;/category&gt;</code></p>

<h2>Updated EE RSS 2.0 Template</h2>
<p>This includes what I consider minimal mandatory fixes to ensure error-free code and to prevent (re)posting problems.</p>
<blockquote class="code"><pre>
{assign_variable:master_weblog_name="blog"}
{assign_variable:master_weblog_status="open"}
{exp:rss:feed weblog="{master_weblog_name}" status="{master_weblog_status}"}

&lt;?xml version="1.0" encoding="{encoding}"?>
&lt;rss version="2.0"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:admin="http://webns.net/mvcb/"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
    &lt;channel>
    &lt;title>{exp:xml_encode}{weblog_name}{/exp:xml_encode}&lt;/title>
    &lt;link>{weblog_url}&lt;/link>
    &lt;description>{weblog_description}&lt;/description>
    &lt;dc:language>{weblog_language}&lt;/dc:language>
    &lt;dc:creator>{email}&lt;/dc:creator>
    &lt;dc:rights>Copyright {gmt_date format="%Y"}&lt;/dc:rights>
    &lt;dc:date>{gmt_date format="%Y-%m-%dT%H:%i:%s%Q"}&lt;/dc:date>
    &lt;admin:generatorAgent rdf:resource="http://expressionengine.com/" />
{exp:weblog:entries weblog="{master_weblog_name}" limit="10" rdf="off" dynamic_start="on" disable="member_data|trackbacks" status="{master_weblog_status}"}
    &lt;item>
      &lt;title>{exp:xml_encode}{title}{/exp:xml_encode}&lt;/title>
      &lt;link>{title_permalink=site/index}&lt;/link>
      &lt;guid isPermaLink="false">{title_permalink=site/index}#When:{gmt_entry_date format="%H:%iZ"}&lt;/guid>
      &lt;description>{exp:xml_encode}{summary}{body}{/exp:xml_encode}&lt;/description>
      &lt;dc:subject>{exp:xml_encode}{categories backspace="1"}{category_name}, {/categories}{/exp:xml_encode}&lt;/dc:subject>
      &lt;dc:date>{gmt_entry_date format="%Y-%m-%dT%H:%i%Q"}&lt;/dc:date>
    &lt;/item>
{/exp:weblog:entries}
    &lt;/channel>
&lt;/rss>
{/exp:rss:feed}
</pre>
</blockquote>

<h2>Improved EE RSS 2.0 Template</h2>
<p>This includes optional changes that I added as a result of various articles, the RSS 2.0 spec and by examining the feeds of major professional news sites.</p>
<blockquote class="code"><pre>
{assign_variable:master_weblog_name="BLOG"}
{assign_variable:master_weblog_status="OPEN"}
{assign_variable:master_rss_uri="http://PATH/TO/THIS/RSS/FEED"}

{exp:rss:feed weblog="{master_weblog_name}" status="{master_weblog_status}"}
&lt;?xml version="1.0" encoding="{encoding}"?>
&lt;rss version="2.0"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:atom="http://www.w3.org/2005/Atom">
    &lt;channel>
    &lt;title>{exp:xml_encode}{weblog_name}{/exp:xml_encode}&lt;/title>
    &lt;link>{weblog_url}&lt;/link>
    &lt;description>{weblog_description}&lt;/description>
    &lt;dc:language>{weblog_language}&lt;/dc:language>
    &lt;dc:creator>{email}&lt;/dc:creator>
    &lt;dc:rights>Copyright {gmt_date format="%Y"}&lt;/dc:rights>
    &lt;pubDate>{gmt_date format="%D, %d %M %Y %H:%i:%s %T"}&lt;/pubDate>
    &lt;atom:link href="{master_rss_uri}" rel="self" type="application/rss+xml" />   
{exp:weblog:entries weblog="{master_weblog_name}" limit="10" rdf="off" dynamic_start="on" disable="member_data|trackbacks" status="{master_weblog_status}"}
    &lt;item>
      &lt;title>{exp:xml_encode protect_entities="yes"}{title}{/exp:xml_encode}&lt;/title>
      &lt;link>{title_permalink=site/index}&lt;/link>
      &lt;guid isPermaLink="false">{title_permalink="site/index"}#id:{entry_id}#date:{gmt_entry_date format="%H:%i"}&lt;/guid>
      &lt;description>&lt;![CDATA[{summary}{body}]]&gt;&lt;/description>
      {categories}&lt;category>{exp:xml_encode protect_entities="yes"}{category_name}{/exp:xml_encode}&lt;/category>
      {/categories}
      &lt;pubDate>{gmt_entry_date format="%D, %d %M %Y %H:%i %T"}&lt;/pubDate>
    &lt;/item>
{/exp:weblog:entries}
    &lt;/channel>
&lt;/rss>
{/exp:rss:feed}						
</pre></blockquote>

<h2>Feedback</h2>
<p>Please let me know if you have any suggestions for improvements on the basic template. I have already submitted these suggestions (as have others) on the EE Forums and I hope this article will soon be out-dated. For further information on customizing your RSS feed including adding Google Analytics tracking and additional fields such as author name,  see <a href="http://www.ablognotlimited.com/articles/customizing-expressionengine-rss-template/">Customizing ExpressionEngine RSS 2.0 Template</a> at 'A Blog Not Limited' (if you use their updated template don't forget to remove the seconds from date fields in the item section).</p>]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2009/12/23/how-to-fix-your-expressionengine-rss-template/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Email protection using CSS</title>
		<link>http://23rdworld.com/2009/04/08/email-protection-using-css/</link>
		<comments>http://23rdworld.com/2009/04/08/email-protection-using-css/#comments</comments>
		<pubDate>Wed, 08 Apr 2009 23:18:41 +0000</pubDate>
		<dc:creator>Administrator</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[contact]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[spam]]></category>
		<category><![CDATA[xhtml]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=197</guid>
		<description><![CDATA[This post originally appeared on my personal blog in March of 2005. It is till useful a half decade later, so finally posting it here. This code is also available on Snipplr as well. Any spambot worth its salt spawned by evil genius could "guess" email addresses by skimming for all 'alias@'s and automatically concatenate [...]]]></description>
			<content:encoded><![CDATA[<a href="http://23rdworld.com/2009/04/08/email-protection-using-cssemail-protection-using-css/"><img src="http://23rdworld.com/wp-content/uploads/2009/04/spam_protect_emails.jpg" alt="Email Link Protection - a graceful and user-friendly technique" title="spam_protect_emails" width="500" height="128" /></a>
<em>This post originally appeared on my personal blog in March of 2005. It is till useful a half decade later, so finally posting it here. This code is also <a href="http://snipplr.com/view/16077/gracefully-degrading-email-obfuscation/">available on Snipplr</a> as well.</em>
<p>Any spambot <strike>worth its salt</strike> spawned by evil genius could "guess" email addresses by skimming for all 'alias@'s and automatically concatenate them with the site's url base and any other domains found on the page, so in the javascript I separate the '@' from the alias.</p>

<p>Enough about the wheres and whys, here's some cut n' paste fun for your use. This code will use javascript to display a normal, clickable mailto: link on your page and if javascript is turned off you still get a screen-readable, selectable email address displayed using a CSS trick.</p>
<blockquote class="code">
<pre>
&lt;style type="text/css"&gt;
.backwards {
unicode-bidi:bidi-override; direction: rtl;font-weight:bold;
}
&lt;/style&gt;
&lt;script type="text/javascript"&gt;
&lt;!--
linkAddy=('alias' + '@' + 'yourdomain.com')
document.write('&lt;a href="mailto:' + linkAddy + '"&gt;' + linkAddy + '&lt;/a&gt;')
//--&gt;
&lt;/script&gt;

&lt;noscript&gt;
&lt;p&gt;Please email me at
&lt;strong&gt;&lt;span class="backwards"&gt;moc.niamodruoy@saila&lt;/span&gt;
&lt;/strong&gt;.&lt;br /&gt;&lt;/p&gt;
&lt;/noscript&gt;
</pre>
</blockquote>

<p>Here's a version for you really paranoid folks that don't want live links at all (or maybe you just want a tiny user obstacle to ensure necessity of correspondence), but you do want your email address to appear correctly if possible but with better protection, plus insurance if javascript is turned off:</p>

<blockquote class="code"><pre>
&lt;style type="text/css"&gt;
.backwards {
unicode-bidi:bidi-override; direction: rtl;font-weight:bold;
}
&lt;/style&gt;
Please email me at
&lt;span class="backwards"&gt;&lt;script type="text/javascript"&gt;
&lt;!--
backAddy=('moc.niamodruoy' + '@' + 'saila')
document.write(backAddy)
//--&gt;
&lt;/script&gt;&lt;/span&gt;
&lt;noscript&gt;&lt;strong&gt;alias at
yourdomain dot com&lt;/strong&gt;&lt;/noscript&gt;
</pre></blockquote>

<p>Here's a working example:</p>

<p>Please email me at  

<script type="text/javascript">
<!-- 
linkAddy=('ma' + 'il' + '@' + 'mahalie.com')
document.write('<a href="mail' + 'to:' + linkAddy + '">' + linkAddy + '</a>')
 //-->
</script>
<noscript>
   <span style="unicode-bidi:bidi-override; direction: rtl;font-weight:bold;">moc.eilaham@liam</span>.
</noscript></p>

<p>Here's a few other ways to protect email addresses from spam bots. If you have a preferred method not listed here, please let me know in the comments.</p>
<ul>
<li><a href="http://www.alistapart.com/articles/gracefulemailobfuscation">Graceful Email Obfuscation</a> article from A List Apart takes it up a notch, with an htaccess rewrite and redirect. Could be worth setting up for a large site where you need to add email links quickly and easy.</li>
<li><a href="http://hivelogic.com/enkoder/form">Hivelogic Enkoder Form</a> - use their form to generate some javascript. Works great but relies on javascript to work.
</li><li><a href="http://www.addressmunger.com/">Addressmunger.com</a> - uses ASCII, JavaScript, and scrambling of letters in your email address.</li>
<li><a href="http://www.knechtology.com/stop-spam/email_encoder.html">K'nechtology Email Encryption</a> - encodes email addresses in to hexadecimal values. <strong>This isn't very secure</strong> as it would be extremely easy for a bot to decode hex.
</li></ul>]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2009/04/08/email-protection-using-css/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Using Drupal book source on Dreamhost</title>
		<link>http://23rdworld.com/2009/03/26/installing-using-drupal-book-source-on-dreamhost/</link>
		<comments>http://23rdworld.com/2009/03/26/installing-using-drupal-book-source-on-dreamhost/#comments</comments>
		<pubDate>Fri, 27 Mar 2009 03:58:00 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Content Management]]></category>
		<category><![CDATA[Hosting]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Web Apps]]></category>
		<category><![CDATA[application]]></category>
		<category><![CDATA[book]]></category>
		<category><![CDATA[configuration]]></category>
		<category><![CDATA[drupal]]></category>
		<category><![CDATA[install]]></category>
		<category><![CDATA[learning]]></category>
		<category><![CDATA[oreilly]]></category>
		<category><![CDATA[webhost]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=164</guid>
		<description><![CDATA[USE THIS INFORMATION AT YOUR OWN RISK. Any information found on this website is offered only as informational and includes no warranty, guarantees or support. The author claims no authority on any subject whatsoever. I just started reading the recently published book Using Drupal, 1st Edition, published by trusty ol&#8217; O&#8217;Reilly and written by a [...]]]></description>
			<content:encoded><![CDATA[<p class="warning"><strong>USE THIS INFORMATION AT YOUR OWN RISK.</strong>  Any information found on this website is offered only as informational and includes no warranty, guarantees or support. The author claims no authority on any subject whatsoever.</p>
<p><div class="wp-caption alignright" style="width: 250px"><a href="http://usingdrupal.com/"><img alt="Using Drupal, 1st Edition by OReilly" src="http://usingdrupal.com/sites/default/files/using_drupal_sidebar.png" title="Using Drupal, 1st Edition" width="240" height="315" /></a><p class="wp-caption-text">Using Drupal, 1st Edition by O&#39;Reilly</p></div>I just started reading the recently published book <a href="http://usingdrupal.com/">Using Drupal</a>, 1st Edition, published by trusty ol&#8217; <a href="http://oreilly.com/catalog/9780596515805/">O&#8217;Reilly</a> and written by a bunch of <a href="http://www.lullabot.com/" title="Mahalie's favorite Drupal consultants and trainers">Lullabots</a>.</p>
<p>So far the book is great, but the instructions on setting up a dev environment aren&#8217;t exactly crystal clear for those completely new to Drupal. I thought I&#8217;d help out the next geek that bothers to <acronym title="Google That Shit">GTS</acronym> to find pitfalls before starting.</p>
<p>First review the preface section 2.7 &#8216;Downloading Drupal&#8217;. If you&#8217;ve never installed Drupal before, or any web application on a web server before, it&#8217;s a good idea to check out Lullabot Addison Berry&#8217;s very easy to follow video, <a href="http://www.lullabot.com/videocasts/installing-drupal-6">Installing Drupal 6</a>.</p>
<p>These instructions are specific to the context of a shared hosting account on Dreamhost, but may work for your environment as well. Be sure to review <a href="http://oreilly.com/catalog/9780596515805/errata/">the book&#8217;s errata</a> &#8211; the &#8216;confirmed errata&#8217; will let you know about any code mistakes or problems with source discovered since the book was published. For troubleshooting help related to the books exercises and installation issues, review the <a href="http://forums.oreilly.com/category/39/Using-Drupal/">Using Drupal book forum</a>.</p>
<p class="warning"><strong>THESE INSTRUCTIONS MAY CAUSE YOUR DATAZ TO BE LOST.</strong>  In addition to setting up things quickly, these steps include how to quickly delete all the stuff in your database, without bothersome &#8216;back up your data first&#8217; steps. The idea is you are just creating a sandbox and nuking your install is no big deal.</p>
<p>Enough blab, let&#8217;s do this:</p>
<style type="text/css">
<!--
ul.this li {font-weight:bold;margin-top:6px;margin-bottom:0;}
ul.this li ul {margin-top:2px;}
ul.this li ul li {font-weight:normal;margin-top:2px;}
-->
</style>
<ul class="this">
<li>Create a subdomain for your dev environment like drupal.yourdomain.com
<ul>
<li>Dreamhost panel &gt; Domains &gt; Mandage Domains &gt; Add New Domain / Sub-Domain</li>
</ul>
</li>
<li>Create a new database (on a new or existing subdomain)
<ul>
<li>Goodies &gt; Manage MySQL, scroll to the bottom where it says &#8216;Create a new MySQL database:&#8217;</li>
<li>Enter something in all the fields:database name must be unique system wide so get creative, create a new hostname like mysql.drupal.yourdomain.com, you can use your own username but I created a special username and password that I&#8217;ll also be using for the admin user in the Drupal install (note: dev enviro, not recc&#8217;d for production), you might want to put something to remind you what this is later in the comment field like &#8220;Sandbox for Using Drupal Book&#8221;.</li>
<li>Write down all that DB stuff so you can use it later.</li>
<li>Wait a while for new database host name and/or new subdomain to propagate.</li>
</ul>
</li>
<li>Download the <a href="http://www.usingdrupal.com/source_code">latest source</a> from the book site.
<ul>
<li>Extract the zip somewhere you can find it, like your desktop.</li>
</ul>
</li>
<li>Change the database connection string in using_drupal_source\drupal\sites\default\default.settings.php
<ul>
<li>Open default.settings.php with your favorite text editor</li>
<li>change connection string stored in $db_url (line 92 at <acronym class="Time of Writing">TOW</acronym>) from mysql://username:password@localhost/databasename to something like <code>mysql://name:psswd@mysql.drupal.yourdomain.com/dbname</code></li>
</ul>
</li>
<li>Copy default.settings.php in the same folder and call it settings.php
<ul>
<li>There should now be 2 files in the default folder</li>
</ul>
</li>
<li>Save a backup copy of your default folder somewhere
<ul>
<li>I just copied the default folder and renamed it &#8216;_default&#8217;, or save somewhere on your hard drive, thumb drive, whatever&#8230;the point is, settings.php and default.settings.php that will soon live on your web server are going to change and you&#8217;re going to want these files again someday.</li>
</ul>
</li>
<li>Upload the contents of using_drupal_source\drupal to the root of your new subdomain</li>
<li>chmod /sites/default to 777
<ul>
<li>On you web server (via your FTP client) navigate to /drupal/sites/default</li>
<li>If you&#8217;re using FileZilla, right click (ctrl+click for macs) the default folder and select file permissions, this will allow you to enter the numeric value 777 or just check read/write/execute for all roles</li>
</ul>
</li>
<li>Open http://drupal.yourdomain.com</li>
</ul>
<p><div class="wp-caption aligncenter" style="width: 510px"><a href="http://farm4.static.flickr.com/3430/3386803484_ab8ee6a755_o.jpg"><img alt="Installation profile options on successful install" src="http://farm4.static.flickr.com/3430/3386803484_52ce422bc7.jpg" title="Using Drupal" width="500" height="471" /></a><p class="wp-caption-text">Installation profile options on successful install</p></div></p>
<p>You&#8217;ll be prompted to select an &#8216;Installation Profile&#8217;. The book source code includes scripts to automatically install a site with assets and modules used in their examples for you. If you are just starting Chapter 2. where they send you off to the Appendix for installation instruction, chose the last option &#8211; the generic/basic Drupal install.</p>
<p>Here&#8217;s how to &#8220;start over&#8221; so you can use a different installation profile. These steps will cause you to lose any data you entered in Drupal &#8211; you will end up with a brand new install and a chance to chose a diferent installation profile:</p>
<ul class="this">
<li>Nuke all your database tables</p>
<ul>
<li>Note I said &#8216;tables&#8217;, not the database.</li>
<li>Go to http://mysql.drupal.yourdomain.com (phpMyAdmin screen) and login</li>
<li>Select you Drupal database from the databases list at left (e.g. NOT information_schema)</li>
<li>Scroll to the bottom of tables listing page and select &#8216;Check All&#8217;, change the &#8216;With selected:&#8217; drop down to &#8216;Drop&#8217;.</li>
<li>You will see a screen asking if you really want to execute this command. Click &#8216;Yes&#8217;.</li>
</ul>
</li>
<li>CHMOD /sites/default to 777 again
<ul>
<li>On your web server, go to /sites/default</li>
<li>CHMOD default to 777 (again, because the previous install process modified the permissions) and be sure to check &#8216;recursive&#8217; (or use -R on commandline) because there&#8217;s new files in there and we need to blow everything in the default folder away.</li>
</ul>
</li>
<li>Delete everything in /sites/default</li>
<li>Put a clean copy of default.settings.php and settings.php in /sites/default
<ul>
<li>Remember that saved copy of default.settings.php and settings.php?</li>
</ul>
</li>
<li>Go to http://drupal.yourdomain.com/install.php and start all over again :)</li>
</ul>
<p><div class="wp-caption alignnone" style="width: 510px"><a href="http://farm4.static.flickr.com/3623/3388465649_ec71b0cc0d_o.jpg"><img alt="Bold moves in phpMyAdmin. Select all  drop." src="http://farm4.static.flickr.com/3623/3388465649_331c0e6b91.jpg" title="Dropping Drupal Database Tables" width="500" height="267" /></a><p class="wp-caption-text">Bold moves in phpMyAdmin. Select all &gt; drop. </p></div></p>
<p>I hope that was helpful for someone. I remember all to well not even knowing what chmod was and trying to write perl scripts, ouch! As you might guess, with as much time as I spend documenting when I should be doing book exercises I don&#8217;t really have time to offer support, but please let me know if anything I&#8217;ve written here needs to be corrected or elaborated on. Have fun in Drupal land!</p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2009/03/26/installing-using-drupal-book-source-on-dreamhost/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Installing Netbeans PHP IDE on Ubuntu</title>
		<link>http://23rdworld.com/2009/02/27/installing-netbeans-php-ide-on-ubuntu/</link>
		<comments>http://23rdworld.com/2009/02/27/installing-netbeans-php-ide-on-ubuntu/#comments</comments>
		<pubDate>Fri, 27 Feb 2009 23:55:12 +0000</pubDate>
		<dc:creator>Administrator</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[environment]]></category>
		<category><![CDATA[ide]]></category>
		<category><![CDATA[install]]></category>
		<category><![CDATA[lamp development]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=134</guid>
		<description><![CDATA[Nothing amazing going on, just a few tips that might save you some time: You need java runtime installed and working, prolly apt-cache search to make sure you&#8217;re putting in the most recent version (6 as of this writing) sudo apt-get update sudo apt-get install sun-java6-jre sun-java6-plugin sun-java6-font The netbeans in the repo is for [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/mahalie/154041190/" title="Lizard Steals Green Bean by mahalie, on Flickr"><img src="http://farm1.static.flickr.com/77/154041190_46fb3c5a83.jpg" width="500" height="375" alt="Lizard Steals Green Bean" /></a></p>
</p>
<p>Nothing amazing going on, just a few tips that might save you some time:</p>
<ul>
<li>You need java runtime installed and working, prolly apt-cache search to make<br />
sure you&#8217;re putting in the most recent version (6 as of this writing)</p>
<ul>
<li><code>sudo apt-get update</code></li>
<li><code>sudo apt-get install sun-java6-jre sun-java6-plugin sun-java6-font</code></li>
</ul>
</li>
<li>The netbeans in the repo is for the Java IDE, so don&#8217;t bother with apt-get</li>
<li>Download the install file here: <a href="http://www.netbeans.org/downloads/index.html">http://www.netbeans.org/downloads/index.html</a>
<ul>
<li>Be sure to pick the PHP bundle</li>
</ul>
</li>
<li>If clicking on the netbeans-x.x-ml-php-linux.sh file gives you an error or tries to open in gedit or something, right-click > <em>properties > permissions and check &#8216;allow executing file as a program&#8217;</em></li>
<li>Select Run (not &#8216;Run in Terminal&#8217;), running in terminal will throw some GTK errors</li>
</ul>
<p>Next you might want to head over to the <a href="http://www.netbeans.org/features/php/index.html">Netbeans website</a> and watch the intro vid and orient yourself to the plethora of PHP-centric features.</p>
<p>As fair newb to programming in PHP I can&#8217;t say I&#8217;m qualified to suggest an IDE. So why Netbeans? It&#8217;s free. It porvides syntactic and semantic code highlighting for PHP and debugging through Xdebug. Folks in my <a href="http://php.meetup.com/49/">Seattle PHP meetup group</a> who know a lot more about programming than I do seem to really like it, every time I go to install Eclipse I am daunted by the website, instructions and innumerable options. Finally, it was recommended in the recent Smashing Magazine article <a href="http://www.smashingmagazine.com/2009/02/11/the-big-php-ides-test-why-use-oneand-which-to-choose/">The Big PHP IDE Test: Why Use One And Which To Choose</a> (2009.02.11) so I stopped resisting.</p>
<p>Do you like it, recommend others over it?</p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2009/02/27/installing-netbeans-php-ide-on-ubuntu/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Google Doctype Screams &#8220;Fork ME!&#8221;</title>
		<link>http://23rdworld.com/2008/05/16/google-doctype-screams-fork-me/</link>
		<comments>http://23rdworld.com/2008/05/16/google-doctype-screams-fork-me/#comments</comments>
		<pubDate>Fri, 16 May 2008 23:27:29 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Opinions]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Web Standards]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[library]]></category>
		<category><![CDATA[reference]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[wiki]]></category>
		<category><![CDATA[xhtml]]></category>

		<guid isPermaLink="false">http://23rdworld.com/?p=127</guid>
		<description><![CDATA[The newly released Google Doctype is intended to be the Wikipedia of web design. There&#8217;s a video introduction on the landing page of Mark Pilgrim explaining what Google has been internally calling the the &#8220;Hitch Hikers Guide to the Web&#8221;. He&#8217;s been working on Google Doctype, said it is supposed to be the cross-platform alternative [...]]]></description>
			<content:encoded><![CDATA[<p>The newly released <a href="http://code.google.com/doctype/">Google Doctype</a> is intended to be the <a href="http://en.wikipedia.org">Wikipedia</a> of web design. There&#8217;s a video introduction on the <a href="http://code.google.com/doctype/">landing page</a> of <a href="http://diveintomark.org/">Mark Pilgrim</a> explaining what Google has been internally calling the the &#8220;Hitch Hikers Guide to the Web&#8221;. He&#8217;s been working on Google Doctype, said it is supposed to be the cross-platform alternative to MSDN. <a href="http://msdn.microsoft.com/en-us/default.aspx">MSDN</a>? I don&#8217;t know any web designers that rely on MSDN as the go-to spot for quality cross-platform client-side code! Maybe they&#8217;re targeting ASP.NET developers&#8230;and that could explain the <a href="http://code.google.com/docreader/#p(doctype)s(doctype)t(ArticleFormattingWithoutSemanticTags)">very un-wiki linear treestyle navigation</a>.</p>
<p><a href='http://code.google.com/doctype/'><img src="http://23rdworld.com/wp-content/uploads/2008/05/goog_doctype.jpg" alt="Google Doctype Screenshot" title="Google Doctype Screenshot" width="500" height="354" class="frame" /></a></p>
<h2>The Good</h2>
<p><a href="http://23rdworld.com/2007/03/30/how-to-make-your-mediawiki-private/">My own private wiki</a>, largely comprised of web development documentation for my own projects, code snippits and links to online resources, is invaluable to me &#8211; so the potential benefits of an open wiki of this nature is obvious and I&#8217;ve often wondered why there isn&#8217;t one (with critical mass) out there already. Certainly this project, or at least the idea of it, could be an invaluable tool to professional web designers and client-side developers. Some take-aways:</p>
<ul>
<li><strong>&#8220;Written by web developers, for web developers&#8221;</strong> and by that they mean client-side developers&#8230;most of the current content is specific to JavaScript DOM stuff and cross-browser CSS considerations. I think this fills a knowledge gap as a lot of CSS and even Ajax resources are designer-oriented (lacking meaty technical details) and many developer resources gloss over or ignore web standards or a lot of the details professional programmers take for granted (like finding a viewport or using javascript to manipulate classes)</li>
<li>It&#8217;s built on the Google Project framework so you can <strong>download the whole thing via SVN</strong>.</li>
<li><strong>The <a href="http://code.google.com/doctype/terms.html">licensing</a> is pretty unrestrictive</strong>, so you could SVN everything and put it up on an intranet statically or keep an off line copy, as was mentioned in the <a href="http://www.youtube.com/watch?v=MmUiKaHWjLI">intro video</a>.</li>
<li><strong>Discrete code snippets.</strong> Rather than a long tutorial with examples that are specific to a given situation, many of the HOWTOs are broken down into more abstracted uses. This style of documentation will help a lot when your stuck on specific area of a bigger project. Personally, I learn more this way &#8211; I like the big step-by-step tutorials but when I cut and paste a lot I don&#8217;t retain very much.</li>
</ul>
<h2>The Ugly</h2>
<p>Google suffers from chronic ugliness (IMHO) and this project is no exception. Don&#8217;t get me wrong, I&#8217;m GOOG fangirl all the way, but there always seems to be some basic user interface and user experience  problems with their apps/portals/projects/whatever. And here&#8217;s where I think Google Doctype has need of improvement:</p>
<ul>
<li><strong>No indication of off-site links.</strong> Not only does a link to MSDN look just like the internal links, there are links to other Google Code project without any indications that you&#8217;re leaving Google Doctype, in fact, the logo is still Google Code. Navigation is a little confusing in general.</li>
<li><strong>Lack of Style Guidelines.</strong> There is something to &#8220;just putting it out there&#8221; and I&#8217;m glad they did, but if a lot of people do start adding to this resource it could turn into quite a mess. It would have been ideal to have a written style established that would make sense for an open wiki. For example, statements like &#8220;generally, we recommend the following&#8230;&#8221; and &#8220;I&#8217;m not sure if this works on IE&#8221;. This type of thing would never fly on Wikipedia &#8211; now that the docs are open to the whole internets, such statements are ambiguous, lack authority and create a bad example that others are sure to follow.</li>
<li><strong>Not really a wiki.</strong> First there&#8217;s the linear tree/node navigation pane (which seems to collapse by itself and disappear or reappear for no apparent reason) . There is no discussion page (although there are comments, sort of like PHP.net), no page history (but you can manually add a free-form line to a log file, if you notice the option), there&#8217;s no obvious way to check to see what links to a page, the list goes on.</li>
<li><strong>Screaming &#8220;Fork Me&#8221;.</strong> <a href="http://www.codinghorror.com/blog/archives/001117.html">A fork may be inevitable</a>, and if a fork emerges using <a href="http://www.mediawiki.org/wiki/MediaWiki">MediaWiki</a> or any of a myriad of much more robust wiki platforms, I would be more likely to invest my time in that in spite of the Google mind share.</li>
</ul>
<h2>A Web Reference To Rule Them All</h2>
<p>When I first read that Google published a web design wiki I was thrilled. I tried to think of other, similar resources. There are some great blogs, lists and forums out there but I&#8217;ve yet to find the one web reference to rule them all. If you know of one, please let me know! In the meantime I&#8217;m looking for domains&#8230;webwiki.com is just a db error, webwiki.net is a half-baked attempt at a wiki version of the Million Dollar Homepage. Hrm. If I come up with a load of extra time and a brilliant idea I will let you know. In the mean time, here are a few of my favorite web coder sites:</p>
<ul>
<li><a href="http://www.w3.org/">W3C.org</a> &#8211; start at the top, right?</li>
<li><a href="http://htmldog.com/">HTML Dog</a> &#8211; very well organized reference and tutorials for CSS and (x)HTML</li>
<li><a href="http://www.alistapart.com/">A List Apart</a> &#8211; high quality articles published by those web standards freaks at <a href="http://www.happycog.com/">Happy Cog</a>.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2008/05/16/google-doctype-screams-fork-me/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Website Contact Pages</title>
		<link>http://23rdworld.com/2007/10/16/website-contact-pages/</link>
		<comments>http://23rdworld.com/2007/10/16/website-contact-pages/#comments</comments>
		<pubDate>Tue, 16 Oct 2007 22:12:54 +0000</pubDate>
		<dc:creator>mahalie</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Opinions]]></category>

		<guid isPermaLink="false">http://23rdworld.com/2007/10/16/website-contact-pages/</guid>
		<description><![CDATA[Oh the contact page. So boring, so obligatory. And not as simple as it may seem. I was hoping to jazz up the contact page at BuildCarbonNeutral.org with some sort of slick Ajax contact form. You see, I built the site in a really big hurry could spare not time for extras like protecting raw [...]]]></description>
			<content:encoded><![CDATA[<p><img src='http://23rdworld.com/wp-content/uploads/2007/10/contact.png' alt='Contact Page vs. Mailto Link' /></p>
<p>Oh the contact page. So boring, so obligatory. And not as simple as it may seem. I was hoping to jazz up the contact page at <a href="http://buildcarbonneutral.org/">BuildCarbonNeutral.org</a> with some sort of slick <a href="www.dustindiaz.com/ajax-contact-form/ ">Ajax contact form</a>. You see, I built the site in a really big hurry could spare not time for extras like protecting raw email addresses.  By the way, email address protection is not an extra, usually! It&#8217;s something I meant to rectify as soon as possible and sure enough, our general contact alias is already receiving spam. I thought I might take the email address off completely and post a contact form instead.</p>
<h2>The Problem with Contact Forms</h2>
<p>Even the best form is an obstacle. Users don&#8217;t like filling out forms and what&#8217;s more, you introduce an opportunity for error. Everyone commits a typo now and again, and what if someone sends you information you&#8217;d really like to follow up on but lo and behold, their email address bounces. Even if you add the extra email confirmation input (make the user enter it twice), there&#8217;s still the case of people using an incorrect email address just to harass you. But really it all comes down to user experience. <strong>Don&#8217;t make your user fill out a form if they don&#8217;t have to</strong>.</p>
<h2>The Simple and Sincere Mailto Link</h2>
<p>So it&#8217;s back to the good &#8216;ol mailto link for me. The added benefit is people can save the email address in their contact list of choice and can format the email and send attachments if they choose. An email link is more personal, less corporate. Of course you all know that any email address present in the code of a public website is crawlable by spambots. Therefore be sure to put measures in place to <a href="http://mahalie.com/notebook/2005/03/01/email-protection-using-css/">protect all email addresses</a>!</p>
<h2>There&#8217;s Always an Exception</h2>
<p>Sometimes you really should use a form. A common use for them is on high-traffic sites where they actually want to make it a little harder for users to get in contact. This approach is especially prevalent on sites that offer a product or service that results in a lot of support email and they want to encourage users to troubleshoot their own problem using existing documentation (FAQs, support forums, etc) before contacting the company/authors directly. Some sites don&#8217;t provide contact info at all for this reason. Chances are though, if your site is for a small business or is personal, you want to make it easier for people to contact you.</p>
]]></content:encoded>
			<wfw:commentRss>http://23rdworld.com/2007/10/16/website-contact-pages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

