phpwordpressmultisite

How do I host a static website inside a Wordpress multisite installation?


I would like to do the following:

Wordpress Multisite
- hosted static site in the directory but not utilising wordpress
  Wordpress additional site
  - /blog subfolder
  Wordpress additional site
  - /jobboard subfolder
  Wordpress additional site
  - /other subfolder

In short, I want to host my static website as the main Wordpress Multisite's site. It's an exported HTML Website ready to go. I haven't got time to convert it into a Wordpress site.

Is this possible, and if so, how do I go about doing it?


Solution

  • It should be possible to just drop the static website into any WordPress directory.

    This is made possible, because of the rewrite rules in the .htaccess file.

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    

    Before rewriting any request, the rewrite engine will check to see whether the request maps to an existent file or directory. If it doesn't, it passes the request to WordPress.