• Resolved wpbless

    (@wpbless)


    I installed the Gutenberg plugin today to try it out.

    I’m getting an error message both at the top of my WP dashboard, and when I go to view the site in a browser:

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘ikreativ_tinymce_fix’ not found or invalid function name in /home1/asharp/public_html/andreasharp.com/wp-includes/class-wp-hook.php on line 288

    A few days ago, I got so sick of years of WP stripping out my tags when I go back to Code-View after switching to Visual — that I finally decided to find a way to solve that problem. I found somebody’s solution https://ikreativ.com/stop-wordpress-removing-html/

    It didn’t work, so I deleted the file that I made with this suggestion’s code, and put my backed-up, unchanged functions.php file back where it was before I fiddled with this.

    I looked at line 288 in wp-includes/class-wp-hook.php. It is blank.

    I’ll the whole section below a line of *** below.

    The first line is line 286.

    The indents don’t carry over the copy/paste step, so it might be hard to see that the entirety of line 287 is

    $this->current_priority[ $nesting_level ] = $priority = current( $this->iterations[ $nesting_level ] );

    Then a blank line for 288.

    And line 289 is foreach ( $this->callbacks[ $priority ] as $the_ ) {

    do {
    $this->current_priority[ $nesting_level ] = $priority = current( $this->iterations[ $nesting_level ] );

    foreach ( $this->callbacks[ $priority ] as $the_ ) {
    if( ! $this->doing_action ) {
    $args[ 0 ] = $value;
    }

    // Avoid the array_slice if possible.
    if ( $the_[‘accepted_args’] == 0 ) {
    $value = call_user_func_array( $the_[‘function’], array() );
    } elseif ( $the_[‘accepted_args’] >= $num_args ) {
    $value = call_user_func_array( $the_[‘function’], $args );
    } else {
    $value = call_user_func_array( $the_[‘function’], array_slice( $args, 0, (int)$the_[‘accepted_args’] ) );
    }
    }
    } while ( false !== next( $this->iterations[ $nesting_level ] ) );

    Hoping someone can send what I can paste in to replace what I have, and that it’ll carry over the copy/paste step, and that it’ll fix the whole problem.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter wpbless

    (@wpbless)

    I installed the Gutenberg plugin today to try it out.

    I’m getting an error message both at the top of my WP dashboard, and when I go to view the site in a browser:

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘ikreativ_tinymce_fix’ not found or invalid function name in /home1/asharp/public_html/andreasharp.com/wp-includes/class-wp-hook.php on line 288

    A few days ago, I got so sick of years of WP stripping out my tags when I go back to Code-View after switching to Visual — that I finally decided to find a way to solve that problem. I found somebody’s solution https://ikreativ.com/stop-wordpress-removing-html/

    It didn’t work, so I deleted the file that I made with this suggestion’s code, and put my backed-up, unchanged functions.php file back where it was before I fiddled with this.

    I looked at line 288 in wp-includes/class-wp-hook.php. It is blank.

    I’ll paste the whole section below a line of *** below.

    The first line is line 286.

    The indents don’t carry over the copy/paste step, so it might be hard to see that the entirety of line 287 is

    $this->current_priority[ $nesting_level ] = $priority = current( $this->iterations[ $nesting_level ] );

    Then a blank line for 288.

    And line 289 is foreach ( $this->callbacks[ $priority ] as $the_ ) {

    *******************************************************************************

    do {
    $this->current_priority[ $nesting_level ] = $priority = current( $this->iterations[ $nesting_level ] );

    foreach ( $this->callbacks[ $priority ] as $the_ ) {
    if( ! $this->doing_action ) {
    $args[ 0 ] = $value;
    }

    // Avoid the array_slice if possible.
    if ( $the_[‘accepted_args’] == 0 ) {
    $value = call_user_func_array( $the_[‘function’], array() );
    } elseif ( $the_[‘accepted_args’] >= $num_args ) {
    $value = call_user_func_array( $the_[‘function’], $args );
    } else {
    $value = call_user_func_array( $the_[‘function’], array_slice( $args, 0, (int)$the_[‘accepted_args’] ) );
    }
    }
    } while ( false !== next( $this->iterations[ $nesting_level ] ) );

    Hoping someone can send what I can paste in to replace what I have, and that it’ll carry over the copy/paste step, and that it’ll fix the whole problem.

    Thread Starter wpbless

    (@wpbless)

    Help urgently needed.

    I fear I won’t have this solved before Gutenberg is the core rather than the plugin.

    Thanks so much if anyone can answer.

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    Whatever code you added that has the “ikreativ_tinymce_fix” function in it is broken. Remove that code.

    The error is coming from wp-hook, but the error is actually caused by your added code. Remove the add_filter line that you added which is adding the “ikreativ_tinymce_fix” filter.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Error after installing Gutenberg (I’d tried to stop WP from removing tags)’ is closed to new replies.