<?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>langui.sh &#187; plugin</title>
	<atom:link href="http://langui.sh/tag/plugin/feed/" rel="self" type="application/rss+xml" />
	<link>http://langui.sh</link>
	<description>Fun hacks, WP plugins, photography, and PKI junk.  Languishing since 2008.</description>
	<lastBuildDate>Tue, 17 Jan 2012 20:23:53 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<atom:link rel="hub" href="http://pubsubhubbub.appspot.com"/><atom:link rel="hub" href="http://superfeedr.com/hubbub"/>		<item>
		<title>Updraft &#8211; A Cloud Backup and Restore Plugin For WordPress</title>
		<link>http://langui.sh/2010/06/17/updraft-a-cloud-backup-and-restore-plugin-for-wordpress/</link>
		<comments>http://langui.sh/2010/06/17/updraft-a-cloud-backup-and-restore-plugin-for-wordpress/#comments</comments>
		<pubDate>Thu, 17 Jun 2010 17:54:51 +0000</pubDate>
		<dc:creator>Paul Kehrer</dc:creator>
				<category><![CDATA[Posts]]></category>
		<category><![CDATA[cloud]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[updraft]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://langui.sh/?p=1036</guid>
		<description><![CDATA[<a href="http://langui.sh/2010/06/17/updraft-a-cloud-backup-and-restore-plugin-for-wordpress/" title="Updraft - A Cloud Backup and Restore Plugin For WordPress"></a>Over the past several months I have been working hard on a new plugin for WordPress and now I am pleased to unveil the initial release. Updraft is a backup and restore plugin for WordPress. It can do scheduled or &#8230;<p class="read-more"><a href="http://langui.sh/2010/06/17/updraft-a-cloud-backup-and-restore-plugin-for-wordpress/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://langui.sh/2010/06/17/updraft-a-cloud-backup-and-restore-plugin-for-wordpress/" title="Updraft - A Cloud Backup and Restore Plugin For WordPress"></a><p>Over the past several months I have been working hard on a new plugin for WordPress and now I am pleased to unveil the initial release.</p>
<p><a href="/updraft-wp-backup-restore/" target="_blank">Updraft</a> is a backup and restore plugin for WordPress.  It can do scheduled or one time backups of your plugins, themes, uploads, and DB itself.  These backups can be kept locally, emailed, sent to an FTP server, uploaded to Rackspace Cloud Files, or transferred to Amazon S3.<sup class='footnote'><a href='#fn-1036-1' id='fnref-1036-1'>1</a></sup></p>
<p>Additionally, you can pick the number of backups to retain and restore from a backup of your choice either by using a local backup, uploading copies yourself, or pulling them down from your cloud service.<sup class='footnote'><a href='#fn-1036-2' id='fnref-1036-2'>2</a></sup></p>
<p>Visit the <a href="http://langui.sh/updraft-wp-backup-restore" target="_blank">Updraft homepage</a> to learn more, see a screencast, and give feedback on bugs or features you&#8217;d like to see.  I look forward to hearing from you!</p>
<div class='footnotes'>
<div class='footnotedivider'></div>
<ol>
<li id='fn-1036-1'>Updraft requires WordPress 3.0 or greater! <span class='footnotereverse'><a href='#fnref-1036-1'>&#8617;</a></span></li>
<li id='fn-1036-2'>At this time restoration does not encompass DB.  You will need to download and restore the DB via another tool.  I am actively looking for ways to work around this issue for a future release. <span class='footnotereverse'><a href='#fnref-1036-2'>&#8617;</a></span></li>
</ol>
</div>
]]></content:encoded>
			<wfw:commentRss>http://langui.sh/2010/06/17/updraft-a-cloud-backup-and-restore-plugin-for-wordpress/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>WordPress 2.9 Upgrade</title>
		<link>http://langui.sh/2009/12/21/wordpress-2-9-upgrade/</link>
		<comments>http://langui.sh/2009/12/21/wordpress-2-9-upgrade/#comments</comments>
		<pubDate>Mon, 21 Dec 2009 17:19:12 +0000</pubDate>
		<dc:creator>Paul Kehrer</dc:creator>
				<category><![CDATA[Posts]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://langui.sh/?p=930</guid>
		<description><![CDATA[<a href="http://langui.sh/2009/12/21/wordpress-2-9-upgrade/" title="WordPress 2.9 Upgrade"></a>WP 2.9 is out. The upgrade went quite smoothly here, but be sure you upgrade your plugins before running the core upgrade! Fidgetr and CDN Tools are both 2.9 compatible already, so if you have the latest versions you&#8217;re set.]]></description>
			<content:encoded><![CDATA[<a href="http://langui.sh/2009/12/21/wordpress-2-9-upgrade/" title="WordPress 2.9 Upgrade"></a><p>WP 2.9 is <a href="http://wordpress.org/development/2009/12/wordpress-2-9/">out</a>.  The upgrade went quite smoothly here, but be sure you upgrade your plugins before running the core upgrade!  <a href="/fidgetr">Fidgetr</a> and <a href="/cdn-tools">CDN Tools</a> are both 2.9 compatible already, so if you have the latest versions you&#8217;re set.</p>
]]></content:encoded>
			<wfw:commentRss>http://langui.sh/2009/12/21/wordpress-2-9-upgrade/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Writing Compatible PHP For WordPress</title>
		<link>http://langui.sh/2009/12/07/writing-compatible-php-for-wordpress/</link>
		<comments>http://langui.sh/2009/12/07/writing-compatible-php-for-wordpress/#comments</comments>
		<pubDate>Tue, 08 Dec 2009 02:36:30 +0000</pubDate>
		<dc:creator>Paul Kehrer</dc:creator>
				<category><![CDATA[Posts]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://langui.sh/?p=875</guid>
		<description><![CDATA[<a href="http://langui.sh/2009/12/07/writing-compatible-php-for-wordpress/" title="Writing Compatible PHP For WordPress"></a>One of the big problems I&#8217;ve run into as a WordPress plugin developer is the diversity of PHP installations. Simply stating you only support PHP5 and greater is insufficient to ensure compatibility. Things you may take for granted in your &#8230;<p class="read-more"><a href="http://langui.sh/2009/12/07/writing-compatible-php-for-wordpress/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://langui.sh/2009/12/07/writing-compatible-php-for-wordpress/" title="Writing Compatible PHP For WordPress"></a><p>One of the big problems I&#8217;ve run into as a WordPress plugin developer is the diversity of PHP installations.  Simply stating you only support PHP5 and greater is insufficient to ensure compatibility.  Things you may take for granted in your development environment may be missing or worse, partially functional.  I&#8217;ve decided to document a few of the bigger &#8220;gotchas&#8221; I&#8217;ve run into so future WordPress hackers will have a starting point for investigating problems.</p>
<h3>Minimum PHP Version</h3>
<p>One easy way to reduce compatibility confusion is specifying a minimum version of PHP for your WordPress plugin or widget. To do so you can use PHP&#8217;s version_compare function:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">version_compare</span><span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">PHP_VERSION</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'5.0.0'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'&lt;'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #990000;">die</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">sprintf</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'You are currently running PHP version %s and you must have at least PHP 5.0.x'</span><span style="color: #339933;">,</span> <span style="color: #009900; font-weight: bold;">PHP_VERSION</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Take a look at the <a href="http://us.php.net/manual/en/function.version-compare.php">version_compare documentation</a> for more information. </p>
<h3>PHP Modules</h3>
<p>The biggest single thing to remember is that any module for PHP is optional.  If you want to require something like curl, that&#8217;s great, but be aware that some non-trivial percentage of your potential users may not have it.  Still want to use that module?  Test for its presence during the instantiation of your plugin and die if it&#8217;s not present.  This will prevent users from being able to successfully install your &#8220;broken&#8221; product if they don&#8217;t have the proper requirements.</p>
<p>Sometimes you&#8217;ll find yourself using functions you think are core to PHP like &#8220;mime_content_type&#8221;.  This is not the case.  In fact, I have frequently run into PHP installations that have no MIME detection facilities at all.  Consider writing a fallback for suffix detection<sup class='footnote'><a href='#fn-875-1' id='fnref-875-1'>1</a></sup> in addition to coding for mime_content_type and the finfo_* methods.</p>
<h3>Safe Mode and Related Problems</h3>
<p>Another common issue is safe_mode and open_basedir. These flags enforce certain security restrictions (must have the same group as PHP when writing to a directory, can&#8217;t open files beneath the basedir, et cetera).  However, they also impact some modules.  For instance, using curl you can&#8217;t use CURLOPT_FOLLOWLOCATION.  This will trigger the error &#8220;CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mode or an open_basedir is set&#8221;.</p>
<h3>Network Communication</h3>
<p>I&#8217;ve already talked a bit about the curl module, but you may also be tempted to use file_get_contents() assuming allow_url_fopen is enabled.  This is very frequently untrue in shared hosting environments.  Luckily, you don&#8217;t need to rely on curl or allow_url_fopen or write your own fsockopen() wrapper class.  Instead, WordPress has integrated <a href="http://sourceforge.net/projects/snoopy/">Snoopy</a> into the core.  Invoking it to fetch just the contents of a URL could not be easier!</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">require_once</span><span style="color: #009900;">&#40;</span> ABSPATH <span style="color: #339933;">.</span> <span style="color: #0000ff;">'wp-includes/class-snoopy.php'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$snoopy</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Snoopy<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$result</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$snoopy</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">fetch</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$url</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$result</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$response</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$snoopy</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">results</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Just hit up Google for the class docs to learn everything Snoopy can do for you.</p>
<p>There are many more where these came from, so drop your problems and solutions in the comments!</p>
<div class='footnotes'>
<div class='footnotedivider'></div>
<ol>
<li id='fn-875-1'>This can be a security risk in certain circumstances, so be careful. <span class='footnotereverse'><a href='#fnref-875-1'>&#8617;</a></span></li>
</ol>
</div>
]]></content:encoded>
			<wfw:commentRss>http://langui.sh/2009/12/07/writing-compatible-php-for-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Plugin Updates</title>
		<link>http://langui.sh/2009/10/23/wordpress-plugin-updates/</link>
		<comments>http://langui.sh/2009/10/23/wordpress-plugin-updates/#comments</comments>
		<pubDate>Fri, 23 Oct 2009 22:30:29 +0000</pubDate>
		<dc:creator>Paul Kehrer</dc:creator>
				<category><![CDATA[Posts]]></category>
		<category><![CDATA[cdn tools]]></category>
		<category><![CDATA[fidgetr]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://langui.sh/?p=709</guid>
		<description><![CDATA[<a href="http://langui.sh/2009/10/23/wordpress-plugin-updates/" title="WordPress Plugin Updates"></a>I&#8217;ve spent quite a bit of time on CDN Tools and Fidgetr in the past few weeks and this has cut back on the time I had planned to use to write blog entries. I&#8217;ll try to get a few &#8230;<p class="read-more"><a href="http://langui.sh/2009/10/23/wordpress-plugin-updates/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://langui.sh/2009/10/23/wordpress-plugin-updates/" title="WordPress Plugin Updates"></a><p>I&#8217;ve spent quite a bit of time on <a href="/cdn-tools">CDN Tools</a> and <a href="/fidgetr">Fidgetr</a> in the past few weeks and this has cut back on the time I had planned to use to write blog entries.  I&#8217;ll try to get a few new articles up soon, but in the mean time here is a status update on some projects you might be interested in&#8230;</p>
<p>CDN Tools (v0.9x and higher) is now compatible with WordPress 2.8+ and features a wide variety of reliability upgrades for various installation quirks.  I will be testing it shortly with WP 2.9 and expect to have a compatible version out prior to that release.  There are also some fun new features in the pipeline that will hopefully see the light of day in the next few weeks.</p>
<p>Regarding Fidgetr; I have decided to port the widget to the new WP 2.8 multi-widget API (which is adapted from the firetree multi-widget class).  While doing so I discovered that my previous assumptions about a single Fidgetr widget per WordPress page made porting quite difficult.  This necessitated an almost total rewrite of the core (and major modifications to the accompanying themes).  At this time I have the new widget mostly working, but there are many cosmetic bugs to resolve with the themes.  That said, I&#8217;m excited to offer this feature for those who desire it.  I have no targeted release date, but Fidgetr 2.0 will require WP 2.8+.  Fidgetr 1.3.5 is almost certainly the last 2.7 compatible release.</p>
]]></content:encoded>
			<wfw:commentRss>http://langui.sh/2009/10/23/wordpress-plugin-updates/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Announcing Fidgetr</title>
		<link>http://langui.sh/2009/01/29/announcing-fidgetr/</link>
		<comments>http://langui.sh/2009/01/29/announcing-fidgetr/#comments</comments>
		<pubDate>Fri, 30 Jan 2009 02:16:07 +0000</pubDate>
		<dc:creator>Paul Kehrer</dc:creator>
				<category><![CDATA[Posts]]></category>
		<category><![CDATA[fidgetr]]></category>
		<category><![CDATA[flickr]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[widget]]></category>

		<guid isPermaLink="false">http://langui.sh/?p=144</guid>
		<description><![CDATA[<a href="http://langui.sh/2009/01/29/announcing-fidgetr/" title="Announcing Fidgetr"></a>For the past few weeks I have been working on a small coding project and today I am proud to announce its first public release! Fidgetr is a WordPress widget that displays the latest photos from your Flickr photostream in an &#8230;<p class="read-more"><a href="http://langui.sh/2009/01/29/announcing-fidgetr/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://langui.sh/2009/01/29/announcing-fidgetr/" title="Announcing Fidgetr"></a><p>For the past few weeks I have been working on a small coding project and today I am proud to announce its first public release!</p>
<p><a href="http://langui.sh/fidgetr/">Fidgetr</a> is a WordPress widget that displays the latest photos from your Flickr photostream in an attractive manner.  It features support for its own themes along with very simple setup and good compatibility with various WordPress themes.  I will likely continue to announce releases here, but Fidgetr&#8217;s <a href="http://langui.sh/fidgetr/">homepage</a> will always have the latest news.  The code is hosted via subversion on wordpress.org and is licensed under the GPL.  I welcome any improvements and/or theme contributions!</p>
<p>A big thanks goes out to the following people:<br />
Matt Pennig for his invaluable assistance with various javascript and CSS questions.<br />
Major Hayden for testing the widget and tolerating my constant chattering about WP plugin development.</p>
<p>If you have any questions, comments, or suggestions feel free to leave them here or on Fidgetr&#8217;s homepage.</p>
]]></content:encoded>
			<wfw:commentRss>http://langui.sh/2009/01/29/announcing-fidgetr/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using memcached
Page Caching using memcached
Database Caching 17/42 queries in 0.016 seconds using memcached
Object Caching 838/880 objects using memcached

Served from: langui.sh @ 2012-02-07 06:34:31 -->
