I’ve got this working and am using it to overwrite user first name, last name, email, and a custom tel. field.
I see now that the email field doesn’t update the WordPress meta – is it possible to overwrite the standard WordPress meta with the ACF field value?
You’re right, I’m seeing a conflict with wp-includes/pluggable.php – the last line here:
$status = apply_filters( 'wp_redirect_status', $status, $location );
if ( ! $location )
return false;
$location = wp_sanitize_redirect($location);
if ( !$is_IIS && PHP_SAPI != 'cgi-fcgi' )
status_header($status); // This causes problems on IIS and some FastCGI setups
header("Location: $location", true, $status);
I also accidentally discovered that if I activate the plugin WP User Frontend, then location works and the form successfully reloads.
Not sure what the plugin is doing right compared to my code, but I’ll keep digging. I’m using the get_header
hook in add_action( 'get_header', 'add_acf_form_head', 7 );
but I’ll try calling it before get_header
.
Thanks for your help, I appreciate it.