Create your own Marketing WordPress Network

In the last days I have been experimenting with WordPress Network, to get them running for my marketing blogs. A WordPress Network allows you to host many blogs in one WordPress installation. So it is perfect when you have a lot of blogs to manage.

Good thing is, you only need to install and configure your plugins once for the network, so you can setup a new blog within minutes.

So what are the requirements?

  • File Caching – We will have many views but not much dynamics. So I want each page to be pre-cached automatically.
  • Fast Indexing – The faster I get indexed, the sooner I can rank
  • Spam Filter – Especially marketing blogs get a lot of spam by people looking for backlinks. I don’t want to care about those.
  • Domain Mapping – A new domain for each blog

Of course we will need some additional plugins for Google Analytics, On-Page SEO, etc but they have to be configured for each blog separately.

Setup a basic WordPress Network

Okay, first we need a clean wordpress installation. To enable the blog network functionality we need to adjust the wp-config.php file and add the following line:

define(‘WP_ALLOW_MULTISITE’, true);

After this you can log in into your backend and will find the Network page in the Tools menu. Use this to install your network and follow the instructions on the next page, as you need to make some changes to wp-config.php again, as well as to your .htaccess file.

image

 

Please remark: Do NOT use the Sub-domains functionality as it will complicate things later. We will be using domain mapping anyway, so no one will see the difference.

When editing .htaccess please change the following: WordPress will ask you to edit (or create) the .htaccess file and put some contents in it. Before doing that Add # BEGIN WordPress and # END WordPress around it. So it will look like this:

# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]

# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ – [L]
RewriteRule  ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule  ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
# END WordPress

If you log in again you will now find the Super Admin Menu on the left. That’s it, your blog network.

Create a test blog in your network

That’s really easy. Go to Super Admin –> Sites. There you can create a blog we can use for testing.

image

Setup Domain Mapping

All your new blogs will be in a sub directory on your network site. This is not just a bit ugly, but also bad for ranking. So we need to fetch the WordPress MU Domain Mapping plugin. You cannot install it using the plugins screen in wordpress, you will have to do it by hand. There are two files you need to place

  • Create the directory wp-content/mu-plugins
  • Put domain_mapping.php to wp-content/mu-plugins/
  • Put sunrise.php to wp-content/

image

And add the following line to your wp-config.php

define( ‘SUNRISE’, true );

Now we can configure the domain mapping plugin:

image

That’s it.

How to map a blog to a domain

Easy. First you need to log into your blog. Either go to your blog, in my example http://network.denniskempin.com/test/ and log in to the admin panel. Or use the faster way:

In your Super Admin –> Sites menu you can click on Backend of each blog to get to the admin backend of each blog.

In Tools –> Domain Mapping you can set the primary domain for your blog:

image

Remember that you have to set up the blog domain to point to the network domain. In Dreamhost this is called mirror, at other hosting companies it might be called alias.

File Caching

The Database at my hoster is really slow. And I don’t want people to wait for my websites especially not google. Since marketing blogs are usually not very dynamic we can use file caching. Each page of your blog is only created once and then stored to a file on the hard disk of the server.

Use the Plugins backend of your network to install “WP Super Cache”. Nice thing: You only need to configure it once and it will be used for all your blogs. Just select “Network Activate” instead of “Activate” in the plugins screen.

At Super Admin –> WP Super Cache we will make some adjustments. Go to the Advanced Tab and set it up like this:

image

This will create a compressed cache and serve them without involving PHP which will make things really fast.

After clicking on “update status” you will see the warning “Rewrite rules must be updated”. Scroll down and hit “Update Mod_Rewrite Rules”.

One last thing. We will need a plugin for the plugin as we are using domain mapping. Enable it.

image

 

Fast indexing

This means we need a sitemap. Sadly, there is no sitemap plugin at the moment that works totally fine with domain mapping. But we can try using the beta of the google xml sitemaps plugin. Grab it here:

http://www.arnebrachhold.de/redir/sitemap-dl-beta/

Install it in your admin panel and activate it. It works out of the box for me, just “Network Activate” it. Test it by opening pointing your browser to http://yournetwork.com/sitemap.xml and http://yourhostedblog.com/sitemap.xml.

Spam Filter

Askimet is great, actually awesome. It requires a wordpress.com account to get an API key. After that you will barely notice any more spam on your blogs. By default you have to setup askimet for every single blog, but you can also add

define(‘WPCOM_API_KEY’,’your wordpress.com API key’);

To your wp-config.php file so it will be working sitewide, so you can “Network Activate” this plugin.

That’s it

Well setup is a bit tricky sometimes, it took me a long time to find all those options for setting up the plugins for networks instead of single blogs. So I thought it is a good idea to share it. So what do we have?

We have a network of blogs on different domains, managed through one login into the backend, fast through caching, without spam and fast indexed by google using sitemaps.

What now? Well there are still some plugins that would be very useful. Like

Duplicate Content Cure, Ultimate Google Analytics and All in One SEO Pack. These plugins can all be installed and activated network wide. But of course you have to setup you Analytics ID and the All in One SEO options for each blog separately.

Any suggestions to this setup? Any plugins that would be useful? Please tell me if you find this useful.

This entry was posted in Experiments. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.