Monday , February 3 2025

Error installing plugins – sprintf(): Too few arguments in class-bulk-upgrader-skin.php

I got this error after installing a third-party free theme. Full text of the error:

Warning: sprintf(): Too few arguments in /wp-admin/includes/class-bulk-upgrader-skin.php on line 152

Here is the solution – in the file /wp-admin/includes/class-bulk-upgrader-skin.php find and replace this code:

if ( $this->result && ! is_wp_error( $this->result ) ) {
    if ( ! $this->error ) {
        echo '<div class="updated js-update-details" data-update-details="progress-' . esc_attr( $this->upgrader->update_current ) . '">' .
            '<p>' . sprintf( $this->upgrader->strings['skin_update_successful'], $title ) .
            ' <button type="button" class="hide-if-no-js button-link js-update-details-toggle" aria-expanded="false">' . __( 'Show details.' ) . '</button>' .
            '</p></div>';
    }
    echo '<script type="text/javascript">jQuery(\'.waiting-' . esc_js($this->upgrader->update_current) . '\').hide();</script>';
}

to this one:

if ( $this->result && ! is_wp_error( $this->result ) ) {
	if ( ! $this->error )
		echo '<div class="updated"><p>' . sprintf($this->upgrader->strings['skin_update_successful'], $title, 'jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').toggle();jQuery(\'span\', this).toggle(); return false;') . '</p></div>';
	echo '<script type="text/javascript">jQuery(\'.waiting-' . esc_js($this->upgrader->update_current) . '\').hide();</script>';
}

About iryna

I'm Iryna, a web developer from Ukraine with a decade of experience solving complex technical challenges in the world of freelance. Throughout my career, I've worked on everything from troubleshooting server-side issues and optimizing website performance to enhancing user interfaces. On this blog, I share detailed solutions to the technical problems I’ve encountered and methods that have worked best for me. In addition to my technical expertise, I’m also passionate about digital drawing. I hope the tutorials and insights I provide here will help both fellow developers and creatives alike in their own projects.

Check Also

How to remove 404 //fonts.gstatic.com and //fonts.googleapis.com from WordPress head section

I tried solutions with functions that should remove from head and , but a very …

Leave a Reply

Your email address will not be published. Required fields are marked *