Hi I developed a website in wordpress on my localhost then moved it to a live server. Everything is working fine except wp-admin. When I go to domain/wp-admin it shows a white screen. Yet when I go to domain/wp-login.php it allows me to login to the admin. Also if I try to create new post or update any settings it keeps showing a blank white screen, yet when refreshed has saved the settings/added the post etc. The site is www.nuvogadgets.com.

Any ideas? Thanks!

  • Hi ... this is a very common question / problem on here and there is a dedicated page on the Codex on how to move WordPress codex.wordpress.org/Moving_WordPress
    – Damien
    Commented Oct 15, 2012 at 11:16
  • It sounds like you might have a problem with your functions.php file. I would suggest removing the last ?> in the file.
    – Lea Cohen
    Commented Oct 15, 2012 at 12:17
  • @PaulElliot: White screen = no debugging info.Add that to your wp-config.php file (details about WP debugging in Codex).
    – kaiser
    Commented Oct 15, 2012 at 14:54

2 Answers 2


When you say moved WordPress, what do you mean exactly,

  • Did you copy your entire WordPress installation from your localhost to your remote server without installing WordPress first on your destination host?

  • Did you export your SQL database from localhost then import it to your remote server?

  • Did you install WordPress on your remote server before copying your theme folder across?

It's likely that the parameters found under Settings -> General for both,

  • WordPress Address (URL)
  • Site Address (URL)

Are both incorrect and still pointing to your localhost environment.

You should install WordPress from scratch on your remote server prior to copying over your theme instead of copying your entire WordPress folder from your localhost.

Otherwise if you want, login to your MySQL manager (likely phpMyAdmin) and edit the entries for,

  • WordPress Address (URL)
  • Site Address (URL)

Under the wp_options table.

As suggested by Damien (in comments), there is of course a whole section on the Codex dedicated to this topic,


In particular the following section title "If you forget to change the locations", relates directly to the WordPress Address URL and Site Address URL mentioned above.

  • 2
    Hi there ... you might like to include a link to the Codex page codex.wordpress.org/Moving_WordPress ... also I think the OP can't get to /wp-admin so they would have to login in via PHPMyAdmin.
    – Damien
    Commented Oct 15, 2012 at 11:14
  • Yes, I like. I should clarify that I recommending to login via phpMyAdmin, not via wp-admin, that's just a reference of where those parameters of normally held - just to give some context. Though, the section I link to within the Moving WordPress Codex page shows an alternative using update_options to reset the URLs. Thanks for reminding me about the link, a must read for anyone moving WP for the first time.
    – Adam
    Commented Oct 15, 2012 at 12:21

Whenever I copy over my WordPress to a new location I always take over my database modifier php script:


$database_host = '';
$database_user = '';
$database_pass = '';
$database_name = '';

$replacement_values = array( 'http://oldurl' => 'http://newurl' );
$text_fields = array( 'char', 'text', 'varchar' );

$mysql = mysql_connect( $database_host, $database_user, $database_pass );
if ( !$mysql ) {
    die( 'Could not connect: ' . mysql_error() );

$mysql_database = mysql_select_db( $database_name, $mysql );
if ( !$mysql_database ) {
    die( 'Can\'t select database: ' . mysql_error() );

$tables_result = mysql_query( 'SHOW TABLES' );
while ( $tables_row = mysql_fetch_row( $tables_result ) ) {
    foreach ( $tables_row as $table ) {
        $columns_result = mysql_query( 'SHOW COLUMNS FROM ' . $table );
        while ( $columns_row = mysql_fetch_assoc( $columns_result ) ) {
            $column = $columns_row[ 'Field' ];
            $type = $columns_row[ 'Type' ];
            foreach ( $text_fields as $text_field_type ) {
                if ( strpos( $type, $text_field_type ) !== false ) {
                    echo '<p>' . $type . ' - ' . $column . ':' . $table . '</p>';
                    foreach ( $replacement_values as $replace => $replacement ) {
                        $replace_query = sprintf( 'UPDATE %s SET %s = REPLACE(%s, \'%s\', \'%s\')', $table, $column, $column, $replace, $replacement );
                        mysql_query( $replace_query );

mysql_free_result( $columns_result );
mysql_free_result( $tables_result );
mysql_close ( $mysql );


You can change the values here:

$replacement_values = array( 'http://oldurl' => 'http://newurl' );

to what you want to replace.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.