[Fix Error] Call to undefined function wp() in wp-blog-header.php

O error that appeared to me at several blogsWordPress After they were moved from one server to another and had edited the file wp-config.php. “Call to undefined function wp() in wp-blog-header.php“.

Cause error:Se pare că fișierul wp-config.php He loses his lines after he is edited. Specifically, the entire PHP code appears on a single row. I don't know what the exact cause is. Probably a PHP file editor's problem.

[Fix Error] Call to undefined function wp() in wp-blog-header.php

SOLVING: Copy & Replace la un nou fișier wp-config.php in which to set your database, USER Database, Pass and Prefix.

<?php 
// ** MySQL settings - You can get this info from your web host ** // 
/** The name of the database for WordPress */ 
define('DB_NAME', 'putyourdbnamehere');

/** MySQL database username */ 
define('DB_USER', 'usernamehere');

/** MySQL database password */ 
define('DB_PASSWORD', 'yourpasswordhere');

/** MySQL hostname */ 
define('DB_HOST', 'localhost');

/** Database Charset to use in creating database tables. */ 
define('DB_CHARSET', 'utf8');

/** The Database Collate type. Don't change this if in doubt. */ 
define('DB_COLLATE', '');

define('AUTH_KEY', 'put your unique phrase here'); 
define('SECURE_AUTH_KEY', 'put your unique phrase here'); 
define('LOGGED_IN_KEY', 'put your unique phrase here'); 
define('NONCE_KEY', 'put your unique phrase here'); 
$table_prefix  = 'wp_';

define ('WPLANG', '');

/* That's all, stop editing! Happy blogging. */

/** WordPress absolute path to the WordPress directory. */ 
if ( !defined('ABSPATH') ) 
    define('ABSPATH', dirname(__FILE__) . '/');

/** Sets up WordPress vars and included files. */ 
require_once(ABSPATH . 'wp-settings.php'); 
?>

Error disappeared after this update from the file wp-config.php al WordPress.

Passionate about technology, I write with pleasure on stealthsetts.com starting with 2006. I have a rich experience in operating systems: Macos, Windows and Linux, but also in programming languages ​​and blogging platforms (WordPress) and for online stores (WooCommerce, Magento, Presashop).

Home Your source of IT tutorials, useful tips and news. [Fix Error] Call to undefined function wp() in wp-blog-header.php
Leave a Comment