diff --git a/wp-import.php b/wp-import.php index 8ad2a11..567643c 100644 --- a/wp-import.php +++ b/wp-import.php @@ -9,10 +9,10 @@ if ( ! file_exists( 'wp-content/mysql.sql' ) ) { // Create backup of the current database. echo shell_exec( 'wp db export ./wp-content/mysql-backup.sql' ); -$staging_domain = shell_exec( 'wp option get siteurl' ); +$staging_domain = shell_exec( 'wp option get siteurl --quiet' ); echo shell_exec( 'wp db import ./wp-content/mysql.sql' ); -$domain = shell_exec( 'wp option get siteurl' ); +$domain = shell_exec( 'wp option get siteurl --quiet' ); $search_replace = trim( $domain ) . ' ' . trim( $staging_domain ); // Replace the domain in the database.