Difference between revisions of "Wordpress errors"
(→WP-Config Editing) |
(→WP-Config Editing) |
||
Line 12: | Line 12: | ||
=== WP-Config Editing === | === WP-Config Editing === | ||
+ | There is several other things you can edit in the config file but for this purpose or any database errors you would want to look for the following things within your wp-config file. | ||
<syntaxhighlight lang="php"> | <syntaxhighlight lang="php"> | ||
// ** MySQL settings - You can get this info from your web host ** // | // ** MySQL settings - You can get this info from your web host ** // |
Revision as of 17:18, 24 September 2014
Redeclare get_temp_dir() error
Error: Fatal Error: Cannot redeclare get_temp_dir() (previously declared in /home/public_html/wp-includes/functions.php:2160) in /home/public_html/wp-admin/includes/file.php on line 189
Solution: Reinstall all WP core files. To keep the plugins, themes and content. Just deleted WP-Admin and uploaded the fresh version and the same for the functions.php.
Blank Page
If you see a blank page it could be because the installer had wrong info or something is missing in htacces, this default htaccess could also help with people logging and wp permalinks working correctly
WP-Config Editing
There is several other things you can edit in the config file but for this purpose or any database errors you would want to look for the following things within your wp-config file.
// ** MySQL settings - You can get this info from your web host ** //
/** The name of the database for WordPress */
define('DB_NAME', 'Database-name');
/** MySQL database username */
define('DB_USER', 'Database-username');
/** MySQL database password */
define('DB_PASSWORD', 'Db-password');
/** MySQL hostname */
// Depending on your host you may have a different local host name or
define('DB_HOST', 'localhost');
Default Htaccess
make sure the following is in the htaccess file in the same folder as the folder with wordpress in it.
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress