WordPress.org

Forums

WP Mulitsite not maping netwok correcty (9 posts)

  1. garc26
    Member
    Posted 3 years ago #

    Hi,
    Very new to WP so would be grateful for any help. On my GoDaddy installation I switched to a Multisite setup. My original single wp site was installed in /wordpress under the root folder. I made the wp-config.php and .htaccess changes and that resulted in a number of problems. As usual I can log into my site with
    http://mysite.com/wordpress/wp-admin/edit.php
    however when I click the menu items My Sites/ Network Admin/ Dashboard I get a 404 on the url
    http://mysite.com/wp-admin/network/
    however if i manually add wordpress to the url this works
    http://mysite.com/wordpress/wp-admin/network
    so it looks like either my .htaccess or wp-config.php is incorrect.

    My wp-config.php setup is

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

    and .htaccess is

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
    RewriteRule ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]
    </IfModule>
    # END WordPres

    Changeing the line
    RewriteBase / to RewriteBase /wordpress does not seem to correct it.
    Additionally the links to my origional wp blog are also broken.
    I'm on vesion 3.5.1. Any help or guideance would be greatly appreciated.

    Thanks
    GC

  2. Memnosis
    Member
    Posted 3 years ago #

    define('PATH_CURRENT_SITE', '/');

  3. Memnosis
    Member
    Posted 3 years ago #

    define('PATH_CURRENT_SITE', '/wordpress/');

  4. garc26
    Member
    Posted 3 years ago #

    Thanks for the reply Memnosis. However when I try

    define('PATH_CURRENT_SITE', '/wordpress/');
    and enter http://mysite.com/wordpress/wp-admin/edit.php
    I get a "Error establishing a database connection"

    The database is up and running so it must be some kind of config issue. Btw when I type http://mysite.com/wp-admin/edit.php I get a 404.

    Any suggestions would be appreciated.

    Thanks.

  5. Lorraine
    Member
    Posted 3 years ago #

    If you change the path in the .htaccess you also need to change the path in the relevant places in the database so that the path matches. Try looking in wp_site and wp_blog. Once they all match you should be OK.

  6. Lorraine
    Member
    Posted 3 years ago #

    Sorry, just to add, you shouldn't need to change the paths, just ensure the config file matches.

  7. You should be going to domain.com/wordpress/... for the network admin links.

    Just to make sure, you have WP installed in domain.com/wordpress/ but running from domain.com as a single site, and that was working fine?

  8. garc26
    Member
    Posted 3 years ago #

    Many thanks Lorraine !!; updating the wp_site and wp_blog to have /wordpress/ in the table path column fixed the 404 issue with wp-admin.

    However I now see another issue. As mentioned previously this was a single site that was upgraded to a multisite. I see my old site in the new manage sites menu and I can edit the old blog post. However I cannot view them. The view url in the admin panel refers to
    http://www.mysite.com/blog/2013/05/20/mypost
    Which does not work even if I remove the blog part. I also see in the wp_blog table that my post are still referring to http://www.mysite.com/?p=20 etc.
    I've seen a few reference to using a plugins to remove the blog part but not sure how to update my wp_blogs table to see my previous post again ?
    Thanks

  9. As mentioned previously this was a single site that was upgraded to a multisite.

    All multisites are single sites updgraded :)

    . I see my old site in the new manage sites menu and I can edit the old blog post. However I cannot view them. The view url in the admin panel refers to
    http://www.mysite.com/blog/2013/05/20/mypost
    Which does not work even if I remove the blog part.

    Resave your permalinks.

    Since you picked subfolders, your urls WILL be http://www.mysite.com/blog/2013/05/20/mypost

    That's just how it works.

Topic Closed

This topic has been closed to new replies.

About this Topic