Holy Molé! Where's my blog WP 2.5!

When I installed WordPress 2.3.3 I found a hack that allowed me to used the same user database across all installations.  This way you kind people who read and will eventually comment on my musings would be able to just jump from one to the other with the same user name, password and capabilities.  You still have to log in to each one (one hack I haven’t successfully found yet), but you wouldn’t have to register at each. 

Yesterday I noticed that my WP install was out of date.  All the new features of 2.5 looked so good that I wanted to upgrade right away.  So, I decided to upgrade garden.earthformed.com first since it is still mostly in development.  I used the WPAU auto upgrade plugin.  What I did not like is that you cannot cancel the install once you’ve begun – even before you download any WP files.  I wanted out so I could do a manual backup of my files and my database (which like an idiot I didn’t do first, I got too anxious).  So, I let WPAU do it’s thing.  Then I came to the database upgrade and this is where the “holy ****” comes in. 

The hack I used to allow the same users for all blogs is used by blog.earthformed.com and thebabyfund.com.  If those user tables are removed or changed in any way I’m screwed.   And as predicted, I was in trouble.  When I tried to even open blog.earthformed.com to see what had happened it wouldn’t even load.  I couldn’t log into garden.earthformed.com either.  Oh, crap.  Upon trying to unzip the backups made by WPAU I encountered another serious issue.  My PC was blocking opening the file because it came from another PC.  Never had that happen before.  So I went to the file properties and unblocked the zip file.  Still won’t decompress.  Thankfully I have another PC limping next to this one (they both act strange on occasion; we are running bets on which will die first).  Went to download.com and found the latest WinZip release.  This finally allowed me to open the zip files. 

So I used FileZilla to upload my old files back to the server and logged into my PHP admin to import the old database structure – my posts, tags, categories, etc. for three now dead blogs.  This is where my impatience and lack of planning really knocked me in the gut.  MySQL did not like the syntax of the backup.  I had to manually go through and find every dash, comma, space, etc. that it didn’t like and delete it without deleting anything important.  Unfortunately, I had to drop a few plugins tables that were causing all kinds of problems.  My basic info was still in tact. Hallelujah!

I then went in search of a hack or official instructions on how to turn WP into a multiblog environment.  What I’d like to do is to have separate themes, separate plugins, and still use the same users across all blogs – under one administrative interface.  Someone came up with an idea, too, for allowing cross posting from one administrative interface.  Yummy! 

I checked out WP’s support and forums and came across and ideas post that gave a few suggestions.  Unfortunately, I don’t think they will work well with 2.5.  I have a feeling they will work with 2.3.3. User and moderator Kaftkaesqui came up with the beautiful hack I’m using, but there has been no update for using the same thing in version 2.5. 🙁

So, for the time being I’m stuck with version 2.3.3.  Not bad for you, just a pain for me.

Hi Everyone,

This is just the topic I’ve been looking for. Currently I have 3 WP 2.3.3 installs using the same user database. This works OK, but I still can’t keep them logged in across DB’s. Now, since I am a novice at PHP I’m gonna need some guidance with the PHP code shown above:

Is this the code you intend from your second post?

<?php $sitename = strtolower( $_SERVER['SERVER_NAME'] ); if ( substr( $sitename, 0, 4 ) == 'www.' ) { $sitename = substr( $sitename, 4 ); } switch ( $sitename ) {( $_SERVER['SERVER_NAME'] ) { case 'server1.com': // <- your first site define('DB_NAME', 'database'); define('DB_USER', 'user'); define('DB_PASSWORD', 'xxxxx'); define('DB_HOST', 'localhost'); define('DB_CHARSET', 'utf8'); define('DB_COLLATE', ''); $table_prefix = 'wp_'; define ('WPLANG', 'es_PE'); break; case 'server2.org': // your second site define('DB_NAME', 'database'); define('DB_USER', 'user'); define('DB_PASSWORD', 'xxxxx'); define('DB_HOST', 'localhost'); define('DB_CHARSET', 'utf8'); define('DB_COLLATE', ''); $table_prefix = 's2_'; // you can just change the prefix define ('WPLANG', 'es_PE'); break; // here add more case [...] break; default: // keep a default just to be safe define('DB_NAME', 'database2'); // or just change the database define('DB_USER', 'user2'); define('DB_PASSWORD', 'xxxxx'); define('DB_HOST', 'localhost'); define('DB_CHARSET', 'utf8'); define('DB_COLLATE', ''); $table_prefix = 'wp_'; define ('WPLANG', 'es_PE'); } define('ABSPATH', dirname(__FILE__).'/'); require_once(ABSPATH.'wp-settings.php'); ?>

From the additional code you’ve added does this mean that there will be 4 iterations in addition to the default which can be changed at any time to a smaller or larger nubmer. As far as you know will this hack allow the functionality of cross posting, using same user db and keeping those users logged in across databases and also maintaining separate designs for each? How does this work for plugins? Will the plugins all be pulled from one repository? If so, if I decide to deactivate it in one DB will it deactivate for all? Do I need to do any ‘hack’ of the php files such as settings and config?

Posted: 14 hours ago #

  • geckospyker

    Sorry about my last question – this is the config file – duh! But are there any other files that must be changed?

    Posted: 14 hours ago #

  • Leave a Reply

    Your email address will not be published. Required fields are marked *

    CommentLuv badge