• Resolved EdwardBock

    (@edwardbock)


    Hi Ninja-Forms-Team,

    we got notices out of you plugin because it uses deprecated wordpress functions. I would be happy if you could fix this with one of your next updates.

    Deprecated: media_buttons_context since version 3.5.0

    You seem to know about the deprecation because it’s in deprecated/classes/notifications.php Line 46

    Thanks
    Edward

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Contributor Justin McElhaney

    (@jmcelhaney)

    You are most likely seeing this issue due to your theme or a page builder calling the deprecated modal function that is still included in Ninja Forms that has not been updated due to WordPress moving to the Gutenberg page editor.
    We have an issue for this in our system for our developers to look into it.

    Thread Starter EdwardBock

    (@edwardbock)

    Ok, thanks for the quick response. I will check the theme.

    @jmcelhaney As a follow up, I am still seeing this

    
        function __construct() {
            // Add a tinyMCE button to our post and page editor
            add_filter( 'media_buttons_context', array( $this, 'insert_form_tinymce_buttons' ) );
        }
    

    in the NF_Admin_AddFormModal class.

    Cédric Charles

    (@cedriccharles)

    NinjaForms Guys,

    It’s been months that this issue is there, and you did nothing about it… (and it’s only because of your plugin -> line 12 of AddFormModal.php…)

    Why this issue is tagged as “resolved”?
    The problem still exists.

    Did you try changing media_buttons_context to media_buttons?

    This is still an issue. Please advise.

    Same issue. It is still not fixed in Ninja Forms 3.4.33.

    Here is a workaround: add this code in your theme’s functions.php:

    if ( class_exists('Ninja_Forms') ) {
    	remove_filter('media_buttons_context', array(Ninja_Forms::instance()->add_form_modal, 'insert_form_tinymce_buttons'));
    }

    I’m also having this problem which is showing as an error when I use FrontEnd Publishing add-on.

    Version of Ninja Forms is 3.4.34

    Can confirm that the workround in the previous message is effective. Thanks for submitting it.

    I am also seeing this issue. Using @kerfred s workaround.

    Hello @jmcelhaney
    Is there someone here? 6 months to change 1 line of code :/?

    Deprecated: media_buttons_context is deprecated since version 3.5.0! Use media_buttons instead. in xxxx/wp-includes/functions.php on line 5234
    I see this is a ninja forms issue – is there a fix for it?

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘media_buttons_context Deprecated’ is closed to new replies.