Fix email field

This commit is contained in:
Kelly Dwan 2019-10-08 13:35:07 -04:00
parent 001c8ee243
commit b032fa914d
No known key found for this signature in database
GPG key ID: 8BA5575F3D11575D
2 changed files with 4 additions and 4 deletions

View file

@ -43,7 +43,7 @@ function get_pledge_meta_config( $context = '' ) {
'show_in_rest' => true,
'php_filter' => FILTER_VALIDATE_URL,
),
'pledge-email' => array(
'org-pledge-email' => array(
'single' => true,
'sanitize_callback' => 'sanitize_email',
'show_in_rest' => false,

View file

@ -6,15 +6,15 @@ namespace WordPressDotOrg\FiveForTheFuture\View;
?>
<div class="form-field">
<label for="5ftf-pledge-email" class="screen-reader-text">
<?php esc_html_e( 'Email', 'wordpressorg' ); ?>
<label for="5ftf-pledge-email">
<?php esc_html_e( 'Contact Email', 'wordpressorg' ); ?>
</label>
<input
type="email"
class="large-text"
id="5ftf-pledge-email"
name="org-pledge-email"
value="<?php echo esc_attr( $data['pledge-email'] ); ?>"
value="<?php echo esc_attr( $data['org-pledge-email'] ); ?>"
required
<?php echo $readonly ? 'readonly' : ''; ?>
/>