• I run a bunch of sites under a few country domains, ie:
    https://www.mydomain.com
    https://www.mydomain.co.uk
    https://www.mydomain.de
    https://www.mydomain.fr
    https://www.mydomain.be
    etc.

    All of those URLs run the same mutlilanguage web application. For instance:
    https://www.mydomain.co.uk/en contains the app’s version for the UK, in English
    https://www.mydomain.fr/fr contains the app’s version for France, in French
    https://www.mydomain.com/en contains the app’s version in English, for countries other than the UK
    https://www.mydomain.com/fr contains the app’s version in French, for countries other than France
    etc.

    I would like to run a blog for each site+language and power it with WordPress, so that:
    https://www.mydomain.co.uk/en/blog would host a blog in English for the UK
    https://www.mydomain.fr/fr/blog would host a blog in French for France
    https://www.mydomain.com/en/blog would host a blog in English for English-speaking countries other than the UK
    https://www.mydomain.com/fr/blog would host a blog in French for French-speaking countries other than France
    etc.

    I would rather avoid having to install multiple WordPress instances to host every one of those blogs. So, what I have done is:
    – I have installed WordPress Multisite at one of my domain’s root (sub-directory based option) – latest version as of today
    – I have also installed MU Domain Mapping – latest version as of today

    This is apparently working fine. I have then created a first Site, for the blog that would run under https://www.mydomain.com/en/blog

    I have done this in two steps:
    – First, I create a new site (My Sites->Network Admin->Sites->Add New)
    – On the site address, I enter “en” (since it won’t let me enter the full “en/blog”, I give it a Title and Admin Email, and Save.
    – I then edit the site’s URL (My Sites->Network Admin->Sites->Edit) and add the /blog end, so that it reads: “https://www.mydomain.com/en/blog” as desired.

    However, when I first created a new Post, the Permalink that WP would propose was of the form “https://www.mydomain.com/blog/…”.

    After some googling, I managed to get rid of the “/blog” part by editing the main installation’s Permalink settings. But I have never managed to make WP build a Permalink that would prepend the site’s URL path “/en/blog” to the post’s name.

    Apparently Permalink settings exist at two levels:
    – The main installation’s settings (https://www.mydomain.com/wp-admin/options-permalink.php, accessible via the general Dashboard->Settings->Permalink)
    – Each site’s individual settings, accessible via My Sites->Network Admin->Sites->Edit and then selecting the Settings tab

    I have tried tweaking both of those in all ways that would seem reasonable to me, without success. I really can’t grasp how these two work together.

    I tried setting the new site’s Permalink settings to “/%postname%” expecting that WP would automatically prepend the site’s “/en/blog” path, but all I would get was “https://www.mydomain/en/my-post-name”.

    I also tried setting it to “/en/blog/%postname%” with the same result.

    Any help would be much appreciated, I’ve been hours with this w/o success.

The topic ‘Multisite permalinks not working as expected’ is closed to new replies.