Support » Installing WordPress » WordPress in domain path subfolder

  • Hello,

    I would like to install multiple WordPress into subfolders, which are visible to users, so that I have:
    example.org/wordpress1
    example.org/wordpress2

    I couldn’t find a documentation for that. Any tips? In my default setup most assets links are incorrectly example.org/wp-content/…

    Thanks,
    Roland

Viewing 4 replies - 1 through 4 (of 4 total)
  • https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

    With above note you can just make the Site Address and WordPress Address a sub folder.

    You might want to read up in WordPress networks tho, makes updating n managing multiple sites easier.

    Hallo David,

    thanks for the answer. This does not fully cover my use-case.

    I have the following general setings:
    WordPress address (URL): http://example.org/wordpress1/wp
    Site address (URL): http://example.org/wordpress

    Page urls are now correctly generated for the backend and frontend.
    Asset urls are still wrong. so the static style url is still:
    /wp-content/themes/onesocial/css/admin.css?ver=1.1.4 instead of
    /wordpress1/wp-content/themes/onesocial/css/admin.css?ver=1.1.4
    http://prntscr.com/hb9kfi

    The link to all media assets is also missing the folder “wordpress1”.

    How can I solve this?

    Thanks in advance,
    Roland

    • This reply was modified 3 weeks, 5 days ago by  RolandSchuetz.

    linking to a resource stylesheet by WordPress standards, is done with a core function, like get_bloginfo('stylesheet_directory') which uses the WordPress address value to build a relative URL. This is all setup this way so tasks (like you’re after) are easily accomplishable. I can’t view the source code of your theme (as it’s premium) to check the code, but I assume it’s authored correctly, so your stylesheets and resources should be loading the new path. Without knowing more, I assume it’s a caché, your browser might of not noticed the change. Try on new browser or in private mode.

    As for inline things, like LINKS and IMAGES within your pages/posts text, they’re just static values stored in the database. So you’ll need to change those urls – there’s a few plugins that can do that for you if you don’t want to do find+replace on the database: https://wordpress.org/plugins/search-and-replace/

    Also double check your htaccess file has updated / is correct, and be sure you only have one if your Site URL and Home Address are different. You can review htaccess file and where it should be in Settings > Permalink. Saving a change in that settings page also flushes your rewrite cache, which is handy when troubleshooting.

    This article explains how to point to a level up from where WordPress is installed.
    https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

    • This reply was modified 1 week, 2 days ago by  dtlevin.
Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.