wp_redirect not working after update_user_meta

wp_redirect sends a HTTP header to the browser. Once HTTP headers are sent, that’s it, they’re gone, you can’t add anymore.

However, you called get_header and rendered some HTML. To do this headers need to be sent to the browser telling it to expect a HTML page.

So by the time you load edit-profile-proccess.php, it’s too late. Headers have already been sent, you can’t add the redirect header. It’s already happened, the horse has already bolted out the stable. Time travel would be necessary.

That’s why you’re getting PHP warning messages about this instead of the redirect you expected. Notice that they tell you exactly whata the problem is, they even tell you where the first output occurred, the file and line it happened in.

Instead, you need to perform this check and redirect before any output happens. If even a single space character or tag is output then the headers are sent, so the order you do this in is critical, and non-negotiable.