Getting WordPress MU working on a Zeus Web Server

zws

WordPress MU logo

Anyone on a Zeus web server will know that anything ‘Htaccess related’ is going to cause you a headache. After scouring the WordPress MU (or Multi-user) forums, I found lots of answered threads on exactly that. With some blood, sweat and tears I now have a working rewrite.script that does take care of most elements required.

My install of WordPress MU opted for the sub-folder option as it more closely resembles the working Rewrite.script for a standard WordPress install. Whilst the sub-domain route may be possible, this post is only looking a sub-folder install.

Below are some of the main points of the rewrite file:

  • Rewrite the location of uploaded files /files/filename to /assets/blogs.php?file=filename
  • Rewrite the “WP special files” on sub folder blogs e.g. /blog1/wp-login.php to /wp-login.php
  • Rewite the “WP special folders and their files” on sub folder blogs e.g. /blog1/assets/ to /assets/, which will fix the style sheets not appearing on the sub folder blogs
  • Rewrite the Permalink structure for all blog content (master and sub folder blogs) e.g. /blog/2009/03/15/hello-world/ to /index.php?q=/blog/2009/03/15/hello-world/

There is also a mention of Plugins in the Apache .htaccess, but I am yet to include this in. Although getting the above to work was tricky and the web void of much help, I do feel that the pieces have fit together in my head (finally!). I am more than happy to share my draft working rewrite.script, so please leave a comment.

  • stickyweb

    Yes please!!
    I’ve just encountered the vagaries of Zeus redirects (trying to port a working ecommerce site from Apache to Zeus) & I’m still some way from getting the pieces to slot together!
    Any help (i.e. browsing your draft script) would be greatly appreciated!

  • http://www.realisingdesigns.com James

    Just sent the working draft to your email, so hope it helps. The script is still working hard on my WordPress MU install and currently not spotted any problems. Will clean up and post soon.

  • Facebook User

    James, thanks so much for the script (aka the beast!). Thanks to your help, I’ve now been able to get MU WordPress and BuddyPress to work on our Zeus web server – you’re a legend fella!

  • http://www.facebook.com/people/John-Wiseman/90403486 John Wiseman

    Do I add the code to “rewrite.script” then upload to my root web directory? Also, what should the WordPress permalink structure be changed to?

  • http://www.realisingdesigns.com James

    Hi John,

    1) Yes, add the rewrite.script file to the root web directory
    2) I don’t think anything specific needs to be done re. permalinks and so you should be able to use this doc to get the structure your after: http://codex.wordpress.org/Using_Permalinks

    Pretty much the script largely tells WordPress the pages not to redirect such as the admin section, images, CSS, some of which are shared as it’s the MU version.

    Hope it works well for you.

    James

  • http://www.facebook.com/people/Nathan-Shoemark/779793327 Nathan Shoemark

    Please can I have a copy of this rewrite.script . I’ve been trying to get my wordpress mu to work for ages, but I can’t find a way to do it. I would greatly appreciate this script
    My email address is n. if you could send it to me
    Thankyou

  • Dave McEvoy

    Hey, If you’re still maintaining this I’d greatly appreciate a copy of you rewrite.script, I’ve been tearing my hair out trying to make this work. I have WPMU installed in a sub directory of a site and it’s just not happy!

    • http://www.realisingdesigns.com James

      Hi Dave,

      You certainly can have a copy and I will email you shortly. I definitely ‘works’ though might have a few little areas to iron out. I now have both a Zeus and Apache server too, so its not actively looked at by me but sure it will save you many headaches!

      James

  • Colin

    Hey mate can you forward me a copy of the script. I am having similar difficulties in rewriting permalinks on a zeus web server.

    Colin

  • Warren

    Hi James,

    I’m testing my first WPMU install today, and a copy of the script would be perfect, if you would be able to supply it as I’m having trouble trying to do it manually.

    Thanks

    Warren

  • http://www.facebook.com/profile.php?id=670837853 Mikko Wahlroos

    Hello, James!

    Have you managed to work this out? I was wondering if I could use your script as well… :)

  • Gareth

    Hi James,

    I hope you still have this zeus rewrite.script! I recently found out that my hosting company has zeus as their server. Managed to find a script for permalinks however I have just started a wpmu site and now have the problem of converting the htacces that wp give on installation. Would you be able to send me a copy please. Would be forever grateful;)

    Cheers

    • Anonymous

      Hi Gareth,

      I know that feeling and have just sent a copy of the script to your email. Please do note that I only ever attempted to work on the *sub folder* route, not sub-domain.

      James

  • David Martin

    Hi any chance you could forward this onto me, would be a great help.

    ta
    Dave

    • http://www.realisingdesigns.com James Montgomery

      Hi Dave, no problem at all – that’s just been sent to your email, James

      • David Martin

        Hi seem to have an issue with blogs that have hyphens in the name, will email over a link, but basically it can not find the images or css files, however all the links work correctly.

        • http://www.realisingdesigns.com James Montgomery

          Hey @google-c144b9c5fb608fc2fa7f8254641c35de:disqus , glad it pointing things in the right direction. I think the problem is with the lines that match [a-zA-Z0-9] … this only allows for a-Z and 0-9, so needs the hyphen added in there. I would backup the old one, then try [a-zA-Z0-9-] first and see how you get on. I am no regular expression expert, so let me know how you get on :)

          • David Martin

            perfect thanks, although im missing images any ideas?

          • http://www.realisingdesigns.com James Montgomery

            Hi Dave, I think you may need to add another – to the reg exp:

            #Blog file on sub directory
            match URL into $ with ^/([a-zA-Z0-9-]*)/files/(.*)$

            That should then bring your “in post” images back.

          • David Martin

            Hi finally found the issue:

            changed:

            RULE_FILE_START:

            set URL = /wp-content/blogs.php?file=

            set URL . %{SCRATCH:REQUEST_URI}

            RULE_FILE_END:

            to

            RULE_FILE_START:

            set URL = /wp-includes/ms-files.php?file=

            set URL . %{SCRATCH:REQUEST_URI}

            RULE_FILE_END:

            Now hopefully will never have to touch zeus again :)

          • http://www.realisingdesigns.com James Montgomery

            Great, thanks for the update and I will update the rewrite script :)

  • Dennis

    Hi James,

    May I please have a copy of your rewrite script also?

    Cheers,

    Dennis

  • http://www.facebook.com/profile.php?id=100000352279679 Warren Groom

    Hi James,

    I don’t suppose you’d mind sending me a copy of this also. Thankfully I moved away from Zeus servers about a year ago – but a client is now wanting a MU install on Zeus, so I’m trying to prepare myself as much as possible before the headache starts.

    Thanks,

    Warren

  • http://www.facebook.com/paulstefday Paul Day

    Hey James,

    Any chance I could get a copy too? I wish I had known how much of a pain Zeus could be before getting this hosting :(
    paul ( at ) paulday.com.au

    Thanks!
    Paul

    • http://www.realisingdesigns.com James Montgomery

      Hi Paul, it’s on its way over to you now.  On the plus side Zeus hosting has been ultra reliable for me over Apache (or at least the providers have been), so perhaps a silver lining for you once the pain has gone ;)

      • http://www.facebook.com/paulstefday Paul Day

        Thanks for the reply! I look forward to that silver linning. My email was not able to receive recently and it might have been on the same day you sent becasue I didn’t get an email. Could you resend? 

        Thanks again!

        • http://www.realisingdesigns.com James Montgomery

          You’re welcome, just resent that for you this morning. James

  • Sherlyn

    Hi Paul,

    Thanks for your work on this.  Any chance I could also have a copy of this script?

    Thanks,
    Sherlyn Koo

    • http://www.realisingdesigns.com James Montgomery

      Hi Sherlyn,

      Just sent a copy over to you this morning.

      James

  • Will

    Hi Paul

    Your script might be just what I need, could I have a copy too?

    Many thanks

    Will

  • Adam Huszka

    hi, could you send me the script as well, please?
    I’m having difficulties with subsites’ appearance (they appear as html links only, and the dashboard also..) 
    Hope this script will be the solution for that…  

    adam

  • Ro

    Hi could you please send me the file, it’s a real headache to get multisite up and running with zeus and wordpress 3.3.1
    Thanks in advance

    • Ro

      Hi just got your script, unfortunately it doesn’t seem to work for my clean install of 3.3.1, whilst the network setup tells me i have a network configured i don’t have any “My sites” link in the admin to create new blogs. I’ll keep at it and see if i come up with a fix, i don’t know much about Zeus, and it’s a bit of a pain…. thanks for the help
      Ronan
       

      • http://www.realisingdesigns.com James Montgomery

         Hey Ro, Zeus is not so bad in the end but does take some getting used to.  Really all features should work OK anyhow, bar the permalinks and the various rewrites for stylesheets and files.  Did you go for the sub-folder option in the setup?

  • Danjamalex

    Hi, could you send me the script please: