Support » Plugin: SiteGround Migrator » Doesn’t work with Pressable

  • Resolved Jon Fuller

    (@freshyjon)


    This doesn’t seem to work with Pressable, since they have the core WP files set up (symbolically linked) differently than most hosting providers.

    For this reason, your use of ABSPATH needs to be adjusted so it knows where to properly find the actualwp-content folder of the site.

    You can read more about this here: https://kb.pressable.com/article/abspath-and-pressable/

    For now, we’ve made this change in the class-siteground-migrator-files-service.php file, but I’m not sure it’s the correct way to fix this issue (there may be other things that need to be fixed).

    https://i.imgur.com/dZcwI3s.png

    // Build the path to the filem using the WP_CONTENT_DIR const.
    // $path = ABSPATH . $maybe_path;
    
    if ( !defined( 'SITEROOTDIR' ) ) {
    	define( 'SITEROOTDIR', str_replace('wp-content','',WP_CONTENT_DIR) );
    }
    $path = SITEROOTDIR . $maybe_path;
    • This topic was modified 6 months, 2 weeks ago by Jon Fuller. Reason: fixing code
    • This topic was modified 6 months, 2 weeks ago by Jon Fuller.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.