WordPress.org

Ready to get started?Download WordPress

Forums

.htaccess and permalinks clashes (11 posts)

  1. niklasbr
    Member
    Posted 2 years ago #

    I am setting up a WordPress multisite site using subfolders like this:

    Site One: example.com/site_one
    Site Two: example.com/site_two
    Site Three: example.com/site_one/site_three

    Site One and Site Two works fine, Site Three looks fine when I look at the database tables, but visiting example.com/site_one/site_three results in a 404 error, from my testing I can work out that all example.com/site_one/* addresses are being interpreted as parts of example.com/site_one and that this takes priority over sensing which address belongs to a subsite. How do I make WordPress recognize example.com/site_one/site_three as a subsite and not a Page belonging to example.com/site_one?

  2. Jackson
    Member
    Posted 2 years ago #

    Check this out:

    ...our solution has been to redirect URLs in Apache (or IIS in your case). In your example, we'd create a site at /research/ and another one at /research-cep/, then redirect the /research/centers/cep/ URL to /research-cep/ from within IIS/Apache (that way it is handled before WordPress sees the request).

    http://wordpress.org/support/topic/nested-sites-without-multiple-installations?replies=7

    So basically, you need the proper rewrite rules to direct example.com/site_one/site_three to example.com/site_three

    Good luck and please post your results.

  3. Site Three: example.com/site_one/site_three

    That's not what site_three should be.

    Site Three: example.com/site_three

    How did you make it a 'child' off Site_one?

  4. niklasbr
    Member
    Posted 2 years ago #

    Site Three: example.com/site_one/site_three

    That's not what site_three should be.

    Site Three: example.com/site_three

    How did you make it a 'child' off Site_one?

    Sorry, I was not clear enough. A "child site" was just my way of saying that there is a setting (a meta key) that we set for each blog with update_option("blog_parent_id", $blog_parent_id_integer), these are used to generate a breadcrumb trail for each site so that the breadcrumb trail on Site Three looks like this:

    Main Site > Site One > Site Three

    Because Main Site is the parent of every site and Site Three has the meta value where the id of Site One is stored under the setting for blog_parent_id.

  5. Ahhh. Okay, what you're doing is kind of making a MultiNETWORK. Which you can do, but the way you're doing it is a little incomplete, I think.

    You may want to try doing that instead with http://wordpress.org/extend/plugins/wp-multi-network/

  6. none of the multi network plugins support nested subFOLDERs.

  7. niklasbr
    Member
    Posted 2 years ago #

    True that Andrea_r, we discovered so during the research phase, this is why we only use WordPress core functionality for subsites.

  8. Augh. I keep forgetting that, Andrea! *self-whap*

    this is why we only use WordPress core functionality for subsites.

    But you're not. I mean, this ISN'T core functionality really. It's semi-functional (as you're experiencing).

  9. this is why we only use WordPress core functionality for subsites.

    multiple network support *is* core functionality. ;)

    Nested subfolders is server side. Not something very many people have done, and I'm not one of 'em.

    (nested subdomains, yes)

  10. niklasbr
    Member
    Posted 2 years ago #

    Multisite is part of the default WordPress install and documented on Codex. Where does it say that it is only semi-functional?

  11. We're all talking sideways semantics.

    MultiSite is core to WordPress.

    MultiNETWORK (i.e having sites that are CHILDREN of other sites) is core functionality, but only works well with nested subdomains. Which is why I hesitate to call it core functionality.

    If you were trying to make siteone.domain.com/sitethree, yes, that's easy and possible.

    But making domain.com/siteone/sitethree, as you've seen, is a head-banging issue unless you happen to know how Tim did it in that post way up above that Jackson linked to.

Topic Closed

This topic has been closed to new replies.

About this Topic