Title: PHP 8 error
Last modified: May 26, 2022

---

# PHP 8 error

 *  [vaka2vaka](https://wordpress.org/support/users/vaka2vaka/)
 * (@vaka2vaka)
 * [4 years ago](https://wordpress.org/support/topic/php-8-error-24/)
 * When switching to another theme and with Ocean (PHP 7 4 ) Extra enabled, a message
   appears:
 * Use of undefined constant OCEANWP_THEME_VERSION – assumed ‘OCEANWP_THEME_VERSION’(
   this will throw an Error in a future version of PHP)
 * When activating PHP 8 – the site breaks
    WordPress version 6.0 Current theme:
   Kadence (version 1.1.18) Problem plugin: Ocean Extra (version 2.0.0) PHP Version
   8.0.12
 * An error with the E_ERROR type occurred on line 647 of the /home/h/hxrkxqj/:__________________.
   ru/public_html/wp-content/plugins/ocean-extra/ocean-extra.php file. Error message:
   Uncaught Error: Undefined constant “OCEANWP_THEME_VERSION” in /home/h/hxrkxqj/:
   __________________/public_html/wp-content/plugins/ocean-extra/ocean-extra.php:
   647
    Stack trace: #0 [internal function]: ocean_theme_is_outdated_admin_notice(”)#
   1 /home/h/hxrkxqj/:__________________/public_html/wp-includes/class-wp-hook.php(
   307): call_user_func_array(‘ocean_theme_is_…’, Array) #2 /home/h/hxrkxqj/:__________________/
   public_html/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(NULL, 
   Array) #3 /home/h/hxrkxqj/:__________________/public_html/wp-includes/plugin.
   php(476): WP_Hook->do_action(Array) #4 /home/h/hxrkxqj/:__________________/public_html/
   wp-admin/admin-header.php(303): do_action(‘admin_notices’) #5 /home/h/hxrkxqj/:
   __________________/public_html/wp-admin/themes.php(246): require_once(‘/home/
   h/hxrkxqj…’) #6 {main} thrown

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Thread Starter [vaka2vaka](https://wordpress.org/support/users/vaka2vaka/)
 * (@vaka2vaka)
 * [4 years ago](https://wordpress.org/support/topic/php-8-error-24/#post-15679705)
 * Clarification
    1 OCEANWP+ Ocean Extra+ PHP 7 4- PHP 8 – no errors 2 Kadence +
   Ocean Extra+ PHP 7 4- – (Use of undefined constant OCEANWP_THEME_VERSION – assumed‘
   OCEANWP_THEME_VERSION’ (this will throw an Error in a future version of PHP))
   3 Kadence + Ocean Extra+ PHP 8 – website broken
 *  [Arvind](https://wordpress.org/support/users/arvindwp/)
 * (@arvindwp)
 * [3 years, 12 months ago](https://wordpress.org/support/topic/php-8-error-24/#post-15703017)
 * I am facing resembling issue. The customiser panel is not working. The hosting
   support informed me of PHP error in public_html/wp-content/themes/kadence/inc/
   customizer/options/custom-layout-options.php on line 1867
 * Currently last few lines (line 1857-1867) read as
 *     ```
       ::add_settings(
       	array( 
       		'info_custom_post_types_placehoder' => array(
       			'control_type' => 'kadence_title_control',
       			'section'      => 'custom_posts_placeholder',
       			'priority'     => 10,
       			'label'        => esc_html__( 'Custom Post Types', 'kadence' ),
       			'settings'     => false,
       		),
       	),
       );
       ```
   
 * The last line is marked with an ERROR sign – a PHP Parse error: syntax error,
   unexpected ‘)’ in last line above.
 * What is the fix please?
 * I am unable to use the Customizer panel Screenshot [https://ibb.co/zf7vYkp](https://ibb.co/zf7vYkp)
 * Regards
    Arvind

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘PHP 8 error’ is closed to new replies.

 * ![](https://ps.w.org/ocean-extra/assets/icon.svg?rev=2814940)
 * [Ocean Extra](https://wordpress.org/plugins/ocean-extra/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ocean-extra/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ocean-extra/)
 * [Active Topics](https://wordpress.org/support/plugin/ocean-extra/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ocean-extra/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ocean-extra/reviews/)

## Tags

 * [parse-error](https://wordpress.org/support/topic-tag/parse-error/)

 * 2 replies
 * 2 participants
 * Last reply from: [Arvind](https://wordpress.org/support/users/arvindwp/)
 * Last activity: [3 years, 12 months ago](https://wordpress.org/support/topic/php-8-error-24/#post-15703017)
 * Status: not resolved