bossbowser
Forum Replies Created
-
Ok we’ve got to the bottom of the issue.
The server was running NGINX the whole time thus the .htaccess rewrite rules were simply not being taken into account breaking the backend virtual paths!
Many many thanks to both Ipstenu and jkhongusc for their patience and expertise.
IF YOU’RE READING THIS SEARCHING FOR ANSWERS PLEASE CHECK WITH YOUR HOSTING PROVIDER IF YOU ARE RUNNING NGINX!
WHY are you renaming a site on your network at all, when you have a clean install of WP?
Originally when we came across the problem after some research w then went into the settings and changed the siteurl and home. However as we have both seen this did not work.
After you advised TO NOT change anything in the settings I wiped the server and all databases and started from fresh.
Now all sites are created and named via the ‘Add a new site’ section in the backend and given the site title and nothing changed in the settings. To confirm I am NOT renaming the site in the settings since you first pointed out this will cause issues.
Unfortunately it does not appear that our server is running NGINX but just to double check I’m awaiting our hosting guys to go over this.
I appreciate everyone helping so far. This is driving me crazy, and in all my years of using the trusty steed that is wordpress I have never had an issue like this go on so long!
Mika, to be clear are you suggesting a seperate wordpress install for each capital city; Or something different?
https://www.domain.com/london
https://www.domain.com/berlin
https://www.domain.com/paris
etc…? Am I missing something very very simple here?The reason we must use a multisite setup is that each post MUST have the permalink setup for seo reasons of something like https://www.domain.com/london/clubs/post-name – https://www.domain.com/paris/clubs/post-name – https://www.domain.com/berlin/post-name
All of which must be subdirectory so that link juice flows through the entire domain.
I’m looking into whether our server is running NGINX now…
Are you sure your web server is configured to allow htaccess files. You are having a rewrite problem. Those rules are in the htaccess file. The easiest way to check if htaccess is enabled is putting junk at the very top
Indeed that does break the .htaccess and supplies a 500 server error so we can be sure that .htaccess is being read by the server.
You can see here how weird and frustrating this problem is!
Here’s the real question. Why do you need to do this at all?
Look, if I want a site named london, I make a site named london and I leave it the heck alone! There’s no logical reason to rename a site.
The reason for this is we are representing capital cities around the world and each will be geotargeted through google webmaster.
That’s where it’s supposed to look!
Surely this is just WordPress creating ‘virtual’ paths? Rather than placing and requiring the files from there. I just can’t see how the following debug gives a 404 (https://s22.postimg.org/qe7qwo3kx/debug.jpg) when you say it’s meant to be looking there?
I replaced the htaccess file with the one supplied by jkhongusc. I still have the same issue.
Has anyone come across this issue before?
/* Multisite */
define(‘MULTISITE’, true);
define(‘SUBDOMAIN_INSTALL’, false);
define(‘DOMAIN_CURRENT_SITE’, ‘www.domain.com’);
define(‘PATH_CURRENT_SITE’, ‘/’);
define(‘SITE_ID_CURRENT_SITE’, 1);
define(‘BLOG_ID_CURRENT_SITE’, 1);# BEGIN WordPress
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]
# END WordPressYou can see here what I’m referring to in regards to broken links on these two screen shots
https://s29.postimg.org/alhukxhk7/image.jpg
https://s22.postimg.org/qe7qwo3kx/debug.jpg
As mentioned above, we’ve followed the setup step by step, and have multisite setups on other projects (although in subdomain format). Even for highly skilled php programmers we cannot see why this would be?!
Hi Mika,
After taking your advice I completely wiped the server starting afresh following the install step by step.
On the creation of each site on the options I did as you told me and did not change the settings tab, just in the edit tab setting the path to /london/ and hey presto! It’s still the same issue.
The wordpress backend for london is still 404’ing it’s own files looking in https://www.domain.com/london/wp-includes/js/filename
This is driving me crazy. Of course I could just create a subfolder on the server and put in the files it’s trying to pull in but surely this would defeat the point of one install???
I appreciate your help thus far.
I’ve also come across this online which seems to be the same problem I’m encountering https://premium.wpmudev.org/forums/topic/network-admin-menu-links-broken-upon-35-subdomain-multisite-install-subfolder-wp-install
Also I just tried to create a new site a moment ago just to test it. With the site address as https://www.domain.com/newsite with the user set to my superadmin. It creates it no issue, but then when I then go to this sites dashboard any file wordpress tries to call eg css, javascript etc is a 404 in the console of chrome due to wordpress trying to find files in `https://www.domain.com/birmingham/wp-admin/css/colors.min.css?ver=3.8.1
Failed to load resource: the server responded with a status of 404 (Not Found) `That then breaks the back end and the front end as the all paths are the equivalent to https://www.domain.com/london/wp-content/themes/cluboid/images/scroll-top.gif.
But interestingly the backend ‘edit posts’ and other such buttons work.
I know I could copy wp-content into a london directory on the server to fix this issue, but surely this defeats the point of child themes and multisite!?
Yes in the settings tab.
Apologies, I meant that https://www.domain.com is the multisite, and London, Paris, and Berlin are sites on the network. Please advise.
Forum: Networking WordPress
In reply to: 500 Internal Server Error when I click Dashboard linkI had an issue with the .htaccess on this one. Did you follow the setup and overwrite your .htaccess? – Mine was wrong as it HAD to be saved as ANSI and have the wordwrap UNSELECTED.