Error establishing a database connection in godaddy.com

Did you change http://localhost to http://yoursite.com in your .sql file Also ,check your client website database in phpmyadmin ,upload .sql file to it and also make sure your localhost databse have same prefix as your client ,generally it is wp_ but if different change it . connect to your client website through FTP and upload … Read more

Fatal error: Call to undefined function wp_raise_memory_limit()

I think you first need to verify whether a plugin or theme is causing the problem. Temporarily rename the wp-content/plugins folder to something else, then access the admin panel. If the problem does not reoccur, recreate the wp-content/plugins folder, then move plugins’ folders in there in small groups to determine a suspect. You may need … Read more

Unexpected error with class-wp-hook.php on WordPress

Somewhere in the theme, the WP_Maintenance_Mode class method is hooked to the filter or action. But when the hook is executed, this class doesn’t exists or is not yet included. I suspect that in the theme (file functions.php) this class is hooked to some event, but it is defined in an inactive plugin (I’m guessing … Read more

Random HTTP 500 error in WordPress

If the problem is easily reproducible (i.e. you can make it happen again and again by following a set of steps), do this: Step 1: Document the steps required to cause the problem. Step 2: Document all of the plugins you have running Step 3: Deactivate all of your plugins! Step 4: Perform the steps … Read more

Post show up as post and pages

I just wanted to post the solution here instead of deleting just in case this ever helps anyone else. The problem was this 1 small function I had tucked away in a setting file… /** * change number of posts shown per page in admin area */ function admin_pagination(){ global $wp_query; $per_page = 5; $wp_query->query(‘showposts=”. … Read more

warnings & errors after MAMP to live (hosteurope)

These are warnings, not errors ( edited original question to reflect this ). You have two options: The easy way – Turn off displaying errors and warnings, log them to a file instead The proper way – Fix the warnings, and log them to a file instead of outputting If you need help fixing the … Read more

WP_Error message

One of the variables you’re trying to pass into wpdb::prepare is a WP_Error object. WP_Error‘s are like exceptions mixed with return codes: some functions in the WordPress API return WP_Error objects to tell you something went wrong (like get_terms). We’ll need to see more of your code to be more specific, but you can test … Read more