Title: PHP8 &#8211; error
Last modified: September 2, 2021

---

# PHP8 – error

 *  [Matt Biscay](https://wordpress.org/support/users/skyminds/)
 * (@skyminds)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/php8-error-4/)
 * Hi Greg,
 * There seems to be an issue with the description field when TinyMCE is enabled
   while PHP8 is being used – it triggers a fatal error (which is a warning under
   PHP7.4) :
 *     ```
       FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, first array member is not a valid class name or object in /www/public/wp-includes/class-wp-hook.php:305
       Stack trace:
       #0 /www/public/wp-includes/plugin.php(189): WP_Hook->apply_filters(Array, Array)
       #1 /www/public/wp-includes/class-wp-editor.php(416): apply_filters('mce_external_pl...', Array, 'post_content')
       #2 /www/public/wp-includes/class-wp-editor.php(307): _WP_Editors::editor_settings('post_content', Array)
       #3 /www/public/wp-includes/general-template.php(3520): _WP_Editors::editor(NULL, 'post_content', Array)
       #4 /www/public/wp-content/plugins/wpadverts/includes/functions.php(1524): wp_editor(NULL, 'post_content', Array)
       #5 /www/public/wp-content/plugins/wpadverts/templates/add.php(30): adverts_field_textarea(Array, Object(Adverts_Form))
       #6 /www/public/w" while reading upstream, client: 196.132.39.108, server: example.com, request: "GET /vehicle-submission/?nocache HTTP/1.0", upstream: "fastcgi://unix:/var/run/php8.0-fpm.sock:", host: "example.com"
       ```
   
 * Is PHP8 support on the roadmap?
 * Thank you,
    Matt

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

 *  Plugin Author [Greg Winiarski](https://wordpress.org/support/users/gwin/)
 * (@gwin)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/php8-error-4/#post-14834585)
 * Hi,
    hmm i am not sure, if this is related to PHP8, i have PHP8 enabled on the
   demo site here [https://demo.wpadverts.com/lite/adverts/add/](https://demo.wpadverts.com/lite/adverts/add/)
   and it does render with errors.
 * It looks like there is just some callback missing.
 * Can you let me know what is the URL of the page where you are having this problem
   and also if you have only WPAdverts installed or also some additional plugins
   or snippets?
 *  Thread Starter [Matt Biscay](https://wordpress.org/support/users/skyminds/)
 * (@skyminds)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/php8-error-4/#post-14834964)
 * Hi Greg,
 * The URL is [https://newoldcars.com/vehicle-submission/](https://newoldcars.com/vehicle-submission/)
   but we had to switch to PHP7.4 so that users can keep on adding their listings.
 * We use WPAdverts, with some addons (Authors, Custom Fields, Mark as Sold, Recaptcha,
   Paypal).
 * The submission page is using the WPA custom fields.
 * Thank you,
    Matt
 *  Plugin Author [Greg Winiarski](https://wordpress.org/support/users/gwin/)
 * (@gwin)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/php8-error-4/#post-14841726)
 * Hi,
    i am looking at the error again, it is caused by a missing callback function
   inside a ‘mce_external_pl…’ filter (most likely ‘mce_external_plugins’).
 * Any chance you have some plugin that interacts with the tinyMCE editor in some
   way? It is possible that the filter is being registered but the actual function
   that should be executed is loaded in the wp-admin only which causes an error.
 * If you do have a plugin like that you can try switching it off, enabling PHP8
   and seeing if it helps.
 * If you are not sure if any of the installed plugins does that, then you can enable
   PHP8 disable plugins one by one and see when and if the problem goes away.
 *  Thread Starter [Matt Biscay](https://wordpress.org/support/users/skyminds/)
 * (@skyminds)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/php8-error-4/#post-14854609)
 * Hi Greg,
 * I searched for any reference to `mce_external_plugins` but apart from the Avada
   builder, I had no luck.
 * The add listing page is very basic and only uses WPAdverts, the Avada builder
   is not used on this page. I also checked for custom codes but no dice regarding
   mce_external_plugins.
 * Thank you,
    Matt
 *  Plugin Author [Greg Winiarski](https://wordpress.org/support/users/gwin/)
 * (@gwin)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/php8-error-4/#post-14858172)
 * Hi,
    note that most likely the problem is not caused by something executed on
   the page, but rather something that is running in wp-admin (but is included incorrectly
   in the frontend).
 * The text editor on your website does not look like the text editor by default(
   that is yours has only two buttons and a different theme) so i am pretty sure
   that something is modifying it, although not 100% sure that it is causing a problem,
   but based on the debug information we have it is reasonable to think that – at
   least for now.
 * You can check in a wp-admin panel on some pages where the tinyMCE editor is available
   if it has some custom buttons added if it has then disable the plugin that adds
   the buttons and check if there is a problem on the page with [adverts_add].
 * One other more complex thing you can try is add the code below in your theme 
   functions.php file
 *     ```
       add_action( "wp_footer", function() {
           global $wp_filter;
           echo "<pre>";
           print_r( $wp_filter["mce_external_plugins"] ); 
           echo "</pre>";
       }, 1000 );
       ```
   
 * and go to the page with the [adverts_add] shortcode, at the bottom of the page,
   below the footer you should see either a notice that there are no filters for
   the mce_external_plugins (or just see nothing at all) or the list of registered
   filters.
 * If there will be some filters listed you can copy the text and paste it here.

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

The topic ‘PHP8 – error’ is closed to new replies.

 * ![](https://ps.w.org/wpadverts/assets/icon-256x256.png?rev=2423472)
 * [WPAdverts - Classifieds Plugin](https://wordpress.org/plugins/wpadverts/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wpadverts/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wpadverts/)
 * [Active Topics](https://wordpress.org/support/plugin/wpadverts/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wpadverts/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wpadverts/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Greg Winiarski](https://wordpress.org/support/users/gwin/)
 * Last activity: [4 years, 8 months ago](https://wordpress.org/support/topic/php8-error-4/#post-14858172)
 * Status: not resolved