FAQ — Virtual Multiblog

This page should hopefully help out with the most common questions people have. I will be adding to this page as time goes on. If you don’t find answers here or in the readme, please feel free to ask questions. :)

Q: Why are all of the blog addresses showing the same blog?

A: Most likely, the system can’t figure out the VUSER for some reason. When that happens, it uses the autoconfig info, or if you’ve set up a $vusers[] list, the first entry on that list. To confirm that it’s just defaulting to the first thing on $vusers[], move something else to the top of the list.

Similar problems can be caused if a config file has an incorrect name, so check that as well.

Q: Okay, I’ve made a folder for a second blog. Now what do I put in it?

A: Nothing. In fact, get rid of the folder. If you want a “virtual” blog in a subdirectory, that subdirectory isn’t going to actually be a folder, it’s going to be a symbolic link. (See more on Symbolic Links.)

If you’re making a virtual blog in a subdomain (e.g. newblog.example.com ) you don’t even need the symlink. Simply point the subdomain to the same location as your primary domain.

The whole point of this exercise is that all your blogs will run off a single set of WordPress files. You should never have to have multiple copies of the files in different places.

Q: Does Virtual Multiblog work with WordPress version x.x?

A: As of this writing, Virtual Multiblog 2.2.2 (with plugin v2.2) has been tested through WordPress 2.5.1. Because of the nature of the VMB system, I do not anticipate basic functionality breaking in future versions, unless WordPress radically changes the way it works.

Although people tend to refer to VMB as a “plugin” for WordPress, it really isn’t: Virtual Multiblog doesn’t run on top of WordPress, WordPress runs on top of Virtual Multiblog! (This is why I consistently refer to it as a “system” rather than a “plugin”.) Because of this, there is very little in the basic function that depends on how WordPress works. That makes it pretty future proof.

It does have some “plugin-like” functions that are more dependent on WordPress, and thus may change or break over time. At this time that code adds no major functionality beyond a diagnostic page in Admin.

Q: The new version is missing the plugin folder. What happened? Do I still need it?

A: Sorry, that’s two questions. The plugin is no longer needed as of VMB version 2.4. Before upgrading, you should deactivate the “Virtual Multiblog Support” plugin in all blogs. The easiest way to do that is to delete the file. The functions formerly handled by the plugin are still there; I just got rid of the plugin, which was acting as a bootstrap.

Q: Can the blogs have different themes and plugins?

A: Yes. Each blog runs as a completely separate install of WordPress. As such, they have separate Admin sections, separate Users, and separate settings (including which themes or plugins are active).

A: A symbolic link, or “symlink” is a type of shortcut originating in Unix-like operating systems. Basically, it is a second representation of a particular file (or in this case, directory). A symbolic link basically acts as though it is the target file or folder. In the case of this system, you can put WordPress files in one folder and make a symlink pointing to that first folder. The symlink acts as a second folder that has all the contents of the original.

As for making them, that’s a huge topic, and too big for this page. It totally depends on your system, your OS, settings within your OS, and so forth, though I can say that they can be made in Unix or Linux; I have personally made them in Mac OS X (using Cocktail); and I am informed by commenters that you can make them in Windows.

If you don’t know much about them, it might be best to ask your hosting company to make them for you. That’s what I do. :)

For further information, you might find the page at Wikipedia useful.

Q: I’ve redirected different domains to my site, and set up the config files, but the domains all show the same blog. What’s going wrong?

A: It could be many things. First off, a URL redirect will not work; the domains must all point directly to the server (or name server). Next, the server must have those domains pointing to the same directory with the install of WordPress. (In Apache the server admin would most likely set up “Virtual Hosts” that all point to the same place.)

A bit of info that might help with troubleshooting: if the system can’t figure out what VUSER to use, it will try to use the default. (If you’ve set up the $vusers[] list, the default is the first on the list.) Thus, problems determining VUSER can result in different virtual blogs displaying the same content.

Q: How do I upgrade to a new version?

Step 1: Set your configuration files aside.

Step 2: Delete the existing /wp-content/multiblog/ folder. Replace it with the new copy. Put your existing config files back into the /config/ folder.

Step 3: In the root WordPress folder, replace the old wp-config.php with the new one.

Step 4: If you have the multiblog-support plugin installed in your plugins folder, delete it. You don’t need it anymore.

NOTE: If you previously had to do strange things to your $vusers[] or table-prefixes relating to double-slashes, I think that’s fixed as of in 2.2. So if you’re having trouble, you may try undoing whatever you had to tweak in the old version. (I was never able to reproduce that error, so I don’t know what exactly caused it, but I’m hearing that it’s fixed now.)

Q: Is there a way to make it so that when you log on to one blog you’re logged on to them all?

A: Not at present. Somewhere down the line I would like to implement this, but I don’t expect it any time soon.

39 Comments

Pages: « 1 [2] Show All

  1. #21 | Posted September 8, 2008 at 2:59 pm

    Frank — I have yet to address either of those problems. At the moment they are limitations of the system.

    With the plugin, you might ask the plugin author to allow a custom directory, or you might give the different blogs different plugin directories by setting WP_PLUGIN_DIR for each. (The latter unfortunately defeats much of the purpose of the VMB system….)

  2. #22 | Posted September 12, 2008 at 4:57 pm

    Aww, that’s too bad… I was really hoping to find a solution to operating 13 blogs from one interface. The only thing is that it needed to operate on 13 separate domains (ie - stockphotoarchive.com , bathroomphotoarchive.com , bedroomphotoarchival.com , etc)

  3. #23 | Posted September 16, 2008 at 9:25 am

    James — This system will work across different domains; but each blog will have its own separate admin.

    For a single admin area, you might take a look at WordPress MU.

  4. #24 | Posted September 18, 2008 at 10:08 am

    Hi Stephen,

    I love your plugin, it’s brilliant. I am, however, also running into the limitation of a needed XML Sitemap (as well as with some Cache plugins).

    I don’t have a complete grasp on what you have done, but I thought I would throw some ideas out there. This might be complex, but I will try to explain as I think it may work.

    Would it be possible for you to setup a section, perhaps in the multiblog folder, called “blogs” or something like that, and in it you have a folder with the location of their blogs. For instance, my blogs are swingdancing.kerryjones.net, blog.swingdancing.net. So those would both be folders in “blogs”.

    Then next step would be a place or way of choosing files in the root directory that would have to be unique, and it would just call the files in the respective folders for each blog, therefore creating a unique file for each installation.

    Just an idea.

  5. #25 | Posted September 22, 2008 at 2:12 pm

    Kerry –

    The next version will support the ability to change the wp-content folder, (introduced in WP 2.6), on a per-blog basis. As you can also change the plugins folder, you could have one plugins folder but different wp-content folders for each blog. (The biggest thing I had to change there was allowing you to relocate the multiblog folder out of wp-content….)

    As for the XML sitemaps — yes, that’s something I would like to fix. Perhaps a redirect to a different file would work? Not sure…..

    Stay tuned… :)

  6. Henry Hartley
    #26 | Posted October 23, 2008 at 8:28 am

    I’ve set up four blogs using your multiblog configuration and it’s quite nice. Because the blogs are for different people (i.e. not just multiple blogs for myself) I need to insulate them slightly more from each other. For instance, they need to have separate upload directories. I mostly solved that by creating a directory outside the blog directory tree, creating an alias to it in the httpd.conf file, and changing the WordPress setting to point to that directory. Since the upload directories are owned by apache, the could, if they really want to, change their upload directory to one owned by a different blog, and I suppose they could cause problems. I think I can trust them not to do that but wonder if there’s a better solution.

    The themes directory is a bit trickier, it seems to me. If the owner of one blog decides he likes the theme a different blog owner, there’s nothing really to stop him from making it his active theme and then editing the settings, which will affect the original blog, as well. Is there some way to give them completely different theme directories so they cannot accidentally (I’ll give them all the benefit of the doubt) change someone else’s theme?

    Thanks for your time.

  7. #27 | Posted October 23, 2008 at 9:27 am

    Henry –

    You can “hard set” a different wp-content directory for each blog by defining WP_CONTENT_DIR and WP_CONTENT_URL in the config files — e.g.:

    define ( 'WP_CONTENT_DIR', '/path/to/content/' );

    If you still want them to share plugins, you can set the plugins directory to a common one for all of them, via WP_PLUGIN_DIR and WP_PLUGIN_URL.

    As for uploads, I don’t believe there is a way to “hard set” that. I don’t think it would be too hard to do, so it’s a feature I’ll consider for a future release.

    (Releases have been slow lately, as I have to make time for things that actually pay the bills….)

  8. #28 | Posted October 25, 2008 at 5:55 pm

    Hi,

    I was successfully running 7 blogs using Multiblog release 2.2.2 but when I upgraded to version 2.4 nothing works. I have reviewed the read-me multiple times and retraced by steps but cannot find the problem. In the meantime all my blogs are down.

    When can we expect your next release?

    Tks,

    Darin

  9. #29 | Posted October 27, 2008 at 10:43 am

    Darin — Did you replace the wp-config.php in the WordPress folder with the Multiblog version? Beyond that, I believe the config for 2.2.2 should be fully compatible with 2.4.

    The new version 2.5 is basically complete, except that there have been changes to configuration, and I need to add backwards compatibility for pre-2.5 setups.

  10. #30 | Posted November 7, 2008 at 10:35 pm

    A couple of questions:

    1) Will this work when my original WP install is a long-term, established website? Or does it have to be started from scratch, literally.

    2) What would happen if I deactivated it?

  11. #31 | Posted November 8, 2008 at 6:33 pm

    Iva — Yes, this will work for an established web site. You wil set it up, and for that blog create a custom config file that has the same info as the pre-existing blog.

    To uninstall the system, you would replace the VMB wp-config.php with the standard WordPress version. Thus, the blog that shows up would depend on which one you set up in that standard WordPress wp-config.php.

  12. #32 | Posted November 9, 2008 at 7:16 pm

    Thanks…and a couple more question because I am always that paranoid:

    1) [refering to your response] In that case, the other blog (I want example.com and video.example.com as there are way too many videos on the particular site) would still be able to exist on its own?

    2) Is it safe to run the install script for the second blog upon having finished the setup and having given both blogs their separate config files or would it be better to actually install the blog on a subdomain old-fashioned way and then delete redundant WP files and set up multiblog?

    3) Double-checking:
    If you’re making a virtual blog in a subdomain (e.g. newblog.example.com ) you don’t even need the symlink. Simply point the subdomain to the same location as your primary domain.

    Is this still valid?:)

    4) Would the plugins deactivated for the main domain blog, yet working on the subdomain blog, still be showing in the admin panel of the main domain blog? I assume that they would look deactivated and still be there.

    I apologise if my questions are odd, but I’m on clustered hosting with different database servers and I want to set up this so the server load would not annoy my host that much (that includes different databases, too).

  13. #33 | Posted November 10, 2008 at 9:06 am

    Iva
    1) The original blog will exist as it was if you access the same database info (which you will if you set up the config properly)

    2) No need to install twice - that would defeat the purpose. If set up properly, you can add new blogs simply by adding a new subdomain or symlink (and maybe a line to $vusers[]).

    3) Still valid. Both subdomains should point to the same root folder (set up at the server level…)

    4) Plugins will show up in the admin for both blogs. Activation status is separate for each blog.
    It’s possible to use separate plugin folders if you want to change this — but I say get things working first, then mess with that if you want. (One thing at a time!)

  14. Henry Hartley
    #34 | Posted November 10, 2008 at 11:50 am

    WP_CONTENT_DIR, WP_CONTENT_URL, WP_PLUGIN_DIR, and WP_PLUGIN_URL appear to be just what I was looking for. Thanks for the pointer. They don’t seem to be working properly but I suspect that’s my fault and mot a bug in the mutliblog system. Here’s what I did.

    In a directory outside the wordpress directory tree, I created a directory called blogname-content. I made a themes subdirectory themes copied the contents from the original wordpress/wp-content/themes directory, then deleted the themes that were not valid choices for that blog. I made a symlink in the new blogname-content directory for multiblog so that appears to be in both places. I added the four define statements to mb-config-blogname_com.php.

    When I go into site admin -> design, I still see the old themes that should have been removed. When I rename the old (shared) themes directory, ALL themes disappear from the system so it’s clearly still looking in the old location.

    As for the location of upload files being different, once I get the above problems fixed, this will be taken care of, since that’s a subdirectory of wp-content, just like themes. Anyway, I’ll fiddle and see if I can figure out what’s wrong. If anyone happens to know, please share.

  15. Henry Hartley
    #35 | Posted November 10, 2008 at 11:57 am

    DOH!

    It helps if you keep your wordpress updated to the latest version, especially when you use features that are relatively recent. The WP_CONTENT_DIR and related constants are new in version 2.6. I suspect that if I upgrade from 2.5.1, I’ll have better luck. Again, thanks.

  16. #36 | Posted November 10, 2008 at 11:41 pm

    I guess I forgot to mention the key factor: they need to be in separate databases. That is why I keep on wondering if the second blog is actually being installed. I’m sorry for being so complicated

  17. #37 | Posted November 11, 2008 at 9:35 am

    Iva — This is all covered in the documentation. If you would like me to install it for you, I am available for hire. Otherwise, **just try it**. The worst that can happen is your computer might melt into a puddle of molten slag, in which case I trust you have a backup.

  18. #38 | Posted December 21, 2008 at 1:02 pm

    Quick question:

    Is there any way to update all of the blogs in one shot with a new plugin? The way I understand it, each blog has it’s own data so it seems like this wouldn’t be that easy. I guess I am just wondering if there is an easy wordpress trick/convention for doing this semi-automatically for every blog installed under virtual multiblog.

    Andy

  19. #39 | Posted December 22, 2008 at 7:24 am

    Andy — A comment on the main VMB page answers that: link. In brief, Virtual Multiblog updates plugins exactly the same as regular WordPress.

Pages: « 1 [2] Show All

Post a Comment

Your email is never shared.

Subscribe without commenting