<?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>Mark Robert Henderson &#187; Merit Badges</title>
	<atom:link href="http://blog.markroberthenderson.com/category/merit-badges/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.markroberthenderson.com</link>
	<description>The greatest adventures in the history of LAMP development</description>
	<lastBuildDate>Sat, 14 Nov 2009 22:50:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Getting rid of /forums/ and /topic/ from bbPress permalinks &#8211; Updated Plugin</title>
		<link>http://blog.markroberthenderson.com/getting-rid-of-forums-and-topic-from-bbpress-permalinks-updated-plugin/</link>
		<comments>http://blog.markroberthenderson.com/getting-rid-of-forums-and-topic-from-bbpress-permalinks-updated-plugin/#comments</comments>
		<pubDate>Sat, 19 Sep 2009 19:04:46 +0000</pubDate>
		<dc:creator>MRH</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://blog.markroberthenderson.com/?p=55</guid>
		<description><![CDATA[There is an existing plugin that does this, but not completely and there are still a few bugs with it.  This post contains an updated version of the plugin, along with instructions on how to install it.]]></description>
			<content:encoded><![CDATA[<p>I was doing some work with bbPress recently and I was looking for a way to take the standard bbPress urls and turn them into something a little more hierarchical and semantic. Currently, they look like:</p>
<pre>http://domain.com/forums/forum/name-of-forum/

http://domain.com/forums/topic/name-of-topic/

etc..</pre>
<p>Not exactly ideal. It would be better if they looked more like:</p>
<pre>http://domain.com/forums/name-of-forum/name-of-topic</pre>
<p>So I found <a href="http://bbpress.org/forums/topic/nicer-slug-url-rewrite-plugin-done" target="_blank">this post on the bbPress forums</a>, which led me to this <a href="http://www.technospot.net/blogs/how-to-remove-forum-and-topic-keyword-from-bbpress-url/">packaged plugin by Ashsh Mohta</a>. However, a few things were busted &#8211; new posts, and also paging on forums and topic names that end with &#8220;forum/&#8221; or &#8220;topic/&#8221;</p>
<p>With a few modifications, I finally got it working, and here are the steps that I took. <strong>Note:</strong> This requires a bit of bbPress core hacking, but it&#8217;s literally only switching the order of two lines in the code.</p>
<ol>
<li>Enable name based permalinks in /bb-admin/options-permalinks.php</li>
<li>Download the plugin from this page, put it in your my-plugins folder, and enable it</li>
<li>Change the .htaccess file at the root of your bbPress install to the htaccess.dist file packaged with the plugin.</li>
<li>Open up bb-post.php at the root of your bbPress install and simply switch lines number 46 and 48</li>
</ol>
<p>I&#8217;m sure this isn&#8217;t perfect, and I&#8217;d love any and all feedback. It&#8217;s been working like a charm for me for a little while now, and hopefully it will help you! I&#8217;d love to find both a way to install this and have the plugin automatically backup and rewrite the .htaccess file, and of course a way to do it without editing the core code.</p>
<p>Plugin: <a href="http://blog.markroberthenderson.com/files/2009/09/remove-forum-topic1.zip">Clean Up bbPress Permalinks</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.markroberthenderson.com/getting-rid-of-forums-and-topic-from-bbpress-permalinks-updated-plugin/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Using a Single, Central Wordpress-MU Installation to Power ***ALL*** Your Domains</title>
		<link>http://blog.markroberthenderson.com/using-a-single-central-wordpress-mu-installation-to-power-all-your-domains/</link>
		<comments>http://blog.markroberthenderson.com/using-a-single-central-wordpress-mu-installation-to-power-all-your-domains/#comments</comments>
		<pubDate>Sun, 02 Aug 2009 16:29:51 +0000</pubDate>
		<dc:creator>MRH</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://blog.markroberthenderson.com/using-a-single-central-wordpress-mu-installation-to-power-all-your-domains/</guid>
		<description><![CDATA[Tired of maintaining a whole boat load of WordPress installations? If you've got your own server, all it takes is one install of WP-MU to simplify your life.]]></description>
			<content:encoded><![CDATA[<blockquote><p>This was something that was bothering me for a while &#8211; Several of my clients&#8217; WordPress blogs were hosted on my server, all with slightly different versions and modifications. This creates a mess of files across all your DocumentRoots &#8211; nearly identical but just different enough to become tedious and cluttered. These instructions provide a possible solution: Running wp-mu centrally across any number of top level domains.<span id="more-1"></span></p></blockquote>
<p>These instructions assume a basic knowledge of the command line and MySQL, and that you have at least a VPS or a dedicated server. Shared hosting users do not dispair, as some hosting companies can be awesome and help if you call tech support. <em>Some</em> hosting companies.</p>
<p>I can&#8217;t tell you exactly what file to put the Apache directives since every operating system and every version of apache has a number of different places where you can do so, but <span style="color: #000000">I would be happy to include different information on where to put these directives for all the different distros and whatnot, I just need people to send them to me!</span></p>
<p>I&#8217;d be curious to hear other people&#8217;s takes on this stuff. Please let me know what you think of these methods and if you&#8217;ve had any similar experiences.</p>
<p><span style="color: #999999"><br />
</span></p>
<h3>Initial Setup.</h3>
<ol>
<li>Download the wordpress core code with svn. I chose to put it into a directory called /opt/wordpress-mu:
<pre>cd /opt
svn http://svn.automattic.com/wordpress-mu/tags/2.8.2/ wordpress-mu</pre>
<p>This way, if you want to update later all you need to do is replace [new-version] with the new version number:</p>
<pre>cd /opt/wordpress-mu
svn switch http://svn.automattic.com/wordpress-mu/tags/[new-version]/</pre>
</li>
<li>Edit your virtualhost file to include the following directives. This is the minimum of what you&#8217;ll need to make sure to include:
<pre>&lt;VirtualHost *:80&gt;
  ServerName www.oneofmanyblogs.com
  ServerAlias oneofmanyblogs.com *.oneofmanyblogs.com
  DocumentRoot /opt/wordpress-mu
&lt;/VirtualHost&gt;</pre>
</li>
<li>Restart Apache, navigate your browser to your blog url, and perform the standard wordpress-mu installation process (<a href="http://codex.wordpress.org/Installing_WPMU">start at step 4</a>).<strong> </strong><strong> </strong></li>
<li>So what we have now is no different than the standard wordpress-mu install except we&#8217;ve decided to install it in /opt instead of a more standard Apache directory like, say, /var/www. Here&#8217;s where the magic begins. I have to give a shout out to Reverend over at <a title="Bava Tuesdays" href="http://bavatuesdays.com" target="_blank">http://bavatuesdays.com</a> for his excellent post on <a title="Article on using wordpress-mu for multiple domains" href="http://bavatuesdays.com/multiple-domains-on-wpmu-mission-accomplished/" target="_blank">wordpress-mu&#8217;s ability to handle multiple domains</a>, since it led me to the WPMU multiple sites plugin. So let&#8217;s continue with this plugin in mind:
<pre>cd /opt/wordpress-mu/wp-content/mu-plugins
wget http://wpmudev.org/download/1193384369_njsl-sites-009.php</pre>
</li>
<li>Finally, we get to the browser. Navigate to /wp-admin. Since the plug-ins in this folder are automatically activated, you will now see a &#8220;Sites&#8221; submenu of Site Admin. Click to there and the next bit of awesomeness begins.</li>
</ol>
<h3>Adding Fresh Blogs and Domains</h3>
<ol>
<li>Add your new site to the control panel accessible via the &#8220;Sites&#8221; submenu item of Site Admin. I usually enter the url twice, &#8220;/&#8221; as the path, and the name of the site as you&#8217;d like it to appear in the header of the page. Then, click Create Site.</li>
<li>Lets say we&#8217;re adding yetanotherblog.com. Go back to your virtualhosts file and edit the ServerAlias line like so:
<pre>ServerAlias oneofmanyblogs.com *.oneofmanyblogs.com yetanotherblog.com www.yetanotherblog.com *.yetanotherblog.com</pre>
</li>
<li>Restart apache again and your new blog should be up and running! It&#8217;s as easy as that. Notice that your admin login you created for oneofmanyblogs.com works here as well. Enjoy your new blog. What if you have an existing blog you want to transfer over? Well&#8230; that&#8217;s a slightly different endeavor.</li>
</ol>
<h3>Migrating an Existing Blog to your new WordPress-MU blog system (ninjas only)</h3>
<ol>
<li>Before we begin, do all the steps in the &#8220;Adding Fresh Blogs and Domains&#8221; section to create a new Site with the domain name of the blog you&#8217;re transitioning over.</li>
<li>In order to migrate over, you&#8217;re going to need a two things: a copy of your original blogs wp-content folder, and a MySQL dump of your original blog&#8217;s database. However you choose to get these things to where you need them is up to you. Let&#8217;s just assume that you have them. First, <strong>merge</strong> the files from wp-content/plugins, wp-content/uploads, and wp-content/themes into the central wordpress-mu/wp-content folder.</li>
<li>Then, you need to alter your sql dump file a bit. The way WP-MU names the tables is wp_1_[tablename] for the first blog, and wp_2_[tablename] for the second and so on and so forth. Since we&#8217;ve already created this blog as a fresh blog, the tables already exist, prefixed, let&#8217;s say, by wp_3_. What we&#8217;ll want to do is rename every table in your old sites sql dump from wp_[tablename] to wp_3_[tablename], then transfer every table from your old blog over <em>except</em> the wp-options table, the wp_users table, and the wp_usermeta table. (Trust me, including these table will really mess up your chi.)
<pre>mysql -u [user] -p[password] [database-name]
&gt; RENAME TABLE wp_3_options TO _wp_3_options;
&gt; exit;
sed 's/wp_/wp_3_/g' sqldump.sql &gt; sqldump_3.sql
mysql -u [user] -p[password] [database-name] &lt; sqldump_3.sql
mysql -u [user] -p[password] [database-name]
&gt; DROP TABLE wp_3_options, wp_3_users, wp_3_usermeta;
&gt; RENAME TABLE _wp_3_options TO wp_3_options</pre>
</li>
<li>There, all the heavy lifting is over and now you can log back in as admin, install the plugins, activate the theme, and do all the normal WP-MU admin panel stuff that is not covered in the scope of this tutorial. Not too too bad, right?</li>
</ol>
<h3>Advantages of This System</h3>
<ol>
<li>First, from an administrative standpoint, it&#8217;s easier to maintain. Installs are done via svn up and you only need to do it once for all the sites. There is a concern about database overhead once you get up into dozens or even hundreds of sites, but for now this works as a solution.</li>
<li>Content can more easily shared among the blogs, now that they know about each other a little more and share a database.</li>
<li>Each blog can now have a ton of different blogs too. So not only is each domain its own blog, but each domain can have multiple subdomains, all blogs, all running from a central WP install.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://blog.markroberthenderson.com/using-a-single-central-wordpress-mu-installation-to-power-all-your-domains/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>Centralized Wordpress-MU Video Tutorials</title>
		<link>http://blog.markroberthenderson.com/centralized-wordpress-mu-video-tutorials/</link>
		<comments>http://blog.markroberthenderson.com/centralized-wordpress-mu-video-tutorials/#comments</comments>
		<pubDate>Fri, 03 Jul 2009 03:12:05 +0000</pubDate>
		<dc:creator>MRH</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Featured]]></category>
		<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://blog.markroberthenderson.com/?p=49</guid>
		<description><![CDATA[
]]></description>
			<content:encoded><![CDATA[<p><embed src="http://www.vimeo.com/moogaloop.swf?clip_id=6408187" quality="best" scale="exactfit" width="425" height="350" type="application/x-shockwave-flash"></embed></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.markroberthenderson.com/centralized-wordpress-mu-video-tutorials/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
