Making WordPress.org


Ignore:
Timestamp:
02/27/2018 03:37:12 AM (9 years ago)
Author:
obenland
Message:

2FA: Don't use submit and cancel buttons.

See #77.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-two-factor/wporg-two-factor.php

    r6789 r6791  
    397397                                <fieldset class="bbp-form">
    398398                                        <div>
    399                                                 <button type="cancel" class="button button-secondary alignright"><?php esc_html_e( 'Disable Two Factor Authentication', 'wporg' ); ?></button>
     399                                                <button type="button" class="button button-secondary two-factor-disable alignright"><?php esc_html_e( 'Disable Two Factor Authentication', 'wporg' ); ?></button>
    400400                                                <p class="status"><?php echo wp_kses_post( __( '<strong>Status:</strong> <span>Active</span>', 'wporg' ) ); ?></p>
    401401                                        </div>
    … …  
    424424                                                                <a href="" class="button button-secondary dashicons-before dashicons-download" id="two-factor-backup-codes-download" title="<?php esc_attr_e( 'Download Codes', 'wporg' ); ?>" download="two-factor-backup-codes.txt"><span class="screen-reader-text"><?php esc_html_e( 'Download Codes', 'wporg' ); ?></span></a>
    425425                                                        </span>
    426                                                         <button type="submit" class="button button-secondary" disabled="disabled"><?php esc_html_e( 'All Finished!', 'wporg' ); ?></button>
     426                                                        <button type="button" class="button two-factor-submit button-secondary" disabled="disabled"><?php esc_html_e( 'All Finished!', 'wporg' ); ?></button>
    427427                                                </div>
    428428                                        </div>
    … …  
    461461                                        ?>
    462462                                </small>
    463                                 <button type="cancel" class="button button-secondary alignleft"><?php esc_html_e( 'Cancel', 'wporg' ); ?></button>
    464                                 <button type="submit" class="button button-primary alignright"><?php esc_html_e( 'Enable', 'wporg' ); ?></button>
     463                                <button type="button" class="button button-secondary two-factor-cancel alignleft"><?php esc_html_e( 'Cancel', 'wporg' ); ?></button>
     464                                <button type="button" class="button button-primary two-factor-submit alignright"><?php esc_html_e( 'Enable', 'wporg' ); ?></button>
    465465                        </div>
    466466                </fieldset>
    … …  
    484484                                        ?>
    485485                                </small>
    486                                 <button type="cancel" class="button button-secondary alignleft"><?php esc_html_e( 'Cancel', 'wporg' ); ?></button>
    487                                 <button type="submit" class="button button-primary alignright"><?php esc_html_e( 'Enable', 'wporg' ); ?></button>
     486                                <button type="button" class="button button-secondary two-factor-cancel alignleft"><?php esc_html_e( 'Cancel', 'wporg' ); ?></button>
     487                                <button type="button" class="button button-primary two-factor-submit alignright"><?php esc_html_e( 'Enable', 'wporg' ); ?></button>
    488488                        </div>
    489489                </fieldset>
    … …  
    523523                        }
    524524
    525                         .two-factor-backup-codes-wrapper [type="submit"] {
     525                        .two-factor-backup-codes-wrapper .two-factor-submit {
    526526                                vertical-align: middle;
    527527                        }
Note: See TracChangeset for help on using the changeset viewer.