Title: Subfolder installation
Last modified: August 22, 2016

---

# Subfolder installation

 *  [cristiano.albano.p](https://wordpress.org/support/users/cristianoalbanop/)
 * (@cristianoalbanop)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/subfolder-installation-2/)
 * Hello, Im using the plugin and my WP is installed in a subfolder. The SEO 301
   metabox display [http://www.example.com/site](http://www.example.com/site). My
   SITEURL is [http://www.example.com](http://www.example.com) according [WordPress Codex](http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory#Using_a_pre-existing_subdirectory_install).
   I think that the plugin is reading WP folder to generate the redirects, but this
   throws a 404 error.
 * Thanks in advance.
 * [https://wordpress.org/plugins/wp-seo-redirect-301/](https://wordpress.org/plugins/wp-seo-redirect-301/)

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

 *  [mpmchugh](https://wordpress.org/support/users/mpmchugh/)
 * (@mpmchugh)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/subfolder-installation-2/#post-5861443)
 * I have this problem as well. The meta box is displaying the WordPress Address(
   URL) as the redirect root, rather than the Site Address (URL), so it make the“
   SEO Redirect 301s” metabox kinda useless when WordPress is not run-in from the
   root directory ( [see screenshot](https://www.evernote.com/l/AALKJRRUkqdN8rtWajNFctArJKqPm53Io0A)).
 * Is there a way to correct this?
 * MMDeveloper, you’d touched on this issue in [this thread](https://wordpress.org/support/topic/plugin-uses-wordpress-address-instead-of-site-address?replies=2),
   but didn’t address the problem.
 * > Isn’t get_option(“siteurl”) the same as home_url(). It should be or am I completely
   > wrong?
 * To answer the question, get_option(“siteurl”) and home_url() are only the same
   if you install WordPress in the root directory. If you choose to install it in
   a subdirectory called “site” or “wordpress” or whatever, then they are different.
 * From the WordPress Codex:
 * >  The site_url template tag retrieves the site url for the current site (where
   > the WordPress core files reside) with the appropriate protocol, ‘https’ if 
   > is_ssl() and ‘http’ otherwise. If scheme is ‘http’ or ‘https’, is_ssl() is 
   > overridden. Use this to get the “WordPress address” as defined in general settings.**
   > Use home_url() to get the “site address” as defined in general settings.**
 * Thanks,
    Michael
 *  [mpmchugh](https://wordpress.org/support/users/mpmchugh/)
 * (@mpmchugh)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/subfolder-installation-2/#post-5861444)
 * I actually did a search and replace in the plugin’s php files replacing **get_option(“
   siteurl”)** with **home_url()**, and it seems to be working correctly on my subfolder
   installed site.
 * Perhaps you can test and do the same for a future release?
 * This also ends up putting the xml redirect list in the site root, which seems
   better, than in the e subdirectory.
 * -Michael

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

The topic ‘Subfolder installation’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-seo-redirect-301.svg)
 * [WP SEO Redirect 301](https://wordpress.org/plugins/wp-seo-redirect-301/)
 * [Support Threads](https://wordpress.org/support/plugin/wp-seo-redirect-301/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-seo-redirect-301/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-seo-redirect-301/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-seo-redirect-301/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [mpmchugh](https://wordpress.org/support/users/mpmchugh/)
 * Last activity: [10 years, 10 months ago](https://wordpress.org/support/topic/subfolder-installation-2/#post-5861444)
 * Status: not resolved