WordPress.org

Make WordPress Core

Ticket #5440: profile-email-filter.patch

File profile-email-filter.patch, 793 bytes (added by axelseaa, 7 years ago)

patch

  • .php

    old new  
    7575<fieldset id="contact-info"> 
    7676<legend><?php _e('Contact Info'); ?></legend> 
    7777 
     78<?php 
     79$disable_email_field = apply_filters('disable_email_field', false); 
     80if ($disable_email_field) 
     81        $disabled = 'disabled = "disabled"'; 
     82else 
     83        $disabled = ''; 
     84?> 
    7885<p><label><?php _e('E-mail: (required)') ?><br /> 
    79 <input type="text" name="email" id="email" value="<?php echo $profileuser->user_email ?>" /></label></p> 
     86<input type="text" name="email" id="email" value="<?php echo $profileuser->user_email ?>" <?php echo $disabled ?>/></label></p> 
    8087 
    8188<p><label><?php _e('Website:') ?><br /> 
    8289<input type="text" name="url" id="url" value="<?php echo $profileuser->user_url ?>" />