0
Fatal error: Uncaught Error: Call to undefined function set_current_screen() in /var/www/html/wp-admin/admin-header.php:30 
Stack trace: 
#0 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Utils/System/Base.php(267): require_once() 
#1 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Utils/System.php(219): CRM_Utils_System_Base->theme('<div id="crm-co...', false, false) 
#2 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/Error.php(233): CRM_Utils_System::theme('<div id="crm-co...') 
#3 /var/www/html/wp-content/plugins/civicrm/civicrm/packages/PEAR.php(921): CRM_Core_Error::handle(Object(DB_Error)) 
#4 /var/www/html/wp-content/plugins/civicrm/civicrm/packages/DB.php(985): PEAR_Error->__construct('DB Error: alrea...', -5, 16, Array, 'CREATE TABLE ci...') 
#5 /var/www/html/wp-content/plugins/civicrm/civicrm/packages/PEAR.php(575): DB_Error->__construct(-5, 16, Array, 'CREATE TABLE ci...') 
#6 /var/www/html/wp-content/plugins/civicrm/civicrm/packages/PEAR.php(223): PEAR->_raiseError(Object(DB_mysqli), NULL, -5, 16, in /var/www/html/wp-admin/admin-header.php on line 30
  • Can you check CiviCRM logs for detailed error. It seems u getting some db error for creating tables( already exists) . – Pradeep Nayak Jan 13 '18 at 15:00
0

Try adding following line in functions.php file of your child theme.

require_once(ABSPATH . 'wp-admin/includes/screen.php');

Which wordpress version and civicrm version are you trying?

0

It seems like you have two problems.

As Pradeep mentioned in the comments - it seems like your underlying error is that the install is trying to create a database that already exists. I can't tell for sure, because the error in #4 is cut off.

Additionally, there's the second error (undefined function) which is unfortunately WordPress-specific and I don't know the solution. However, completely removing/creating the CiviCRM database again (assuming that it's separate from WordPress) is likely to solve the first problem, and the second problem won't occur.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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