<?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>SurlyJake &#187; wordpress</title>
	<atom:link href="http://www.surlyjake.com/tag/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.surlyjake.com</link>
	<description></description>
	<lastBuildDate>Fri, 30 Dec 2011 15:28:12 +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>WordPress HTTPS secure login</title>
		<link>http://www.surlyjake.com/2011/12/wordpress-https-secure-login-with-nginx/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-https-secure-login-with-nginx</link>
		<comments>http://www.surlyjake.com/2011/12/wordpress-https-secure-login-with-nginx/#comments</comments>
		<pubDate>Wed, 21 Dec 2011 03:36:11 +0000</pubDate>
		<dc:creator>jacob</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.surlyjake.com/?p=862</guid>
		<description><![CDATA[Back when I started with WordPress, I had to create server rewrites to force my browser to use HTTPS. That changed back in 2008, but this is the first i&#8217;ve heard of it. WordPress 2.6 (released in July, 2008) and newer include the tools do do this out of the box! Using this documentation, you [...]]]></description>
			<content:encoded><![CDATA[<p>Back when I started with <a href="http://www.surlyjake.com/tag/wordpress/" class="st_tag internal_tag" rel="tag" title="Posts tagged with wordpress">WordPress</a>, I had to create server rewrites to force my browser to use HTTPS. That changed back in 2008, but this is the first i&#8217;ve heard of it.</p>
<p>WordPress 2.6 (released in July, 2008) and newer include the tools do do this out of the box! Using this documentation, you can get rid of some old .htaccess or nginx rewrite rules: <a title="http://codex.wordpress.org/Administration_Over_SSL" href="http://codex.wordpress.org/Administration_Over_SSL" target="_blank">http://codex.wordpress.org/Administration_Over_SSL</a>.  All you have to do is add the declaration in wp-config.php:</p>
<pre><code>define('FORCE_SSL_ADMIN', true);</code></pre>
<p>This forces logins and administrative sessions to use SSL.</p>
<p>Now, you can remove the old nginx rewrites. They aren&#8217;t needed anymore:</p>
<pre><code>rewrite ^/wp-login.php(.*) https://www.surlyjake.com/wp-login.php$1 permanent;</code>
<code>rewrite ^/wp-admin(.*) https://www.surlyjake.com/wp-admin$1 permanent;</code></pre>
<div class="none"><div class="g-plusone" data-href="http://www.surlyjake.com/2011/12/wordpress-https-secure-login-with-nginx/" size="standard" count="true"></div></div>]]></content:encoded>
			<wfw:commentRss>http://www.surlyjake.com/2011/12/wordpress-https-secure-login-with-nginx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Redirection Plugin</title>
		<link>http://www.surlyjake.com/2011/09/wordpress-redirection-plugin/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=wordpress-redirection-plugin</link>
		<comments>http://www.surlyjake.com/2011/09/wordpress-redirection-plugin/#comments</comments>
		<pubDate>Fri, 09 Sep 2011 20:10:17 +0000</pubDate>
		<dc:creator>jacob</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[web developer]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.surlyjake.com/?p=809</guid>
		<description><![CDATA[This blog is undergoing some changes.There is some content (like the zabbix pages) that I can no longer maintain since I no longer use them in my day-job. To keep everything working seamlessly, I wanted to create some 302 (permanently moved) redirectors for the content that I was taking down. In the past, I used [...]]]></description>
			<content:encoded><![CDATA[<p>This blog is undergoing some changes.There is some content (like the zabbix pages) that I can no longer maintain since I no longer use them in my day-job. To keep everything working seamlessly, I wanted to create some 302 (permanently moved) redirectors for the content that I was taking down. In the past, I used a plugin called &#8220;<a href="http://wordpress.org/extend/plugins/smart-404/" target="_blank">smart 404</a>&#8221; to intelligently redirect visitors to a good page instead of the dummy standard 404 page. Unfortunately, It looks like smart 404 is having some trouble in newer <a href="http://www.surlyjake.com/tag/wordpress/" class="st_tag internal_tag" rel="tag" title="Posts tagged with wordpress">WordPress</a> versions and wouldn&#8217;t create a smart suggestions on my 404 page.</p>
<p>Enter <a href="http://wordpress.org/extend/plugins/redirection/" target="_blank">Redirection</a>. Redirection gives you a menu in the admin interface which allows you to easily create and maintain 301 and 302 redirections (among other features). Here is a screenshot of what it looks like once activated:</p>
<p><a href="http://www.surlyjake.com/2011/09/wordpress-redirection-plugin/wordpress-redirection-plugin/" rel="attachment wp-att-818"><img class="size-large wp-image-818 alignnone" title="wordpress-redirection-plugin" src="http://www.surlyjake.com/wp-content/uploads/2011/09/wordpress-redirection-plugin-1024x389.jpg" alt="" width="570" height="216" /></a></p>
<p>From the screenshot, you can see that I was able to create a simple 301 redirect from a page on my WordPress instance to an external website where the content will live from now on.  The second rule allowed me to match the URL using a regular expression and redirect it to another page on my site. This is a great piece of software.</p>
<p>One issue I ran into when testing the plugin was that edits I made did not seem to be taking effect. This turned out to simply be my browser caching the 301 response. I recommend that you either manually clear the cache or download the <a href="http://chrispederick.com/work/web-developer/" target="_blank">web developer toolbar</a> and disable cache.  I should also note that my server runs nginx and not the Apache web server. I simply deleted the redirection &#8216;module&#8217; for Apache which attempts to create .htaccess rules to perform the redirections. Without the Apache module, WordPress handles the redirections.</p>
<p>Redirection Plugin documentation: <a href="http://urbangiraffe.com/plugins/redirection/" target="_blank">http://urbangiraffe.com/plugins/redirection/</a></p>
<div class="none"><div class="g-plusone" data-href="http://www.surlyjake.com/2011/09/wordpress-redirection-plugin/" size="standard" count="true"></div></div>]]></content:encoded>
			<wfw:commentRss>http://www.surlyjake.com/2011/09/wordpress-redirection-plugin/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>script to update wordpress</title>
		<link>http://www.surlyjake.com/2008/11/script-to-update-wordpress/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=script-to-update-wordpress</link>
		<comments>http://www.surlyjake.com/2008/11/script-to-update-wordpress/#comments</comments>
		<pubDate>Wed, 26 Nov 2008 21:02:37 +0000</pubDate>
		<dc:creator>jacob</dc:creator>
				<category><![CDATA[shell scripting]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[update]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.surlyjake.com/?p=119</guid>
		<description><![CDATA[Why? Because i&#8217;m lazy. I&#8217;ll update this to see if it works #!/bin/sh #your current site will be backed up to your home folder with the date in the name #change this to whatever you want BACKUPNAME="wordpress_site_b4_update" BACKUPDATE=`date +%y%m%d` #this is the path to your wordpress site's root SITEROOT="/usr/local/www/" #here she goez... cd ~ tar [...]]]></description>
			<content:encoded><![CDATA[<p>Why? Because i&#8217;m lazy. I&#8217;ll <a href="http://www.surlyjake.com/tag/update/" class="st_tag internal_tag" rel="tag" title="Posts tagged with update">update</a> this to see if it works<br />
<code>#!/bin/sh<br />
#your current site will be backed up to your home folder with the date in the name<br />
#change this to whatever you want<br />
BACKUPNAME="<a href="http://www.surlyjake.com/tag/wordpress/" class="st_tag internal_tag" rel="tag" title="Posts tagged with wordpress">wordpress</a>_site_b4_update"<br />
BACKUPDATE=`date +%y%m%d`<br />
#this is the path to your wordpress site's root<br />
SITEROOT="/usr/local/www/"<br />
#here she goez...<br />
cd ~<br />
tar -pczf "$BACKUPNAME""$BACKUPDATE".tar.gz "$SITEROOT"<br />
cd /usr/local<br />
fetch http://wordpress.org/latest.tar.gz<br />
tar -xzf latest.tar.gz<br />
rm latest.tar.gz<br />
cp -R wordpress/* "$SITEROOT"/<br />
rm -R wordpress<br />
chown -R www "$SITEROOT"<br />
</code></p>
<div class="none"><div class="g-plusone" data-href="http://www.surlyjake.com/2008/11/script-to-update-wordpress/" size="standard" count="true"></div></div>]]></content:encoded>
			<wfw:commentRss>http://www.surlyjake.com/2008/11/script-to-update-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

