I haven’t been able to reproduce the error, but could you try something for me? In wp-user-avatar/includes/class-wp-user-avatar-shortcode.php, could you change line 113 from:
wp_redirect(add_query_arg(array('updated' => 'true'), get_permalink($post)));
to:
wp_redirect(add_query_arg(array('updated' => 'true'), get_permalink($post)));
die();
You’re just adding the die();.
Thanks for looking into this.
With the die(); added, the same warning is displayed after updating or removing the avatar, but it’s the only thing in the page content area.
I tried deactivating all other plugins and activating the default Twenty Twelve theme, but the the warning still appears. I’m running WP 3.9.
I’ll be happy to try any experiments you like or give you a login. I’m busy the rest of today because I celebrate Easter but I’ll be able to reply tomorrow.
I can confirm the same problem, and the die() fix does not resolve it.
I think you’re calling wp_redirect from the shortcode-generating code, whereas it should be called from a much earlier hook, like wp-init.
I’m using WordPress 3.9 and WP-User-Avatar 1.9.4.
FYI: I’ve found out that commenting out the wp_redirect line completely prevents the message without preventing the plugin from working.
I’ve released 1.9.5 with an update for this. Let me know if upgrading fixes the problem.
Yes, the 1.9.5 update resolves the issue for my site. Thank you, Bangbay. And ZigPress.
Confirm problem fixed, many thanks.
This error has resurfaced in 1.9.11.
There hasn’t been any change to the code. When you save the image, are you redirected to the same page but with ?updated=1 appended to the URL?
No URL parameter. Another site still on 1.9.10 has ?updated=1 but the site running 1.9.11 does not.
Could I go to the site and create a test user account to see the problem?
Experiencing the same issue on my site. Deactivated all plugins to confirm it was the Avatar plugin. It’s happening when I use the [avatar_upload] shortcode and I have the most recent version installed
I can go into the plugin and edit any code you’d like. There are not URL parameters submitted with the version I’m using.
Thanks!
Danny Batista
Vuepoint