Viewing 12 replies - 1 through 12 (of 12 total)
  • Dealing with this same issue. Getting this error on our website after updating to 2.2.12:

    Warning: sprintf(): Too few arguments in (...)/wp-content/plugins/wp-user-avatar/includes/class-wp-user-avatar-functions.php on line 668

    Will be awesome to get a fix pushed out for us less tech-savvy folk ??

    • This reply was modified 3 years, 8 months ago by osmanham.
    Sa?a

    (@stodorovic)

    The formatting string should contains %s for each string. If developers want to use sprintf, correct solution is:

           $avatar = sprintf(
               '<img src="%s"%s alt="%s" class="avatar avatar-%s wp-user-avatar wp-user-avatar-%s photo avatar-default %s" />',
               $wpua_final_avatar_image_src,
               $default_image_details['dimensions'],
               $alt,
               $size,
               $size,
               esc_attr( implode( ' ', $class ) )
           );
    
    Thread Starter janrenn

    (@janrenn)

    @stodorovic +1 for this solution

    Nos hemos encontrado con el mismo problema al actualizar, la única solución que encontramos es desactivar el complemento :S ??

    Moderator Yui

    (@fierevere)

    永子

    Please, if you have “same issue”, consider opening your own support topics,
    or if you are sure it is absolutely same (not all same issues are same, because of many varieties of server and wordpress environments), then just subscribe for this topic on the sidebar.
    “Metoo” like replies wont help finding the solution.

    from where I can get the previous working version?

    Sa?a

    (@stodorovic)

    It’s possible to download previous versions from www.ads-software.com (eg. https://downloads.www.ads-software.com/plugin/wp-user-avatar.2.2.11.zip ).

    There are 3 places where is used sprintf function. I hope that an update will be released soon because we already proposed correct solutions (use proper placeholder %s for each string variable).

    Plugin Author Collins Agbonghama

    (@collizo4sky)

    Everyone please update to 2.2.14.

    Let me know if that fixes the issue.

    I upgraded to: Version 2.2.14
    Still have the issue, but only when i’m logged in :

    Warning: sprintf(): Too few arguments in /customers/6/4/d/(…)/httpd.www/wp-content/plugins/wp-user-avatar/includes/class-wp-user-avatar-functions.php on line 666

    Plugin Author Collins Agbonghama

    (@collizo4sky)

    @teamemilie 2.2.15 should fix your issue.

    Let me know if that works.

    @collizo4sky
    You are right. Thanks and thank you very much for quick fix! Have a pleasent day.
    Bast Regards

    Thread Starter janrenn

    (@janrenn)

    @collizo4sky fixed. Thanks a lot. JR

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘PHP Warning: sprintf(): Too few arguments’ is closed to new replies.