• Hi

    I would like to know how to ensure my public site domain link remains valid whilst allowing membership site to also redirect correctly

    Existing site: – REDIRECTS TO NEW SITE (This is wrong)
    https://hongernaarmeer.nl/hmm – the below is not on the home directory but in hnm)
    1. .htacces line reads – RewriteRule . /index.php [L]
    2. Index.php reads – /** Loads the WordPress Environment and Template */
    require(‘./hnm/wp-blog-header.php’);

    Example of a URL that is broken because it goes to “launch1” which is defined as the root domain (https://hongernaarmeer.nl)
    https://www.hongernaarmeer.nl/hnm/cambridge-dieet

    Root Domain URL (New Membership Site) – WORKING URL
    https://hongernaarmeer.nl/
    1. .htaccess line reads – RewriteRule . /index.php [L]
    2. Index.php reads – /** Loads the WordPress Environment and Template */
    require(‘./launch1/wp-blog-header.php’);

    Please advise how to edit the above files correctly so that traffic for both “launch1” (which currently works and “hnm” (which is broken) can reach their respective destinations?

    Thanks in advance

    Phil

    P.S. I followed the https://codex.www.ads-software.com/Giving_WordPress_Its_Own_Directory exactly but I cannot see how to edit for 2 WP sites

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter philsquires

    (@philsquires)

    Bump??

    I’ma bit confused on the workings here…
    You give wordpress it’s own directory if index.php is in root, and the files are elsewhere

    So both installs can’t have their index.php in root correct?

    So for the first install, are all the files including the index.php in the hnm directory?

    If so, there is no need to edit the index.php per the ‘own directory’ instructions….

    index.php in the hnm directory doesn’t need to point to require(‘./hnm/wp-blog-header.php’);

    if index.php is IN the hnm directory

    the default index.php would be what is needed

    The only time the index.php needs edited is if the index.php and the files are in different directories

    Thread Starter philsquires

    (@philsquires)

    OK thanks this was helpful…

    Just needed to bounce this off someone and realised my error. Within Dashboard/General I was pointing hnm to the root domain which was causing the conflict as the index.php in home directory was heading off to NEW “launch1” WP install

    Thanks for your time….

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘2 WP sites – Editing index.php for NEW site affects the other site’ is closed to new replies.