<?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>Ronald! &#187; wordpress</title>
	<atom:link href="http://www.rchu.nl/tag/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.rchu.nl</link>
	<description>My own little corner of the world wide web</description>
	<lastBuildDate>Mon, 06 Feb 2012 20:00:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Integrating WordPress with Facebook</title>
		<link>http://www.rchu.nl/2010/11/integrating-wordpress-with-facebook/</link>
		<comments>http://www.rchu.nl/2010/11/integrating-wordpress-with-facebook/#comments</comments>
		<pubDate>Sun, 14 Nov 2010 12:34:31 +0000</pubDate>
		<dc:creator>ronald</dc:creator>
				<category><![CDATA[Computing]]></category>
		<category><![CDATA[Website]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.rchu.nl/?p=653</guid>
		<description><![CDATA[Update: I now use a different plugin because I want people to be able to write something on their wall when liking a post. I just installed a plugin that adds open graph data and a like box to each page on this site. I like to have it configured this way; specifying meta data <a href='http://www.rchu.nl/2010/11/integrating-wordpress-with-facebook/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Update: I now use a different plugin because I want people to be able to write something on their wall when liking a post.</p>
<p>I just installed a <a href="http://wordpress.org/extend/plugins/facebook-open-graph-widget/other_notes/">plugin</a> that adds <a href="http://developers.facebook.com/docs/opengraph">open graph</a> data and a like box to each page on this site. I like to have it configured this way; specifying meta data in the header my pages, it all feels semantic web-ish.</p>
<p>Of course I needed to make some changes in the code to make it all work.<br />
<span id="more-653"></span></p>
<p>First of all the layout elements in the sidebar weren&#8217;t present in the HTML and after a quick inspection of the plugin source code I found that it simply was trying to read that information from a undefined variable <em>$args</em>. Google quickly led me to the <a href="http://codex.wordpress.org/Widgets_API#Display_Sidebar_on_Theme">widgets API page</a> where I found out it is simply the first parameter passed to that method:</p>
<p>
<pre class="brush: php; first-line: 210; gutter: true; highlight: [212]; light: false;">&lt;br /&gt;
}&lt;br /&gt;
// widget control functions&lt;br /&gt;
function kpg_fb_like_data_widget($args) {&lt;br /&gt;
 // show the widget&lt;br /&gt;
 // need to just put the iframe here&lt;br /&gt;
</pre>
</p>
<p>Next up was the description of the page. Because I want all posts to be seperate entities (as opposed to the entire site as one entity) I do not want the description of the page to be the description of the blog. I added a line setting the description simply to the stripped content of the post:</p>
<p>
<pre class="brush: php; first-line: 24; gutter: true; highlight: [27]; light: false;">&lt;br /&gt;
        global $post;&lt;br /&gt;
        if (!empty($post)) {&lt;br /&gt;
                $fbtitle=$post-&gt;post_title;&lt;br /&gt;
                $fbdesc=htmlspecialchars(strip_tags($post-&gt;post_content));&lt;br /&gt;
        }&lt;br /&gt;
</pre></p>
<p class='fb-like'><iframe src='http://www.facebook.com/plugins/like.php?href=http://www.rchu.nl/2010/11/integrating-wordpress-with-facebook/&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light' scrolling='no' frameborder='0' allowTransparency='true' style='border:none; overflow:hidden; width:450px; height:65px'></iframe></p>]]></content:encoded>
			<wfw:commentRss>http://www.rchu.nl/2010/11/integrating-wordpress-with-facebook/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Some nice layout changes</title>
		<link>http://www.rchu.nl/2010/04/some-nice-layout-changes/</link>
		<comments>http://www.rchu.nl/2010/04/some-nice-layout-changes/#comments</comments>
		<pubDate>Mon, 05 Apr 2010 18:27:36 +0000</pubDate>
		<dc:creator>ronald</dc:creator>
				<category><![CDATA[Computing]]></category>
		<category><![CDATA[Website]]></category>
		<category><![CDATA[applescript]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[scripting]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.rchu.nl/?p=444</guid>
		<description><![CDATA[My WordPress powered website has been running for quite some time now, and today I finally replaced the default theme with something I like better,  Suffusion, and customized it to my needs. I had installed some syntax highlighting plugins before but disabled them because I couldn&#8217;t get it to work properly. Now with the pretty <a href='http://www.rchu.nl/2010/04/some-nice-layout-changes/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full wp-image-449" title="Source code" src="http://www.rchu.nl/wordpress/wp-content/uploads/Screen-shot-2010-04-05-at-19.33.47.png" alt="Source code" width="287" height="225" />My WordPress powered website has been running for quite some time now, and today I finally replaced the default theme with something I like better,  <a href="http://wordpress.org/extend/themes/suffusion">Suffusion,</a> and customized it to my needs.</p>
<p>I had installed some syntax highlighting plugins before but disabled them because I couldn&#8217;t get it to work properly. Now with the pretty new layout all posts with snippets of unhighlighted source code were a real eye-sore, so that needed to be fixed as wel.</p>
<p><span id="more-444"></span>For some unknown reason the <a href="http://wordpress.org/extend/plugins/syntaxhighlighter/">SyntaxHighlighter Evolved</a> plugin that I couldn&#8217;t get to do as I wanted before now works like a charm. The only difficult part was to get me some <a href="http://developer.apple.com/AppleScript/">AppleScript </a>highlighting. <a href="http://davidchambersdesign.com/applescript-syntax-highlighting/">David Chambers</a> has written a brush, so I only had to install that brush the <a href="http://www.viper007bond.com/wordpress-plugins/syntaxhighlighter/adding-a-new-brush-language/">proper way</a>. Creating the plugin was easy:</p>
<pre class="brush: php;">
&lt;?php
/*
Plugin Name: SyntaxHighlighter Evolved: AppleScript Brush
Description: Adds support for the Applescript language to the SyntaxHighlighter Evolved plugin.
Author: Ronald Chu
Version: 1.0.0
Author URI: http://www.rchu.nl/
*/

// SyntaxHighlighter Evolved doesn't do anything until early in the &quot;init&quot; hook, so best to wait until after that
add_action( 'init', 'syntaxhighlighter_applescript_regscript' );

// Tell SyntaxHighlighter Evolved about this new language/brush
add_filter( 'syntaxhighlighter_brushes', 'syntaxhighlighter_applescript_addlang' );

// Register the brush file with WordPress
function syntaxhighlighter_applescript_regscript() {
 wp_register_script( 'syntaxhighlighter-brush-applescript', plugins_url( 'shBrushAppleScript.js', __FILE__ ), array('syntaxhighlighter-core'), '1.2.3' );
}

// Filter SyntaxHighlighter Evolved's language array
function syntaxhighlighter_applescript_addlang( $brushes ) {
 $brushes['applescript'] = 'applescript';
 $brushes['osascript'] = 'applescript';

 return $brushes;
}
?&gt;
</pre>
<p>But at first the highlighting did not work on AppleScript snippets, and it took me quite some time to find out that I shouldn&#8217;t have copy-pasted the javascriptcode into <a href="http://www.vim.org/about.php">Vim</a> on my ssh shell. Some of the special characters in line 37 were transformed into in a question mark which broke the regular expression.</p>
<p>Now, as far as I know, only one thing is wrong; when I refresh quickly in Chrome (5.0.342.7 beta, OS X 10.6.2) some of the keywords do not light up. I do not know if it is a bug in Chome, SyntaxHighighter or the AppleScript brush, but it is something I can live with for now.</p>
<p class='fb-like'><iframe src='http://www.facebook.com/plugins/like.php?href=http://www.rchu.nl/2010/04/some-nice-layout-changes/&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light' scrolling='no' frameborder='0' allowTransparency='true' style='border:none; overflow:hidden; width:450px; height:65px'></iframe></p>]]></content:encoded>
			<wfw:commentRss>http://www.rchu.nl/2010/04/some-nice-layout-changes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hello world!</title>
		<link>http://www.rchu.nl/2009/05/hello-world/</link>
		<comments>http://www.rchu.nl/2009/05/hello-world/#comments</comments>
		<pubDate>Sat, 02 May 2009 17:34:47 +0000</pubDate>
		<dc:creator>ronald</dc:creator>
				<category><![CDATA[Website]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://rchu.nl/?p=1</guid>
		<description><![CDATA[This is my first post on the third reincarnation of my weblog. It all started years ago when all of a sudden many people around me started with their Livejournals. I was socially forced to start one of my own, not in the least to keep up with their lives and be able to follow <a href='http://www.rchu.nl/2009/05/hello-world/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>This is my first post on the third reincarnation of my <a href="http://www.rchu.nl/">weblog</a>. It all started years ago when all of a sudden many people around me started with their <a href="http://www.livejournal.com/">Livejournals</a>. I was socially forced to start one of my own, not in the least to keep up with their lives and be able to follow the conversations in my own house. As I felt the need to keep control of my blog in my own hands grow I purged my livejournal and created a blog on my own website.</p>
<p>Now as a proud web developer I like to think I can create anything, and thus can write custom software which fits exactly to my personal needs. But as a lazy-ass blogger I don&#8217;t want to spend all that time <a href="http://www.youtube.com/watch?v=LgbWu8zJubo">reinventing the wheel</a>, I want everything, and I want it now! Installing <a href="http://www.wordpress.org/">WordPress</a> comes close enough :).</p>
<p>Now I have a way simpler way to write blogposts, and I hope I am going to because it&#8217;s fun, and even more fun reading back those posts later (I know this because I am importing old posts into this blog and really enjoy reading and formatting them). I also installed a livejournal crossposter, because the LJ people don&#8217;t do RSS or reading other blogs a lot. Lets see what happens.</p>
<p class='fb-like'><iframe src='http://www.facebook.com/plugins/like.php?href=http://www.rchu.nl/2009/05/hello-world/&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light' scrolling='no' frameborder='0' allowTransparency='true' style='border:none; overflow:hidden; width:450px; height:65px'></iframe></p>]]></content:encoded>
			<wfw:commentRss>http://www.rchu.nl/2009/05/hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

