<?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>BigSmoke &#187; WordPress</title>
	<atom:link href="http://blog.bigsmoke.us/tag/wordpress/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.bigsmoke.us</link>
	<description>Smokes your problems, coughs fresh air.</description>
	<lastBuildDate>Tue, 07 Sep 2010 09:38:54 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Aihato WordPress development notes</title>
		<link>http://blog.bigsmoke.us/2010/05/04/aihato-wordpress-dev-notes</link>
		<comments>http://blog.bigsmoke.us/2010/05/04/aihato-wordpress-dev-notes#comments</comments>
		<pubDate>Tue, 04 May 2010 16:04:56 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Aihato]]></category>
		<category><![CDATA[Make]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=1382</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m collaborating with <a href="http://www.ytec.nl/">YTEC</a> on a new website for <a href="http://www.aihato.nl/">Aihato</a>. I&#8217;ve picked WordPress to do most of the heavy lifting for this project. So far, I&#8217;ve spent most of my time on this project to get a good development environment in working order, with WordPress living in <a href="http://blog.bigsmoke.us/2009/01/30/separating-wordpress-factory-files-from-custom-files">its own directory</a> and some deployment recipes managed from a Makefile.</p>

<p>Now that I&#8217;m well-settled in the YTEC office with everything set-up and running, I hope to make some actual progress on this project next time that I&#8217;m here. <img src='http://blog.bigsmoke.us/wp-factory/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2010/05/04/aihato-wordpress-dev-notes/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>WordPress pretty pagination plugin</title>
		<link>http://blog.bigsmoke.us/2010/02/13/wp-page-numbers</link>
		<comments>http://blog.bigsmoke.us/2010/02/13/wp-page-numbers#comments</comments>
		<pubDate>Sat, 13 Feb 2010 20:00:08 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[pagination]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=1154</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>During the recent redesign of my blog, I decided that I wanted to have pretty pagination with numbers instead of the WordPress default <cite>Older/Newer Posts</cite> links. The plugin I decided to use was <a href="http://www.jenst.se/2008/03/29/wp-page-numbers">WP Page Numbers</a> by Jens Törnell.</p>

<p>This is how the pagination for page one of my home looks now:</p>

<p style="margin-left: 2em;"><img src="http://blog.bigsmoke.us/uploads/2010/02/wp-page-numbers-page1.png" alt="WP Page Numbers on page 1" title="WP Page Numbers on page 1" width="208" height="23" class="alignnone size-full wp-image-1242" /><p>

<p>For page six you can see more of what the plugin can do:</p>

<p style="margin-left: 2em;"><img src="http://blog.bigsmoke.us/uploads/2010/02/wp-page-numbers-page6.png" alt="WP Page Numbers on page 6" title="WP Page Numbers on page 6" width="314" height="23" class="alignnone size-full wp-image-1243" /></p>

<p>And finally…</p>

<p style="margin-left: 2em;"><img src="http://blog.bigsmoke.us/uploads/2010/02/wp-page-numbers-page20.png" alt="WP Page Numbers on page 20" title="WP Page Numbers on page 20" width="248" height="23" class="alignnone size-full wp-image-1244" /></p>

<p>Do I have twenty pages of posts already?</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2010/02/13/wp-page-numbers/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress admin menu layout problem</title>
		<link>http://blog.bigsmoke.us/2010/02/02/wordpress-admin-menu-layout-problem</link>
		<comments>http://blog.bigsmoke.us/2010/02/02/wordpress-admin-menu-layout-problem#comments</comments>
		<pubDate>Tue, 02 Feb 2010 09:33:37 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[blog.bigsmoke.us]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=1159</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>In this WordPress installation I have a problem with my admin menu. If I add <q><tt>clear: left;</tt></q> to the rules for <tt>#adminmenu li.menu-top</tt> it appears to be fixed.</p>

<div id="attachment_1160" class="wp-caption alignnone" style="width: 310px"><a href="http://blog.bigsmoke.us/uploads/2010/02/wordpress-dashboard-with-borked-menu.png"><img src="http://blog.bigsmoke.us/uploads/2010/02/wordpress-dashboard-with-borked-menu-300x186.png" alt="WordPress dashboard with borked menu" title="WordPress dashboard with borked menu" width="300" height="186" class="size-medium wp-image-1160" /></a><p class="wp-caption-text">WordPress dashboard with borked menu</p></div>

<div id="attachment_1161" class="wp-caption alignnone" style="width: 310px"><a href="http://blog.bigsmoke.us/uploads/2010/02/wordpress-dashboad-with-unborked-menu.png"><img src="http://blog.bigsmoke.us/uploads/2010/02/wordpress-dashboad-with-unborked-menu-300x186.png" alt="WordPress dashboard with menu CSS fixed" title="WordPress dashboard with menu CSS fixed" width="300" height="186" class="size-medium wp-image-1161" /></a><p class="wp-caption-text">WordPress dashboard with menu CSS fixed</p></div>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2010/02/02/wordpress-admin-menu-layout-problem/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>AJAX comment preview for WordPress</title>
		<link>http://blog.bigsmoke.us/2010/01/30/ajax-comment-preview-for-wordpress</link>
		<comments>http://blog.bigsmoke.us/2010/01/30/ajax-comment-preview-for-wordpress#comments</comments>
		<pubDate>Sat, 30 Jan 2010 01:06:20 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=1056</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>Yesterday night, after <a href="http://blog.bigsmoke.us/2010/01/30/svn-merge-tracking">mucking around</a> with my Subversion repo for this blog for way too long, I finally stopped annoying the designer of my new theme and uploaded it, one and a half year after the <a href="http://blog.bigsmoke.us/2008/07/13/new-theme">last major redesign</a>. Anyway, while implementing the new design for the comment list , I decided it was time to have comment previews.</p>

<p>At some time, I had already installed (but not activated) the <a href="http://wordpress.org/extend/plugins/live-comment-preview/">Live Comment Preview</a> plugin, but that&#8217;s client-side only. I removed it because I want the comment to show as it would after being piped through all the hooks and filters that comments normally get piped through. Enter the <a href="http://wordpress.org/extend/plugins/ajax-comment-preview/">AJAX Comment Preview</a> plugin:</p>

<blockquote>
<p>Other preview plugins don&#8217;t know what sort of changes WordPress will make to a visitor&#8217;s comment, but this plugin uses AJAX and other buzzwords to send each previewed comment through WordPress&#8217; inner voodoo.</p>
<p>The result? With the click of a button, your site&#8217;s visitors can preview their comments exactly as they will appear when they submit them for realies.</p>
</blockquote>

<p>You just gotta love their phrasing. <img src='http://blog.bigsmoke.us/wp-factory/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  Enjoy the new preview feature.</p>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2010/01/30/ajax-comment-preview-for-wordpress/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tracking WordPress in a Subversion vendor branch</title>
		<link>http://blog.bigsmoke.us/2009/09/20/svn-vendor-branches-wordpress</link>
		<comments>http://blog.bigsmoke.us/2009/09/20/svn-vendor-branches-wordpress#comments</comments>
		<pubDate>Sun, 20 Sep 2009 11:03:34 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[CLI]]></category>
		<category><![CDATA[Subversion]]></category>
		<category><![CDATA[svn]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=824</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>Two months prior to writing a <a href="http://blog.bigsmoke.us/2009/07/20/svn-vendor-branches">script to upgrade MediaWiki installations using Subversion vendor branches</a>, I wrote something similar for WordPress. It&#8217;s a little bit more limited and should really incorporate some of the improvements made for the MediaWiki version, but it worked fine so far:</p>

<pre class="bash">cat upgrade-wordpress.sh 
<span style="color: #808080; font-style: italic;">#!/bin/bash</span>
&nbsp;
<span style="color: #0000ff;">svn_repo_url=</span>file:///var/svn/blog.omega-research.org/vendor/wordpress/
<span style="color: #0000ff;">last_version=</span>$<span style="color: #cc66cc;">1</span>
<span style="color: #0000ff;">new_version=</span>$<span style="color: #cc66cc;">2</span>
&nbsp;
<span style="color: #0000ff;">tmp_dir=</span>`mktemp -d`
<span style="color: #000066;">cd</span> <span style="color: #0000ff;">$tmp_dir</span>
&nbsp;
<span style="color: #b1b100;">for</span> version <span style="color: #b1b100;">in</span> $*; <span style="color: #b1b100;">do</span>
    <span style="color: #000066;">echo</span> <span style="color: #ff0000;">&quot;Downloading and extracting WordPress version $version...&quot;</span>
&nbsp;
    <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#91;</span> -z `svn ls <span style="color: #0000ff;">$svn_repo_url</span>|grep <span style="color: #0000ff;">$version</span>` <span style="color: #66cc66;">&#93;</span>; <span style="color: #b1b100;">then</span>
        <span style="color: #0000ff;">branch=</span>`<span style="color: #000066;">echo</span> <span style="color: #0000ff;">$version</span> |sed -e <span style="color: #ff0000;">'s/<span style="color: #000099; font-weight: bold;">\.</span>[0-9]<span style="color: #000099; font-weight: bold;">\+</span>$//'</span>`
        <span style="color: #0000ff;">archive_file=</span><span style="color: #ff0000;">&quot;wordpress-$version.tar.gz&quot;</span>
        <span style="color: #0000ff;">md5_file=</span><span style="color: #ff0000;">&quot;wordpress-$version.md5&quot;</span>
&nbsp;
        wget <span style="color: #ff0000;">&quot;http://wordpress.org/$md5_file&quot;</span>
        wget <span style="color: #ff0000;">&quot;http://wordpress.org/$archive_file&quot;</span>
&nbsp;
        <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#91;</span> `md5sum <span style="color: #0000ff;">$archive_file</span> |cut -f <span style="color: #cc66cc;">1</span> -d <span style="color: #ff0000;">' '</span>` != `cat <span style="color: #0000ff;">$md5_file</span>` <span style="color: #66cc66;">&#93;</span>; <span style="color: #b1b100;">then</span>
            <span style="color: #000066;">echo</span> <span style="color: #ff0000;">&quot;MD5 sum did not match!&quot;</span> &gt;&amp;<span style="color: #cc66cc;">2</span>
            <span style="color: #000066;">exit</span> <span style="color: #cc66cc;">1</span>
        <span style="color: #b1b100;">fi</span>
&nbsp;
        tar --extract --ungzip --transform <span style="color: #ff0000;">&quot;s/^wordpress/$version/&quot;</span> --file <span style="color: #0000ff;">$archive_file</span>
        svn_load_dirs.pl <span style="color: #0000ff;">$svn_repo_url</span> -t <span style="color: #0000ff;">$version</span> current <span style="color: #0000ff;">$version</span>
    <span style="color: #b1b100;">fi</span>
<span style="color: #b1b100;">done</span>
&nbsp;
<span style="color: #000066;">cd</span> -
svn merge <span style="color: #ff0000;">&quot;$svn_repo_url$last_version&quot;</span> <span style="color: #ff0000;">&quot;$svn_repo_url$new_version&quot;</span> .</pre>

<p>I&#8217;m actually planning to make both scripts a little bit more generic (in the sense that <tt>svn_repo_url</tt> becomes an external param) and to track future changes to them using GitHub&#8217;s <a href="http://gist.github.com/">Gist</a>. (How ironic is that, tracking an script for Subversion using Git?)</p>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2009/09/20/svn-vendor-branches-wordpress/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Complete WordPress Atom feed: an XSLT transformation</title>
		<link>http://blog.bigsmoke.us/2009/06/10/nopaging-wordpress-atom-feed-with-xslt</link>
		<comments>http://blog.bigsmoke.us/2009/06/10/nopaging-wordpress-atom-feed-with-xslt#comments</comments>
		<pubDate>Wed, 10 Jun 2009 13:51:27 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Atom]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[www.halfgaar.net]]></category>
		<category><![CDATA[XSLT]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=587</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>Previously, I tried obtaining a <a href="http://blog.bigsmoke.us/2009/02/16/wordpress-feed-pagination">full Atom feed without pagination</a> from WordPress. I didn&#8217;t succeed, so I ended up writing an XSL transformation which merges all the pages of this Atom feed into one valid Atom XML stream.</p>

<h2>The transformation: <tt>wordpress-full-atom-feed.xsl</tt></h2>

<pre class="xml"><span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;?xml</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span> <span style="color: #000066;">encoding</span>=<span style="color: #ff0000;">&quot;UTF-8&quot;</span><span style="font-weight: bold; color: black;">?&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:transform <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span>
xmlns:<span style="color: #000066;">xsl</span>=<span style="color: #ff0000;">&quot;http://www.w3.org/1999/XSL/Transform&quot;</span>
xmlns:<span style="color: #000066;">atom</span>=<span style="color: #ff0000;">&quot;http://www.w3.org/2005/Atom&quot;</span>
xmlns:<span style="color: #000066;">thr</span>=<span style="color: #ff0000;">&quot;http://purl.org/syndication/thread/1.0&quot;</span>
<span style="color: #000066;">xmlns</span>=<span style="color: #ff0000;">&quot;http://www.w3.org/2005/Atom&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:param <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;base_url&quot;</span> <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;atom:feed/atom:link[@rel='self']/@href&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
&nbsp;
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:template <span style="color: #000066;">match</span>=<span style="color: #ff0000;">&quot;/&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:apply-templates <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;node()&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:template<span style="font-weight: bold; color: black;">&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:template <span style="color: #000066;">match</span>=<span style="color: #ff0000;">&quot;*&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:element <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;{name(.)}&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:apply-templates <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;node()&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:element<span style="font-weight: bold; color: black;">&gt;</span></span>
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:template<span style="font-weight: bold; color: black;">&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:template <span style="color: #000066;">match</span>=<span style="color: #ff0000;">&quot;@*|node()&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:copy-of <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;.&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:template<span style="font-weight: bold; color: black;">&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:template <span style="color: #000066;">match</span>=<span style="color: #ff0000;">&quot;atom:feed&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;feed<span style="font-weight: bold; color: black;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:apply-templates <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;@*|node()&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
&nbsp;
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:call-template <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;process_feed_page&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
      <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:with-param <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;page&quot;</span> <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;number('2')&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:call-template<span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/feed<span style="font-weight: bold; color: black;">&gt;</span></span></span>
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:template<span style="font-weight: bold; color: black;">&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:template <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;process_feed_page&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:param <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;page&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
&nbsp;
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:variable <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;page_doc&quot;</span> <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;document(concat($base_url, '?paged=', $page))&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
&nbsp;
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:if <span style="color: #000066;">test</span>=<span style="color: #ff0000;">&quot;$page_doc/atom:feed/atom:entry&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:apply-templates <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;$page_doc/atom:feed/atom:entry&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
  
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:call-template <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;process_feed_page&quot;</span><span style="font-weight: bold; color: black;">&gt;</span></span>
      <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;xsl</span>:with-param <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;page&quot;</span> <span style="color: #000066;">select</span>=<span style="color: #ff0000;">&quot;$page + 1&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span>
    <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:call-template<span style="font-weight: bold; color: black;">&gt;</span></span>
  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:if<span style="font-weight: bold; color: black;">&gt;</span></span>
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:template<span style="font-weight: bold; color: black;">&gt;</span></span>
&nbsp;
<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/xsl</span>:transform<span style="font-weight: bold; color: black;">&gt;</span></span></pre>

<p>The transformation works by processing the <tt>atom:feed</tt> element. Before closing that, the <tt>process_feed_page</tt> template is called. This template tries to open the next page and process all <tt>atom:entry</tt> elements in there. Then it tries to recurse to the next page.</p>

<p>The next page&#8217;s URL can be guessed because this is the normal feed URL with <q><tt>?paged=[pagenum]</tt></q> appended to it. The feed URL can be found because WordPress adds it to the feed:</p>

<pre class="xml"><span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;link</span> <span style="color: #000066;">rel</span>=<span style="color: #ff0000;">&quot;self&quot;</span> <span style="color: #000066;">type</span>=<span style="color: #ff0000;">&quot;application/atom+xml&quot;</span> <span style="color: #000066;">href</span>=<span style="color: #ff0000;">&quot;http://blog.bigsmoke.us/author/halfgaar/feed/atom&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span></pre>

<p>For very old WordPress versions this doesn&#8217;t work, because the <tt>paged</tt> parameter isn&#8217;t supported there. Also, older versions might require you to supply the <tt>$base_url</tt> param to the XSLT processor, because the <tt>rel='self'</tt> link is incorrectly set to the URL of the default feed within all other feeds (such as the author feed or the tag feed).</p>

<h2>Invocation</h2>

<p>Invocation is simple. I use <a href="http://xmlsoft.org/XSLT/">libxslt</a>&#8216;s xsltproc:</p>

<pre>xsltproc wordpress-full-atom-feed.xsl http://blog.bigsmoke.us/author/halfgaar/feed/atom</pre>

<p>That&#8217;s it. You end up with a full feed as if there never was any pagination to begin with; it almost looks as if WordPress <em>does</em> support the <em>nopaging</em> option for feeds.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2009/06/10/nopaging-wordpress-atom-feed-with-xslt/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Finding a decent GeSHi plugin for WordPress</title>
		<link>http://blog.bigsmoke.us/2009/04/13/wordpress-geshi-plugin</link>
		<comments>http://blog.bigsmoke.us/2009/04/13/wordpress-geshi-plugin#comments</comments>
		<pubDate>Mon, 13 Apr 2009 14:03:59 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[BigSmoke.US]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[BBCode]]></category>
		<category><![CDATA[GeSHi]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=310</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>I like <a href="http://qbnz.com/highlighter/">GeSHi</a> (enough even to have written a <a href="http://geshi.svn.sourceforge.net/viewvc/geshi/trunk/geshi-1.0.X/src/geshi/bnf.php">language file</a> for it). For ages now, I&#8217;ve used a WordPress plugin by Dan Peverill. But for as long as I&#8217;ve been using the plugin, I&#8217;ve been looking to get rid of it.</p>

<p>Dan Peverill&#8217;s GeSHI plugin sucks for two reasons:</p>
<ol>
  <li>It&#8217;s no longer being maintained. It doesn&#8217;t even seem to justify a page on Dan&#8217;s website anymore (for which reason I&#8217;m not going to give him any link-juice).</li>
  <li>It breaks HTML. With the plugin enabled I can no longer use the <tt>&lt;code&gt;</tt> tag to mark in-line elements as being <em>code</em>. Frankly, this is annoying and I find myself typing <tt>&lt;tt&gt;</tt> often when I mean <tt>&lt;code&gt;</tt>.</li>
</ol>

<p>A search for <a href="http://wordpress.org/extend/plugins/tags/geshi">WordPress plugins tagged <q>GeSHi</q></a> reveals a number of results:  <a href="http://wordpress.org/extend/plugins/sniplets/">Sniplets</a>, <a href="http://wordpress.org/extend/plugins/codecolorer/">CodeColorer</a>, <a href="http://wordpress.org/extend/plugins/devformatter/">Developer Formatter</a>, and <a href="http://wordpress.org/extend/plugins/wp-synhighlight/">WP-SynHighlight</a>. <a href="http://wordpress.org/extend/plugins/wp-syntax/">WP-Syntax</a> is a plugin that is missing from the tag search.</p>

<p><strong>Sniplets</strong> seems much too generic to my taste. I just want a GeSHi highlighter, period.</p>

<p><strong>CodeColorer</strong> says it does what I want, but if I ever want to use the TinyMCE editor again, I won&#8217;t be able to with this plugin. Shouldn&#8217;t be too much of a problem, but still&#8230;</p>

<p><strong>Developer Formatter</strong> is very thoroughly written and even sports a TinyMCE plug-in for copying/pasting the code. It is pretty big, though, and, as a rule, I tend to avoid plug-ins that complicate the database schema. I also don&#8217;t really see how these extra tables are an advantage feature-wise.</p>

<p><strong>WP-SynHighlight</strong> uses a custom BBCode-style tag, <tt>&#x5B;codesyntax]</tt> I like this (if you&#8217;re going to use pointy brackets, at least keep out of the HTML namespace), though I don&#8217;t like the attempt at a generic name; what&#8217;s wrong with calling the tag <tt>[geshi]</tt>? Seriously&#8230; I&#8217;m sure I&#8217;m going to forget this name billions of times if I&#8217;ll use this plug-in.</p>

<p><strong>WP-Syntax</strong> uses the <tt>&lt;pre&gt;</tt> tag with a few custom attributes. This at least is better than the <strong>officially inline</strong> <tt>&lt;code&gt;</tt> tag that my current plugin uses, because most of the time that I&#8217;d use a <tt>&lt;pre&gt;</tt> tag I really do want syntax highlighting. Just wondering: will it also allow my to use it normally for that other rare occasion? Sadly, the plugin <em>will</em> doubtlessly wreak havoc with the visual (TinyMCE) editor.</p>

<p>So, which plugin will I choose? I am somehow inclined to want a plugin that <em>can</em> play nice with the visual editor because I keep telling myself how much nicer it would be to switch to the visual editor for all my posting. (That this will be difficult because I disabled WP&#8217;s &#8216;<tt>wpautop</tt>&#8216; filter to rid myself of its eagerness is a story for some later time.) This requirement rules out CodeColorer and WP-Syntax.</p>

<p>That leaves Developer Formatter and WP-SynHighlight. Both seem to fit my purpose. Developer Formatter sports a nice TinyMCE plugin for inserting code, but I don&#8217;t think that switching to TinyMCE will suddenly and unexpectedly make me afraid of typing. Besides, I really don&#8217;t want the extra tables in my database without a very good reason, so, for now, I will try <a href="http://wordpress.org/extend/plugins/wp-synhighlight/">WP-SynHighlight</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2009/04/13/wordpress-geshi-plugin/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>WordPress feed pagination</title>
		<link>http://blog.bigsmoke.us/2009/02/16/wordpress-feed-pagination</link>
		<comments>http://blog.bigsmoke.us/2009/02/16/wordpress-feed-pagination#comments</comments>
		<pubDate>Mon, 16 Feb 2009 21:52:37 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Atom]]></category>
		<category><![CDATA[feed]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[URL]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=399</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>Wiebe uses his <a href="/author/halfgaar/feed/atom">author Atom feed</a> to generate a list of his blog posts here <a href="http://www.halfgaar.net/articles">on his own website</a>. WordPress feeds only display the latest 10 entries. He has written 16 so far. What he needs is a feed with <strong>all</strong> his entries.</p>

<p>First, I tried if pagination works for feeds. Appending &#8220;<tt>/page/2</tt>&#8221; (as is used an non-feed lists) to a feed URL gives a 404 so I was kind of stuck there. Four days ago, after Googling for some time, unable to find a solution anywhere, I <a href="http://wordpress.org/support/topic/242847">asked</a> on the forum. Still no answer today so I tried to find out which parameters WordPress accepts in the <tt>QUERY_STRING</tt>. The WordPress Codex does explain <a href="http://codex.wordpress.org/Query_Overview">how queries are handled</a> but not which parameters are accepted.</p>

<p>Digging into <tt>wp-includes/query.php</tt>, with much trial and error, I found out that I can append <q><tt>?paged=2</tt></q> to the URL to get the next page. At least I got that sorted then. There are a number of much more promising parameters supported by <tt>get_posts()</tt>, but these don&#8217;t seem to be parsed by <tt>parse_query()</tt>. Next time, I&#8217;d like to find out how how to use two of these: <tt>nopaging</tt> and <tt>posts_per_page</tt>.</p>

<p>Wiebe could complete his list by merging together all the pages of the feed, but I&#8217;d much prefer to find a relatively painless method to produce a feed with an unlimited number of posts.</p>

<h2>Notes</h2>

<ul>
<li>http://codex.wordpress.org/Query_Overview</li>
<li>http://codex.wordpress.org/Function_Reference/WP_Query</li>
<li>http://codex.wordpress.org/Template_Tags/query_posts</li>
</ul>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2009/02/16/wordpress-feed-pagination/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>WordPress 2.7 administration panel changes</title>
		<link>http://blog.bigsmoke.us/2009/02/07/wordpress-admin-gui-changes</link>
		<comments>http://blog.bigsmoke.us/2009/02/07/wordpress-admin-gui-changes#comments</comments>
		<pubDate>Sat, 07 Feb 2009 18:24:00 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=379</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>I really, really liked the new style of administration panel that was <a href="http://wordpress.org/development/2008/03/wordpress-25-rc2/">introduced</a> in WordPress 2.5. In all the time since I&#8217;ve upgraded (and increasingly with every update), I&#8217;ve started to like it more and more. I hadn&#8217;t thought it possible but everything just felt at <em>exactly</em> the right place, while before 2.5, the whole always felt like it had been thrown together by a blind child. Had I written it myself, it would have at least felt as being thrown together by an adult (chimpanzee).</p>

<p>So I was happy. And I&#8217;m still happy. Yet, this time, it does take getting used to it. That&#8217;s a bit sad. Probably, it&#8217;ll be for all the better, with more space for more (plug-in) features and everything. Still&#8230; I <em>will</em> miss the <q>old</q> interface.</p>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2009/02/07/wordpress-admin-gui-changes/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Untangling WordPress&#8217; core files from your local customizations</title>
		<link>http://blog.bigsmoke.us/2009/01/30/separating-wordpress-factory-files-from-custom-files</link>
		<comments>http://blog.bigsmoke.us/2009/01/30/separating-wordpress-factory-files-from-custom-files#comments</comments>
		<pubDate>Fri, 30 Jan 2009 12:38:13 +0000</pubDate>
		<dc:creator>Rowan Rodrik</dc:creator>
				<category><![CDATA[BigSmoke.US]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[mod_rewrite]]></category>
		<category><![CDATA[Subversion]]></category>
		<category><![CDATA[svn]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://blog.bigsmoke.us/?p=113</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>Since <a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">version 2.6</a>, WordPress can be <a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">installed in its own directory</a>, separate from your customizations and everthing. Needless to say, this makes upgrading a whole lot easier.</p>

<p>If, in the pre-2.6 days, you wanted to fetch your WordPress updates through SVN, the docs would <a href="http://codex.wordpress.org/Installing/Updating_WordPress_with_Subversion">advice</a> you to do an <tt>svn checkout</tt> from the official WP SVN repo in your working dir and then do an <tt>svn update</tt> whenever you want to update WordPress. This works because <tt>svn update</tt> leaves local modifcations alone. However, this means that you&#8217;ll be unable to commit your local changes (configuration, themes, plugins, etc.) if you choose this route.</p>

<p>I used my own subversion repository for my blogs and thus had to upgrade the old fashioned way with each release (although I prefer <a href="http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch">diff/patch over rm/cp</a>). (I could have used <a href="http://svnbook.red-bean.com/en/1.5/svn.advanced.vendorbr.html">vendor branches</a>, but, clearly, I hadn&#8217;t thought about that at the time.) This was pretty much a royal pain in the ass, so I was glad when I could move WordPress into a separate directory with its 2.6 release.</p>

<p>This process consisted of removing everything except <tt>wp-content/</tt>, <tt>wp-config.php</tt>, <tt>.htaccess</tt>. (I also kept <tt>robots.txt</tt>, <tt>favicon.ico</tt> and some other personal files.) Then, I added the current WordPress release as an <tt>svn:external</tt>.</p>

<pre>
svn propset svn:externals 'wp-factory http://svn.automattic.com/wordpress/tags/2.6.1' .
</pre>

<h2><kbd>.htaccess</kbd> changes</h2>

<p>In the WordPress codex, it is then <a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">suggested</a> to copy <tt>index.php</tt> to the root dir and to change it to require <tt>wp-factory/wp-blog-header.php</tt> instead of <tt>./wp-blog-header.php</tt>. I preferred adding some mod_rewrite voodoo of my own to <tt>.htaccess</tt>, so I did:</p>

<pre class="php">&lt;IfModule mod_rewrite.c&gt;
<span style="color: #808080; font-style: italic;"># This way I don't need directory indices</span>
RewriteRule ^$ /wp-factory/index.php <span style="color: #66cc66;">&#91;</span>L<span style="color: #66cc66;">&#93;</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># This way WordPress can manage its own block without doing any harm</span>
RewriteRule ^index.php /wp-factory/index.php <span style="color: #66cc66;">&#91;</span>L<span style="color: #66cc66;">&#93;</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># Allow easier access to /wp-factory/wp-admin/</span>
RewriteRule ^wp-admin http:<span style="color: #808080; font-style: italic;">//%{HTTP_HOST}/wp-factory/wp-admin/ [L,R=301]</span>
&lt;/IfModule&gt;</pre>

<p>The middle rule performs most of the magic. It redirects all the requests to <tt>/index.php</tt> to the factory default <tt>index.php</tt>. This means that I can let WordPress pretend that <tt>index.php</tt> does live in the root, so I don&#8217;t have to modify the rewrite rules that are managed by WordPress itself:</p>

<pre class="php"><span style="color: #808080; font-style: italic;"># BEGIN WordPress</span>
&lt;IfModule mod_rewrite.c&gt;
RewriteEngine On
RewriteBase /
RewriteCond %<span style="color: #66cc66;">&#123;</span>REQUEST_FILENAME<span style="color: #66cc66;">&#125;</span> !-f
RewriteCond %<span style="color: #66cc66;">&#123;</span>REQUEST_FILENAME<span style="color: #66cc66;">&#125;</span> !-d
RewriteRule . /index.php <span style="color: #66cc66;">&#91;</span>L<span style="color: #66cc66;">&#93;</span>
&lt;/IfModule&gt;
<span style="color: #808080; font-style: italic;"># END WordPress </span></pre>

<h2><tt>wp-config.php</tt> changes</h2>

<p>In <cite><a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">Giving WordPress Its Own Directory</a></cite> in the WordPress Codex, it is suggested to change the &#8220;<tt>siteurl</tt>&#8221; and &#8220;<tt>home</tt>&#8221; options through the administration panel. In my case they would have to be changed to &#8220;<tt>http://blog.bigsmoke.us/wp-factory/</tt>&#8221; and <tt>http://blog.bigsmoke.us</tt>&#8220;. I couldn&#8217;t do this because I override these with <tt>WP_SITEURL</tt> and <tt>WP_HOME</tt> in my <tt>wp-config.php</tt>. This is because I <a href="http://blog.bigsmoke.us/2008/07/12/separate-development-environment-for-wordpress">configured WordPress to support a development environment separate from the live production environment</a>.</p>

<p>Ignoring the customizations for my development environment, these are the relevant settings in <tt>wp-config.php</tt>:</p>

<pre class="php"><a href="http://www.php.net/define"><span style="color: #000066;">define</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'WP_HOME'</span>, <span style="color: #ff0000;">'http://blog.bigsmoke.us'</span><span style="color: #66cc66;">&#41;</span>;
<a href="http://www.php.net/define"><span style="color: #000066;">define</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'WP_SITEURL'</span>, WP_HOME . <span style="color: #ff0000;">'/wp-factory'</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
<a href="http://www.php.net/define"><span style="color: #000066;">define</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'WP_CONTENT_DIR'</span>, <a href="http://www.php.net/dirname"><span style="color: #000066;">dirname</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">__FILE__</span><span style="color: #66cc66;">&#41;</span> . <span style="color: #ff0000;">'/wp-content'</span><span style="color: #66cc66;">&#41;</span>;
<a href="http://www.php.net/define"><span style="color: #000066;">define</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'WP_CONTENT_URL'</span>, WP_HOME . <span style="color: #ff0000;">'/wp-content'</span><span style="color: #66cc66;">&#41;</span>;</pre>

<p>BTW: I really like it how WordPress disables the form controls for <tt>siteurl</tt> and <tt>home</tt> when you override these settings in <tt>wp-config.php</tt>. Kudos for that, devs!</p>

<h2>Next time: git</h2>

<p>In the end, this is all quite a bit of pain to compensate for what is essentially a version management problem. That&#8217;s why, on my newer projects, I&#8217;m now using git which makes forking and tracking an upstream repo absolutely trivial. <img src='http://blog.bigsmoke.us/wp-factory/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>

<h2>A few references</h2>

<ul>
<li><cite><a href="http://codex.wordpress.org/Editing_wp-config.php">Editing wp-config.php</a></cite> in the <cite>WordPress Codex</cite></li>
<li><cite><a href="http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory">
Giving WordPress its Own Directory While Leaving Your Blog in the Root Directory</a></cite> in the <cite>WordPress Codex</cite></li>
<li><cite><a href="http://svnbook.red-bean.com/en/1.5/svn.advanced.vendorbr.html">Vendor branches</a></cite> in the <cite>Subversion Redbook</cite></li>
</ul>]]></content:encoded>
			<wfw:commentRss>http://blog.bigsmoke.us/2009/01/30/separating-wordpress-factory-files-from-custom-files/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
