500 error for new site in multisite wordpress

WordPress is installed in subfolder. public_html/wordpress/
So, I want to have two sites: mydomain.com/wordpress and mydomain.com/wordpress/fr

mydomain.com/wordpress works without any problems.

Read More

When I try to go mydomain.com/wordpress/fr, I’m redirected to Page Not Found of the main site (mydomain.com/wordpress). When I go mydomain.com/wordpress/fr/wp-admin I get 500 Internal Server Error.

Here my .htaccess file:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /wordpress/
RewriteRule ^index.php$ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)??les/(.+) wp-includes/ms-?les.php??le=$2 [L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) wordpress/$2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*.php)$ wordpress/$2 [L]
RewriteRule . /wordpress/index.php [L]
</IfModule>

Here the part I added to wp-config.php:

define('WP_ALLOW_MULTISITE', true);
define('SUBDOMAIN_INSTALL', false);
define('DOMAIN_CURRENT_SITE', 'mydomain.com/wordpress');
define('PATH_CURRENT_SITE', '/');
define('SITE_ID_CURRENT_SITE', 1);
define('BLOG_ID_CURRENT_SITE', 1);
define('WP_ALLOW_REPAIR', true);

Here some settings in Network Panel for my new site:
Domain: http://mydomain.com
Path: /wordpress/fr/
SiteURL: http://archex.ca/wordpress/fr

Please, help me.

Related posts

Leave a Reply

3 comments

  1. in your wp-config.php, you want the following to setup/install the network (via the /wp-admin webapage):

    define('WP_ALLOW_MULTISITE', true);
    

    but then after you create it and click install, your wp-config.php should be edited to replace that line with:

    define('MULTISITE', true);
    define('SUBDOMAIN_INSTALL', false);
    define('DOMAIN_CURRENT_SITE', 'mydomain.com');
    define('PATH_CURRENT_SITE', '/');
    define('SITE_ID_CURRENT_SITE', 1);
    define('BLOG_ID_CURRENT_SITE', 1);
    

    i.e. you need the allow to do the setup, but then you just want enable once setup; otherwise, you get that weird db-needs-to-be-repaired error page (which it doesn’t, so drop that allow repair line); just drop the “WP_ALLOW_” in your multisite line in your wp-config.php file and it should start to work as expected

    Just FYI in case anyone does some web searching (as this is an old post, but still relevant pitfall).

  2. I was still having this 500 error (dashboard) or 400 error (visit site) immediately after creating a New Site (subdomain) through WordPress Multisite for my ‘AddOn Domain’/non-root site (/public_html/mysite.com). I looked at a ton of forums for hours and didn’t find my answer. But I changed a few things and it works perfectly now, so hopefully this can help someone out there. In addition to having a correct wp-config & .htaccess (see previous comment or other forums), I had to:

    (1) Add wildcard (*) to my Domain DNS settings

    • Type: A
    • Name: *
    • Value: [insert your IP address here]
    • TLL: (I used 10800 because my other A types were using that number)

    (2) Create wildcard (*) Subdomain & EDIT IT (cPanel)

    • WRONG (auto-created using cPanel from GoDaddy)

      • Subdomains: *.mysite.com
      • Document Root: /public_html/wildcard.mysite.com
    • RIGHT (self-edited after above)

      • Subdomains: *.mysite.com
      • Document Root: /public_html/mysite.com (took out the wildcard.)

    I’ve heard that the DNS changes can take some time to propagate, so give it some time if you had to add that to your domain. Good luck!

  3. First I don’t know if you still need help or not but it might help to someone else in future.

    Before sometime I had the same problem. I had enabled the multi site in from wordpress config file, following instructions on WordPress codex site, but getting 404 while accessing domain and 500 while accessing admin panel.

    First I solved 500 error by putting

    # Tell PHP that the mod_rewrite module is ENABLED.
    SetEnv HTTP_MOD_REWRITE On

    in my .htaccess immediately after <IfModule mod_rewrite.c>

    The 500 error is gone now, and for 404 I had created new directory to install another WordPress into it.

    Thanks to: a.l.e

    Cheers & Beers 😛