Skip to content

get_home_path returns an incorrect path when wp-config is stored outside site root #695

@willmot

Description

@willmot

From @willmot on March 26, 2014 13:52

In humanmade/hm-backup@3e213ac we introduced the following as a workaround for WordPress MS installs where WordPress is installed in a subdirectory. See #260 a deeper explanation.

if ( ! file_exists( ABSPATH . 'wp-config.php' ) ) {
    $home_path = trailingslashit( dirname( ABSPATH ) );
}

However this broke standard WordPress installs where wp-config.php is stored outside of site root. See humanmade/hm-backup@3e213ac#commitcomment-5802989.

Copied from original issue: humanmade/hm-backup#64

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions