Hi,
My site does not allow change of email for security reasons and account information is managed through UM.
I have seen the past posts about this question, the solution provided is using the following CSS code to hide this section.
.wpf-field.wpf-field-type-email.wpf-field-name-user_email.wpf-field-required { display: none; }
However, hiding section doesn't prevent user from changing email or other values. Any browser can quickly inspect the page and change hidden email value in a few seconds.
Is there any way to totally disable section from the front-end using other methods or through php snippet?
Thanks!
Hi,
You can use JavaScript code provided below:
jQuery( document ).ready(function() { jQuery('.wpf-field.wpf-field-type-email.wpf-field-name-user_email.wpf-field-required').remove(); });
For guidance on adding JavaScript to WordPress pages, you may find this article helpful: https://www.wpbeginner.com/wp-tutorials/how-to-easily-add-javascript-in-wordpress-pages-or-posts/