Now that everything’s set up, it’s time to get those users!
H
OWD
OU
SERSS
IGNU
P?
Provided you allow for user registration, visitors can go to http:// example.com/wp-signup.php and register for a new account.
They will be emailed their password, and cannot access the site without activating their account.
You cannot activate an account for a user, even as a super admin, so if they don’t get the email, or don’t reply, it can get messy, as the only way to purge out the activations is through the database.
If you allow users to create an account and a blog at the same time (called ‘Open Registration’) the form includes the following option:
If you have a subdomain install, going to http://fakesub.example.com will send you to http://example.com/wp-signup.php?new=fakesub and allow them to register, with an additional note:
H
OWD
OU
SERSC
REATEN
EWS
ITES?
If the user is creating a new site when they register, they have the option to click on ‘Gimme a site!’ when they pick their user name. By default, the user name is filled in as the blog name, but that can be changed.
If the user is creating a site after they made an account, they simply go back to http://example.com/wp-signup.php and fill in this form:
This form is also what you see if you want to create additional sites. There are no default limits to how many sites a user can make, but you can limit them via plugins.
T
HED
IFFERENCEB
ETWEENAB
LOG ANDA
M
ULTISITEB
LOG?
When you run your own single install of WordPress, you’re actually the ‘Super Admin’ of your site! When you’re a site admin, you have slightly fewer powers. It’s easier to explain what you can’t do as a Site Admin:• You can’t change the URL of your site. • You can’t move the location of media files. • You can’t use ‘embed’ codes for videos6
• You can’t post by email.
• You can’t install plugins or themes. • You can’t edit plugins or themes.
As you can see, there are limitations, however most of these cause no issues to your site admins.
Chapter 11
FAQ
Before we get to the advanced topics, let’s take a moment to go over the most common questions.
W
HERE ARE MY SITES?I
DON’
T SEE THEM ON MY SERVER!
If you mean ‘Why isn’t there a folder called sitename on my server?’ the answer is that they are virtual.
Just like you can’t see the ‘files’ for posts and pages on your server, everything that contains the information for your site on a network is in the database. The only files that are uploaded are images.
A
LL MY IMAGES UPLOAD TO FILES,
BUT THERE’
S NO FILES FOLDER!
That’s okay! Your images on subsites upload into /wp-content/ blogs.dir/#/files and, through the magic of .htaccess, they are redirected from http://site2.example.com/files to http://example.com/ blogs.dir/2/files/
How does that work?
In your .htaccess there’s a line like this:
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp- includes/ms-files.php?file=$2 [L]
That line says ‘Any URL that goes to /files/ should be redirected to /wp-includes/ms-files.php instead’
And it’s that file which detects what site you’re coming from, where the image actually is, and outputs it for your visitors.
By the way, don’t make a folder (or file, or page) named ‘files’ or you’ll break the redirect magic.
C
ANI
MAKE AN EXISTING SITE INTO AM
ULTISITE?
Sure, but there are caveats.By default, WordPress will only let you turn on subdomains if your site has existing for more than 60 days. This is to avoid possible conflicts between pages on your main site and your new subsites. You can change that (just change the value for ‘Subdomains’ when you define it in your wp-config.php), however remember that your URLs for posts will have /blog/ prepended to them, and that can cause 404s on your site. This can normally be fixed with some .htaccess magic.
W
HY IS THE THEME NOT WORKING ON MY SUBSITE?
If you get unstyled content on your subsites, where all you see is the content but no theme formatting, the odds are your server isn’t reading your .htaccess file correctly. Normally that occurs when mod rewrite isn’t enabled (though if you verified that pretty permalinks work before you turned on Multisite, you know they are), or that your httpd.conf file doesn’t have AllowOverride set to ALL.
If you don’t know how to edit that file, or don’t have access, ask your webhost.
H
OW BIG IS MY DATABASE GOING TO GET?
That depends on how you look at it. For every site you create on your network, you will have, minimum, nine new tables created. That can add up pretty fast, especially if you have open registration. Normally, however, this isn’t a problem, as most sites are relatively small.
H
OW BIG IS MY SERVER GOING TO GET?
Depends on how many images people upload, and how big they are. But yeah, that can get big too.
W
ILLM
ULTISITE MAKE MY SERVER SLOWER?
Indirectly. See, the more sites you have on your server, the more traffic you have. The more traffic, the slower the server, unless you optimize it. There are minification and caching plugins that can help, but also sitting down and tuning your server will help exponentially.
H
OW DOI
KNOW WHICH PLUGINS ARE SAFE TO USE ONM
ULTISITE?
Most plugins work just fine if you activate them per-site. Some plugins don’t. If a plugin is tagged ‘multisite’ or ‘wpmu’ in the official plugin
repository, it’s a good bet that it’ll work. If it’s not, well, you have to experiment a little. Always read the full documentation on a plugin before installing!
C
ANI
INSTALLM
ULTISITE IN A SUBFOLDER?
Sure, with caveats.• You can’t map domains
• All your URLs will contain that subfolder name. Same thing for subdomains.
C
ANI
USE‘
GIVINGW
ORDP
RESS IT’
S OWN DIRECTORY’
WITHM
ULTISITE?
As of WordPress 3.5, yes you can. If you want to install in http:// example.com/wordpress but have your main site use the URL http:// example.com then just install it like you normally would in that case and set up the ‘own directory’ before Multisite. Otherwise you have to move Multisite, and that’s not really easy.
C
ANI
MAKE ALL MY SITES USE THE SAME MEDIA LIBRARY?
No. No plugin currently exists that permits this, and it’s out of the scope of Multisite.