Make WordPress Core

Ticket #34267: 34267.2.patch

File 34267.2.patch, 3.4 KB (added by afercia, 10 years ago)
  • src/wp-admin/css/forms.css

     
    957957        margin: 25px;
    958958}
    959959
     960#request-filesystem-credentials-title {
     961    font-size: 1.3em;
     962    margin: 1em 0;
     963}
     964
     965.request-filesystem-credentials-form legend {
     966        font-size: 1em;
     967        padding: 1.33em 0;
     968        font-weight: 600;
     969}
     970
    960971.request-filesystem-credentials-form input[type="text"],
    961972.request-filesystem-credentials-form input[type="password"] {
    962973        display: block;
  • src/wp-admin/includes/file.php

     
    10011001 *
    10021002 * @todo Properly mark optional arguments as such
    10031003 *
     1004 * @global string $pagenow
     1005 *
    10041006 * @param string $form_post    the URL to post the form to
    10051007 * @param string $type         the chosen Filesystem method in use
    10061008 * @param bool   $error        if the current request has failed to connect
     
    10101012 * @return bool False on failure. True on success.
    10111013 */
    10121014function request_filesystem_credentials($form_post, $type = '', $error = false, $context = false, $extra_fields = null, $allow_relaxed_file_ownership = false ) {
     1015        global $pagenow;
    10131016
    10141017        /**
    10151018         * Filter the filesystem credentials form output.
     
    11411144</script>
    11421145<form action="<?php echo esc_url( $form_post ) ?>" method="post">
    11431146<div id="request-filesystem-credentials-form" class="request-filesystem-credentials-form">
    1144 <h3 id="request-filesystem-credentials-title"><?php _e( 'Connection Information' ) ?></h3>
     1147<?php
     1148// Print a H1 heading in the FTP credentials modal dialog, default is a H2.
     1149$heading_tag = 'h2';
     1150if ( 'plugins.php' === $pagenow || 'plugin-install.php' === $pagenow ) {
     1151        $heading_tag = 'h1';
     1152}
     1153echo "<$heading_tag id='request-filesystem-credentials-title'>" . __( 'Connection Information' ) . "</$heading_tag>";
     1154?>
    11451155<p id="request-filesystem-credentials-desc"><?php
    11461156        $label_user = __('Username');
    11471157        $label_pass = __('Password');
     
    11791189        </label>
    11801190</div>
    11811191<?php if ( isset($types['ssh']) ) : ?>
    1182 <h4><?php _e('Authentication Keys') ?></h4>
     1192<fieldset>
     1193<legend><?php _e( 'Authentication Keys' ); ?></legend>
    11831194<label for="public_key">
    11841195        <span class="field-title"><?php _e('Public Key:') ?></span>
    11851196        <input name="public_key" type="text" id="public_key" aria-describedby="auth-keys-desc" value="<?php echo esc_attr($public_key) ?>"<?php disabled( defined('FTP_PUBKEY') ); ?> />
     
    11881199        <span class="field-title"><?php _e('Private Key:') ?></span>
    11891200        <input name="private_key" type="text" id="private_key" value="<?php echo esc_attr($private_key) ?>"<?php disabled( defined('FTP_PRIKEY') ); ?> />
    11901201</label>
     1202</fieldset>
    11911203<span id="auth-keys-desc"><?php _e('Enter the location on the server where the public and private keys are located. If a passphrase is needed, enter that in the password field above.') ?></span>
    11921204<?php endif; ?>
    1193 <h4><?php _e('Connection Type') ?></h4>
    1194 <fieldset><legend class="screen-reader-text"><span><?php _e('Connection Type') ?></span></legend>
     1205<fieldset>
     1206<legend><?php _e( 'Connection Type' ); ?></legend>
    11951207<?php
    11961208        $disabled = disabled( (defined('FTP_SSL') && FTP_SSL) || (defined('FTP_SSH') && FTP_SSH), true, false );
    11971209        foreach ( $types as $name => $text ) : ?>