• Jeremy

    (@jmalais)


    Hello everyone. I am trying to set up a complicated multi-site network which would allow me to have a base domain for the organization and multiple sites for varying services. One such service I would like to run another multi-site off of and allow users to create their own sites. Here is the structure I am trying to achieve:

    • domain.com
    • service.domain.com
    • service.domain.com
    • sites.domain.com
    • sites.domain.com/site1
    • sites.domain.com/site2
    • sites.domain.com/site3

    What is the best way to do this, I’ve tried the multi-network plugin which appears to be outdated, but it doesnt allow for the 2 forms of site URLs (subdomain or subdirectory). I have looked at doing the shared users with CUSTOM_USER_TABLE and CUSTOM_USER_META_TABLE, but it doesn’t seem like roles can be easily established for allowing multisite editing on only their own site. I can’t seem to find a good plugin for syncing users or cookies across sites. I’m also not sure how to go about domain mapping to achieve this when using a wildcard subdomain multisite setup.

    • This topic was modified 5 years ago by Jeremy.
    • This topic was modified 5 years ago by Jeremy.
    • This topic was modified 5 years ago by Jeremy.
Viewing 3 replies - 1 through 3 (of 3 total)
  • autotutorial

    (@autotutorial)

    The multisite uses url rewriting rules and this indicates a type of htaccess for subdirectories and another type of htaccess for subdomains … at the same time they cannot be used.
    With the installation on subdomain or subdirectory the cookie from the network is accessible to all the subdomains.
    Different speech when mapping a domain
    Network domain.tld
    Secondary site (subdomain) ns1.domain.tld
    Mapping (secondary site of one network) any.domain.com
    If the mapping is different from the network domain, you will encounter a cookie block.
    This define('COOKIE_DOMAIN', $_SERVER['HTTP_HOST']); for mapping from subdirectories and define('COOKIE_DOMAIN', ''); for mapping subdomain.

    Thread Starter Jeremy

    (@jmalais)

    So is the recommendation to have 2 separate installations of multisite, one on domain.tld and another on a ns1.domain.tld, use the define cookie functions and share the user databases with CUSTOM_USER_TABLE and CUSTOM_USER_TABLE_META functions?

    autotutorial

    (@autotutorial)

    It is difficult to recommend something if you do not have all the code you have your eyes on, for example the multinetwork plugin (not updated for a long time) allows you to use more than one network and make multisite variables dynamic (in wp-config.php the plugin indicates not to use COOKIE_DOMAIN constant)
    without plugins you can create secondary sites on subdomain (except the www).
    The best way is to try
    Network1 domain1.tld
    secondary site sub1.domain.tld
    Metwork2 domain2.tld
    secondary site sub2.domain.tld

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Complicated Multi-site / Multi-network Help’ is closed to new replies.