<?xml version="1.0" encoding="UTF-8"?>
<rss 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" version="2.0">

<channel>
	<title>Paul Maunders | Web log</title>
	<atom:link href="http://www.pyrosoft.co.uk/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.pyrosoft.co.uk/blog</link>
	<description>Economics, Business, Telecoms, Tech and Gadgets</description>
	<pubDate>Tue, 07 Oct 2008 17:57:25 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
	<language>en</language>
			<item>
		<title>Attack of the Wee PCs</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/10/07/attack-of-the-wee-pcs/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/10/07/attack-of-the-wee-pcs/#comments</comments>
		<pubDate>Tue, 07 Oct 2008 17:45:45 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=434</guid>
		<description><![CDATA[Anyone looking for an ultra portable / mini laptop / sub notebook / netbook is now spoilt for choice. It seems that after the OLPC (one laptop per child) project announced they were aiming to build an ultraportable device for $100, every manufacturer wants a piece of the pie. 


Name
Screen Size
Weight
Price


ASUS EEE PC
7&#34; - 10&#34;
0.92 [...]]]></description>
			<content:encoded><![CDATA[<p>Anyone looking for an ultra portable / mini laptop / sub notebook / netbook is now spoilt for choice. It seems that after the OLPC (one laptop per child) project announced they were aiming to build an ultraportable device for $100, every manufacturer wants a piece of the pie. </p>
<table class="compare">
<tr>
<th>Name</th>
<th>Screen Size</th>
<th>Weight</th>
<th>Price</th>
</tr>
<tr>
<td><a href="http://eeepc.asus.com/global/">ASUS EEE PC</a></td>
<td>7&quot; - 10&quot;</td>
<td>0.92 -  1.1 KG</td>
<td>&pound;160 - &pound;340</td>
</tr>
<tr>
<td><a href="http://laptop.org/">OLPC XO-1</a></td>
<td>7.5</td>
<td>1.45 KG</td>
<td>$200 ($400 give one get one)</td>
</tr>
<tr>
<td><a href="http://www.mydellmini.com/">Dell Mini 9</a></td>
<td>8.9&quot;</td>
<td>1.035 KG</td>
<td>&pound;269 - &pound;299</td>
</tr>
<tr>
<td><a href="http://www.acer.com/aspireone/">Acer Aspire One</a></td>
<td>8.9&quot;</td>
<td>0.99 -  1.26 KG</td>
<td>&pound;198 - &pound;269</td>
</tr>
</table>
<p>References:</p>
<p>Wikipedia - <a href="http://en.wikipedia.org/wiki/Comparison_of_netbooks">Comparison of Netbooks</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/10/07/attack-of-the-wee-pcs/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F10%2F07%2Fattack-of-the-wee-pcs%2F</feedburner:awareness></item>
		<item>
		<title>Running mysqldump via ssh (direct host to host copy)</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/10/03/running-mysqldump-via-ssh-direct-host-to-host-copy/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/10/03/running-mysqldump-via-ssh-direct-host-to-host-copy/#comments</comments>
		<pubDate>Fri, 03 Oct 2008 12:52:19 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<category><![CDATA[mysql]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=430</guid>
		<description><![CDATA[In order to run a mysqldump from one host to another over SSH you can run:

mysqldump dbname &#124; ssh root@remotehost.com "mysql -D dbname"
This will pipe the output of mysqldump directly to the ssh connection which is running MySQL at the other end and receiving the mysqldump from standard input.
]]></description>
			<content:encoded><![CDATA[<p>In order to run a mysqldump from one host to another over SSH you can run:<br />
<code><br />
mysqldump dbname | ssh root@remotehost.com "mysql -D dbname"</code><br />
This will pipe the output of mysqldump directly to the ssh connection which is running MySQL at the other end and receiving the mysqldump from standard input.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/10/03/running-mysqldump-via-ssh-direct-host-to-host-copy/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F10%2F03%2Frunning-mysqldump-via-ssh-direct-host-to-host-copy%2F</feedburner:awareness></item>
		<item>
		<title>A wget replacement for OS X Leopard</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/09/16/a-wget-replacement-for-os-x-leopard/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/09/16/a-wget-replacement-for-os-x-leopard/#comments</comments>
		<pubDate>Tue, 16 Sep 2008 10:40:20 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[apple]]></category>

		<category><![CDATA[leopard]]></category>

		<category><![CDATA[osx]]></category>

		<category><![CDATA[wget]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=426</guid>
		<description><![CDATA[If, like me, you are missing wget since you upgraded to Leopard, then should set up an alias for wget to curl -O which does exactly the same thing:

echo 'alias wget="curl -O"' >> ~/.bash_profile

]]></description>
			<content:encoded><![CDATA[<p>If, like me, you are missing wget since you upgraded to Leopard, then should set up an alias for wget to curl -O which does exactly the same thing:</p>
<pre>
echo 'alias wget="curl -O"' >> ~/.bash_profile
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/09/16/a-wget-replacement-for-os-x-leopard/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F09%2F16%2Fa-wget-replacement-for-os-x-leopard%2F</feedburner:awareness></item>
		<item>
		<title>Getting Apache, PHP and MySQL to work on Leopard</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/09/16/getting-apache-php-and-mysql-to-work-on-leopard/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/09/16/getting-apache-php-and-mysql-to-work-on-leopard/#comments</comments>
		<pubDate>Tue, 16 Sep 2008 09:44:59 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[apple]]></category>

		<category><![CDATA[mysql]]></category>

		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=419</guid>
		<description><![CDATA[If you have upgraded from Tiger, you may need to complete these steps to get Leopard&#8217;s version of Apache to work with UserDir

Copy your old userdir configurations from /etc/httpd/users/ to /etc/apache2/users/
Uncomment LoadModule php5_module        libexec/apache2/libphp5.so in /etc/apache2/httpd.conf

To install MySQL follow these steps:

Download the MySQL OS X disk image from [...]]]></description>
			<content:encoded><![CDATA[<p>If you have upgraded from Tiger, you may need to complete these steps to get Leopard&#8217;s version of Apache to work with UserDir</p>
<ul>
<li>Copy your old userdir configurations from /etc/httpd/users/ to /etc/apache2/users/</li>
<li>Uncomment <em>LoadModule php5_module        libexec/apache2/libphp5.so</em> in /etc/apache2/httpd.conf</li>
</ul>
<p>To install MySQL follow these steps:</p>
<ul>
<li>Download the MySQL OS X disk image from a <a href="http://www.mirrorservice.org/sites/ftp.mysql.com/downloads/mysql/5.0.html#macosx-dmg">MySQL mirror</a></li>
<li>Mount the image, and install the main package, the startup item package, and then the preferences pane</li>
<li>Add the mysql bin folder to your path:
<pre>sudo echo 'export PATH=$PATH:/usr/local/mysql/bin' >> ~/.bash_profile</pre>
</li>
<li>If no /private/etc/php.ini exists, make a copy of php.ini.default</li>
<li>Update php.ini to point at the new MySQL socket <em>mysql.default_socket = /private/tmp/mysql.sock</em> - do this for both mysql and mysqli.
<pre>mysql.default_socket = /private/tmp/mysql.sock
mysqli.default_socket = /private/tmp/mysql.sock</pre>
</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/09/16/getting-apache-php-and-mysql-to-work-on-leopard/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F09%2F16%2Fgetting-apache-php-and-mysql-to-work-on-leopard%2F</feedburner:awareness></item>
		<item>
		<title>Generating a Certificate Signing Request</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/09/10/generating-a-certificate-signing-request/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/09/10/generating-a-certificate-signing-request/#comments</comments>
		<pubDate>Wed, 10 Sep 2008 09:26:24 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=412</guid>
		<description><![CDATA[When applying for a secure certificate you will need to generate a certificate signing request (CSR). If you are renewing an existing certificate you might want to keep your existing private key, if it&#8217;s a new certificate then you will probably need to create a new private key. 
If you have previously registered a secure [...]]]></description>
			<content:encoded><![CDATA[<p>When applying for a secure certificate you will need to generate a certificate signing request (CSR). If you are renewing an existing certificate you might want to keep your existing private key, if it&#8217;s a new certificate then you will probably need to create a new private key. </p>
<p>If you have previously registered a secure cert and nothing has changed since then, you can even re-use the existing CSR. The most important part of a CSR is the embedded public key, which must correspond to your private key, hence why it only really needs to change if you have changed private key.</p>
<p><b>What is in a Certificate Signing Request?</b><br />
A CSR can contain the following information:</p>
<ul>
<li>Domain name (or person&#8217;s name)</li>
<li>Address details</li>
<li>E-mail address</li>
<li>Public Key</li>
</ul>
<p>When you send the CSR to a CA (certificate authority), they will use the information embedded within it to create you a full certificate, which has been signed by them. Some CAs will let you change the address information before generating the certificate.</p>
<p>You can decode a CSR with the following command:</p>
<pre>
openssl req -in old/secure.domain.com.csr -text -noout
Certificate Request:
   Data:
       Version: 0 (0x0)
       Subject: C=GB, ST=Hampshire, L=Aldershot, O=Fubra Ltd,
CN=secure.domain.com
       Subject Public Key Info:
           Public Key Algorithm: rsaEncryption
           RSA Public Key: (1024 bit)
               Modulus (1024 bit):
                   00:c7:2b:e8:ad:c7:2a:da:f7:0f:e5:7d:23:f5:91:
                   49:a5:1d:ee:df:03:33:af:b5:ad:0b:dd:3e:af:e0:
                   95:67:b8:39:fb:2b:0e:c4:2b:37:d7:aa:f7:79:f8:
                   07:23:41:87:e8:72:88:8e:4b:c5:e6:cc:51:7b:9a:
                   9f:87:db:52:f8:4d:73:b2:79:9a:b9:18:17:fb:f8:
                   22:05:6b:af:25:81:e3:89:e0:ec:be:d1:19:93:bf:
                   06:31:20:01:e3:3d:80:7f:1e:c3:9c:89:4f:33:f1:
                   bd:9a:f6:58:d5:74:51:9a:43:3e:14:f8:ee:8e:8d:
                   7b:43:da:44:33:13:bd:0d:7f
               Exponent: 65537 (0x10001)
       Attributes:
           a0:00
   Signature Algorithm: md5WithRSAEncryption
       50:c7:69:cf:04:53:8b:de:64:dc:ba:e3:ac:3b:93:d1:94:2f:
       48:3b:15:27:c7:e5:1a:65:bc:a4:bd:cb:6a:fe:12:a3:b0:14:
       13:23:ff:3b:15:68:eb:48:c1:63:64:e0:de:8d:ce:34:93:8f:
       41:ef:97:e5:6f:aa:1d:01:db:2e:51:d6:68:8a:d3:f8:f4:70:
       87:17:a2:d1:c8:2d:79:61:22:b6:02:bd:31:50:67:e6:7e:fb:
       23:49:e3:58:61:2e:6b:4b:77:1e:76:3f:d8:2f:8e:44:6e:9e:
       e7:e5:54:f7:a7:90:a7:3c:1e:34:4a:31:22:72:77:fe:bc:7e:
       53:ce
</pre>
<p><strong>Generating a new CSR and a new private key</strong><br />
To create a brand new private key and certificate signing request just run:</p>
<pre>
openssl req -new -nodes -keyout newprivate.key -out server.csr
</pre>
<p><strong>Generating a new CSR with an existing private key</strong></p>
<p>If you need to generate a certificate signing request from an existing private key, you can do so with the following command:</p>
<pre>
openssl req -new -key existingprivate.key -out server.csr
</pre>
<p><strong>Using an existing CSR with an existing private key</strong><br />
You don&#8217;t need to run any new commands, just send your existing CSR to the certificate issuer.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/09/10/generating-a-certificate-signing-request/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F09%2F10%2Fgenerating-a-certificate-signing-request%2F</feedburner:awareness></item>
		<item>
		<title>Apple Homepage - 4th Generation iPod Nano</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/09/09/apple-homepage-4t-generation-ipod-nano/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/09/09/apple-homepage-4t-generation-ipod-nano/#comments</comments>
		<pubDate>Tue, 09 Sep 2008 21:26:11 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[apple]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=408</guid>
		<description><![CDATA[Apple really do make the most of their website&#8217;s homepage to promote their latest products, and since they are one of my favourite companies, I am going to try to keep a record of these designs on my site.
Here&#8217;s my first following today&#8217;s announcement of the 4th generation iPod Nano:

]]></description>
			<content:encoded><![CDATA[<p>Apple really do make the most of their website&#8217;s homepage to promote their latest products, and since they are one of my favourite companies, I am going to try to keep a record of these designs on my site.</p>
<p>Here&#8217;s my first following today&#8217;s announcement of the 4th generation iPod Nano:</p>
<p><a href="http://www.pyrosoft.co.uk/blog/wp-content/uploads//2008/09/apple-homepage-2nd-ipod-nano.png"><img src="http://www.pyrosoft.co.uk/blog/wp-content/uploads//2008/09/apple-homepage-2nd-ipod-nano-400x250.png" alt="" title="Apple Homepage - 2nd Generation iPod Nano" width="400" height="250" class="alignnone size-medium wp-image-409" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/09/09/apple-homepage-4t-generation-ipod-nano/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F09%2F09%2Fapple-homepage-4t-generation-ipod-nano%2F</feedburner:awareness></item>
		<item>
		<title>When sudo echo ‘test’ &gt; /root/test gives permission denied</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/09/03/when-sudo-echo-test-roottest-gives-permission-denied/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/09/03/when-sudo-echo-test-roottest-gives-permission-denied/#comments</comments>
		<pubDate>Wed, 03 Sep 2008 22:16:53 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=402</guid>
		<description><![CDATA[If you get a permission denied error when trying to redirect the output of a sudo command then the reason for this is normally because the superuser permissions only apply to the first part of the statement, e.g. the echo command. They do not carry through to the bash redirection. 

paul@backups:~$ sudo echo 'test' >> [...]]]></description>
			<content:encoded><![CDATA[<p>If you get a permission denied error when trying to redirect the output of a sudo command then the reason for this is normally because the superuser permissions only apply to the first part of the statement, e.g. the echo command. They do not carry through to the bash redirection. </p>
<pre>
paul@backups:~$ sudo echo 'test' >> /root/test
-bash: /root/test: Permission denied
</pre>
<p>One way to get round this is to use the <strong>tee</strong> command, as follows:</p>
<pre>
echo 'test' | sudo tee -a /root/test
</pre>
<p>Note that the -a switch means append to the file if it already exists.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/09/03/when-sudo-echo-test-roottest-gives-permission-denied/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F09%2F03%2Fwhen-sudo-echo-test-roottest-gives-permission-denied%2F</feedburner:awareness></item>
		<item>
		<title>Installing Zend Framework on Ubuntu (Hardy)</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/09/02/installing-zend-framework-on-ubuntu-hardy/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/09/02/installing-zend-framework-on-ubuntu-hardy/#comments</comments>
		<pubDate>Tue, 02 Sep 2008 11:49:35 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[php]]></category>

		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=394</guid>
		<description><![CDATA[As of the 8.04 Hardy release of Ubuntu, Zend Framework has been added to the repositories, so you can install it by simply running:

sudo apt-get install zend-framework

The package installs 17M of files into /usr/share/php/libzend-framework-php/. 
Once that has finished, you then need to ensure that the framework is in your PHP include path. The best way [...]]]></description>
			<content:encoded><![CDATA[<p>As of the 8.04 Hardy release of Ubuntu, Zend Framework has been added to the repositories, so you can install it by simply running:</p>
<pre>
sudo apt-get install zend-framework
</pre>
<p>The package installs 17M of files into /usr/share/php/libzend-framework-php/. </p>
<p>Once that has finished, you then need to ensure that the framework is in your PHP include path. The best way to do this is to add the include to your PHP scripts directly, or better still via a global include file. The line you would need to add is:</p>
<pre>
set_include_path(get_include_path().PATH_SEPARATOR.'/usr/share/php/libzend-framework-php');
</pre>
<p>An example project would then look like:</p>
<pre>
set_include_path(get_include_path().PATH_SEPARATOR.'/usr/share/php/libzend-framework-php');
require_once 'Zend/Mail.php';
$mail = new Zend_Mail();
$mail->setBodyText('My Nice Test Text');
$mail->setBodyHtml('My Nice <b>Test</b> Text');
$mail->setFrom('test@example.com', 'Mr Example');
$mail->addTo('test@test.com', 'Mr Test');
$mail->setSubject('TestSubject');
$mail->send();
</pre>
<p>As Andy pointed out in a comment, Zend Framework is evolving quite rapidly, so if the Ubuntu repository version fails to meet your needs, then you could easily install and switch to a newer version for certain projects if you modify the include path this way.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/09/02/installing-zend-framework-on-ubuntu-hardy/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F09%2F02%2Finstalling-zend-framework-on-ubuntu-hardy%2F</feedburner:awareness></item>
		<item>
		<title>Hosting multiple blogs on a single WordPress installation</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/08/31/hosting-multiple-blogs-on-a-single-wordpress-installation/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/08/31/hosting-multiple-blogs-on-a-single-wordpress-installation/#comments</comments>
		<pubDate>Sun, 31 Aug 2008 14:16:10 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[blogging]]></category>

		<category><![CDATA[mysql]]></category>

		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=384</guid>
		<description><![CDATA[As you can probably tell from this blog, WordPress is my favourite blogging tool. I&#8217;ve been using it for a couple of years now, and during that time I&#8217;ve been really impressed by it. So when I was recently asked if a single copy of WordPress could be used to power several blogs, I was [...]]]></description>
			<content:encoded><![CDATA[<p>As you can probably tell from this blog, WordPress is my favourite blogging tool. I&#8217;ve been using it for a couple of years now, and during that time I&#8217;ve been really impressed by it. So when I was recently asked if a single copy of WordPress could be used to power several blogs, I was optimistic that it would be up to the job.</p>
<p>And it didn&#8217;t disappoint me&#8230;</p>
<p>There are a number of ways you can host multiple blogs with WordPress:</p>
<ul>
<li><a href="http://mu.wordpress.org/">WordPress MU (multi-user)</a> - This is system that powers all blogs at wordpress.com, Le Monde, Harvard Univeristy etc&#8230;</li>
<li>Batch management of blogs with <a href="http://birdhouse.org/software/2008/04/wp-create/">WP-Create</a> and WP-Upgrade - These scripts let you install multiple blogs in parallel, however each one would get it&#8217;s own installation.</li>
<li>Modifying wp-config.php to choose a different database per hostname. This uses the standard wordpress scripts.</li>
</ul>
<p>Since I wanted to use a standard wordpress installation, and I didn&#8217;t want to install it multiple times, I chose the 3rd option. Wordpress stores most of it&#8217;s configuration in it&#8217;s database, so all you need to do is modify wp-config.php to point at a different database depending on the hostname of the site being accessed:</p>
<pre>
// Ignore the www. part of a hostname
$host = eregi_replace('^www\.', '', $_SERVER['HTTP_HOST']);

switch ($host) {
        case 'site1.co.uk';
                $db = 'site1';
                break;
        case 'site2.co.uk';
                $db = 'site2';
                break;
        default:
                header("HTTP/1.0 404 Not Found");
                exit();
                break;
}

// ** MySQL settings ** //
define('DB_NAME', $db);    // The name of the database
define('DB_USER', 'user');
define('DB_PASSWORD', 'password');
define('DB_HOST', 'hostname');
</pre>
<p>Simply add the existing database settings code with the code above, and then create a new empty database for each blog you want to host. You will need to run the <em>install</em> scripts for each blog, e.g.  http://www.site1.co.uk/blog/wp-admin/install.php</p>
<p><strong>References:</strong></p>
<ul>
<li>Enterprise 2.0 anyone? - <a href="http://www.bos89.nl/1216">How to: multiple blogs, one Wordpress installation</a></li>
<li>WordPress Codex - <a href="http://codex.wordpress.org/Installing_Multiple_Blogs">Installing Multiple Blogs</a>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/08/31/hosting-multiple-blogs-on-a-single-wordpress-installation/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F08%2F31%2Fhosting-multiple-blogs-on-a-single-wordpress-installation%2F</feedburner:awareness></item>
		<item>
		<title>iPhone firmware update fails</title>
		<link>http://www.pyrosoft.co.uk/blog/2008/08/30/iphone-firmware-update-fails/</link>
		<comments>http://www.pyrosoft.co.uk/blog/2008/08/30/iphone-firmware-update-fails/#comments</comments>
		<pubDate>Sat, 30 Aug 2008 20:13:10 +0000</pubDate>
		<dc:creator>Paul Maunders</dc:creator>
		
		<category><![CDATA[apple]]></category>

		<guid isPermaLink="false">http://www.pyrosoft.co.uk/blog/?p=382</guid>
		<description><![CDATA[If you repeatedly get an error while upgrading your iPhone&#8217;s firmware that says something like: 
the iphone could not be restored an unkown error occured 1604
Try restarting iTunes and plugging the iPhone into a different USB port. Failing that you might need to try restoring the phone on another machine before syncing your settings from [...]]]></description>
			<content:encoded><![CDATA[<p>If you repeatedly get an error while upgrading your iPhone&#8217;s firmware that says something like: </p>
<blockquote><p>the iphone could not be restored an unkown error occured 1604</p></blockquote>
<p>Try restarting iTunes and plugging the iPhone into a different USB port. Failing that you might need to try restoring the phone on another machine before syncing your settings from the original machine.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.pyrosoft.co.uk/blog/2008/08/30/iphone-firmware-update-fails/feed/</wfw:commentRss>
		<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetItemData?uri=PaulMaunders&amp;itemurl=http%3A%2F%2Fwww.pyrosoft.co.uk%2Fblog%2F2008%2F08%2F30%2Fiphone-firmware-update-fails%2F</feedburner:awareness></item>
	<feedburner:awareness xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0">http://api.feedburner.com/awareness/1.0/GetFeedData?uri=PaulMaunders</feedburner:awareness></channel>
</rss>
