• Hello.

    I’m working on a site example.com, but I need to make sub domain: sub.example.com but both will use the main database, which I have created for example.com and sub.example.com will get posts from this database.
    I have made sub domain on hostgator, also I have setup network, and my wordpress admin panel shows both sites, there is a folder with sub domain name in public_html folder, but it’s empty, and when I access it from browser, I see only empty folder.

    Now I don’t know, have I to install new wordpress installation on sub domain folder (but it will create new database, and I don’t wont it), or is there any method to do this.

    I have deadline soon, so please help me if you can πŸ™

Viewing 8 replies - 1 through 8 (of 8 total)
  • Moderator bcworkz

    (@bcworkz)

    Just remove the empty sub-domain folder.

    When you use any sort of WP, it works by receiving server requests which do not match any specific server resource. Any time a resource actually exists, WP does not receive the request. When you use sub-domains, WP rewrites them into a normal sub-folder request. That sub-folder must not exist on the server or WP will never see the rewritten request.

    Thread Starter tsotne

    (@tsotne)

    So now I have to do:

    1. Remove empty sub domain folder.
    2. Remove network setup, and setup again.
    3. create new site in wp-admin panel.
    4. rewrite wp-config and .htaccess.

    And it will work yeah?

    Moderator bcworkz

    (@bcworkz)

    I think just #1 is enough, since you’ve already done #s 2-4 once. It should still be valid once the sub-folder is gone. If that fails by itself, try #3. #s 2 & 4 would be the same no matter what is done with other sites.

    Thread Starter tsotne

    (@tsotne)

    unfortunately not worked πŸ™
    At first I tried #1. deleted all folders with name sub.example.com, and I got server side error 500;
    Then I added new subdomain sub2.example.com and deleted folders cpanel has created for this. then added new site from wp dashboard, but I got the same server side error.
    I don’t know what to do.
    the site is: insport.ge
    and the subdomain: rugby.insport.ge

    and I have to make subdomains for all sports πŸ™
    can we speak in PM?

    • This reply was modified 6 years, 9 months ago by tsotne.
    Moderator bcworkz

    (@bcworkz)

    Sorry, no. All correspondence with me must remain in these public forums. Lets review what you should have done.
    1. Started with a single site installation where pretty permalinks work correctly.
    2. Add define( 'WP_ALLOW_MULTISITE', true ); to wp-config.php
    3. Do the “Create a Network” tool. You should have chosen a sub-domain network.
    4. On the resulting “Enable a Network” screen, copy/paste the offered code to .htaccess and wp-config.php as directed.
    5. In your hosting cPanel, add a sub-domain and direct sub-domain requests to the root WP installation. NOT a sub-folder.
    6. In WP network admin, add a site using the same sub-domain.

    The above is covered in more detail at https://ww.wp.xz.cn/support/article/create-a-network/
    but it’s light on what to do on the hosting side because what to do varies by host.

    If you can provide a link to your sub-domain site, I can see if any clues are evident from the outside. What I can see is limited, but something might stand out.

    Thread Starter tsotne

    (@tsotne)

    I can give you temporary access to the dashboard.
    login: tmpforhelp
    pass: [redacted]

    • This reply was modified 6 years, 9 months ago by bcworkz. Reason: redaction
    Moderator bcworkz

    (@bcworkz)

    Sorry, no. I will not access anyone’s dashboard. You shouldn’t offer privileged access to complete strangers on the Internet. That is very risky behavior. I appreciate you trusting me, and I certainly mean no harm, but I could still accidentally do something stupid and screw up your site. I don’t want such liability. Please delete that account or change it’s password. While I removed it here, by now it’s been scraped hundreds of times and can be found by anyone caring enough to dig for it.

    When I said I would take a look from the outside, I meant as a random visitor to the front end. I can watch my browser’s requests and your server’s responses and maybe get a clue to what’s going on. It’s not much, but a clue might present itself. In any case, I don’t know your site’s URL, so I can’t look at anything as things stand.

    can u cek my website.. what error in my wordpress.. thanks

    Situs Poker Online

    thanks brother

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Sub domained multysite with one database’ is closed to new replies.