esc_attr_e example

<?php _e( 'New Password' ); ?></label></th> <td> <input type="hidden" value=" " /><!-- #24364 workaround --> <button type="button" class="button wp-generate-pw hide-if-no-js" aria-expanded="false"><?php _e( 'Set New Password' ); ?></button> <div class="wp-pwd hide-if-js"> <div class="password-input-wrapper"> <input type="password" name="pass1" id="pass1" class="regular-text" value="" autocomplete="new-password" spellcheck="false" data-pw="<?php echo esc_attr( wp_generate_password( 24 ) ); ?>" aria-describedby="pass-strength-result" /> <div style="display:none" id="pass-strength-result" aria-live="polite"></div> </div> <button type="button" class="button wp-hide-pw hide-if-no-js" data-toggle="0" aria-label="<?php esc_attr_e( 'Hide password' ); ?>"> <span class="dashicons dashicons-hidden" aria-hidden="true"></span> <span class="text"><?php _e( 'Hide' ); ?></span> </button> <button type="button" class="button wp-cancel-pw hide-if-no-js" data-toggle="0" aria-label="<?php esc_attr_e( 'Cancel password change' ); ?>"> <span class="dashicons dashicons-no" aria-hidden="true"></span> <span class="text"><?php _e( 'Cancel' ); ?></span> </button> </div> </td> </tr> <tr class="user-pass2-wrap hide-if-js"> <th scope="row"><label for="pass2">
<?php                 /** This filter is documented in wp-admin/edit-form-advanced.php */
                echo apply_filters( 'enter_title_here', __( 'Title' )$post );
                ?> </label> <input type="text" name="post_title" id="title" autocomplete="off" /> </div> <div class="textarea-wrap" id="description-wrap"> <label for="content"><?php _e( 'Content' ); ?></label> <textarea name="content" id="content" placeholder="<?php esc_attr_e( 'What&#8217;s on your mind?' ); ?>" class="mceEditor" rows="3" cols="15" autocomplete="off"></textarea> </div> <p class="submit"> <input type="hidden" name="action" id="quickpost-action" value="post-quickdraft-save" /> <input type="hidden" name="post_ID" value="<?php echo $post_ID; ?>" /> <input type="hidden" name="post_type" value="post" /> <?php wp_nonce_field( 'add-post' ); ?> <?php submit_button( __( 'Save Draft' ), 'primary', 'save', false, array( 'id' => 'save-post' ) ); ?> <br class="clear" /> </p> </form>
?> </main><!-- #main --> </div><!-- #primary --> </div><!-- #content --> <?php get_template_part( 'template-parts/footer/footer-widgets' ); ?> <footer id="colophon" class="site-footer"> <?php if ( has_nav_menu( 'footer' ) ) : ?> <nav aria-label="<?php esc_attr_e( 'Secondary menu', 'twentytwentyone' ); ?>" class="footer-navigation"> <ul class="footer-navigation-wrapper"> <?php                     wp_nav_menu(
                        array(
                            'theme_location' => 'footer',
                            'items_wrap'     => '%3$s',
                            'container'      => false,
                            'depth'          => 1,
                            'link_before'    => '<span>',
                            'link_after'     => '</span>',
                            'fallback_cb'    => false,
                        )
<?php _e( 'Choose an image from your computer:' ); ?></label><br /> <input type="file" id="upload" name="import" /> <input type="hidden" name="action" value="save" /> <?php wp_nonce_field( 'custom-background-upload', '_wpnonce-custom-background-upload' ); ?> <?php submit_button( __( 'Upload' ), '', 'submit', false ); ?> </p> <p> <label for="choose-from-library-link"><?php _e( 'Or choose an image from your media library:' ); ?></label><br /> <button id="choose-from-library-link" class="button" data-choose="<?php esc_attr_e( 'Choose a Background Image' ); ?>" data-update="<?php esc_attr_e( 'Set as background' ); ?>"><?php _e( 'Choose Image' ); ?></button> </p> </form> </td> </tr> <?php endif; ?> </tbody> </table> <h2><?php _e( 'Display Options' ); ?></h2> <form method="post"> <table class="form-table" role="presentation"> <tbody>
/** * Prints the necessary markup for the embed sharing button. * * @since 4.4.0 */
function print_embed_sharing_button() {
    if ( is_404() ) {
        return;
    }
    ?> <div class="wp-embed-share"> <button type="button" class="wp-embed-share-dialog-open" aria-label="<?php esc_attr_e( 'Open sharing dialog' ); ?>"> <span class="dashicons dashicons-share"></span> </button> </div> <?php }

/** * Prints the necessary markup for the embed sharing dialog. * * @since 4.4.0 */
update_user_meta( get_current_user_id(), 'wporg_favorites', $user );
            } else {
                $user = get_user_option( 'wporg_favorites' );
            }
            ?> <p class="install-help"><?php _e( 'If you have marked themes as favorites on WordPress.org, you can browse them here.' ); ?></p> <p> <label for="wporg-username-input"><?php _e( 'Your WordPress.org username:' ); ?></label> <input type="hidden" id="wporg-username-nonce" name="_wpnonce" value="<?php echo esc_attr( wp_create_nonce( $action ) ); ?>" /> <input type="search" id="wporg-username-input" value="<?php echo esc_attr( $user ); ?>" /> <input type="button" class="button favorites-form-submit" value="<?php esc_attr_e( 'Get Favorites' ); ?>" /> </p> </div> <div class="filter-drawer"> <div class="buttons"> <button type="button" class="apply-filters button"><?php _e( 'Apply Filters' ); ?><span></span></button> <button type="button" class="clear-filters button" aria-label="<?php esc_attr_e( 'Clear current filters' ); ?>"><?php _e( 'Clear' ); ?></button> </div> <?php         // Use the core list, rather than the .org API, due to inconsistencies         // and to ensure tags are translated.
<?php selected( 'term', $type ); ?>><?php _e( 'Keyword' ); ?></option> <option value="author"<?php selected( 'author', $type ); ?>><?php _e( 'Author' ); ?></option> <option value="tag"<?php selected( 'tag', $type ); ?>><?php _ex( 'Tag', 'Plugin Installer' ); ?></option> </select> <label class="screen-reader-text" for="search-plugins"> <?php             /* translators: Hidden accessibility text. */
            _e( 'Search Plugins' );
            ?> </label> <input type="search" name="s" id="search-plugins" value="<?php echo esc_attr( $term ); ?>" class="wp-filter-search" placeholder="<?php esc_attr_e( 'Search plugins...' ); ?>" /> <?php submit_button( __( 'Search Plugins' ), 'hide-if-js', false, false, array( 'id' => 'search-submit' ) ); ?> </form> <?php }

/** * Displays a form to upload plugins from zip files. * * @since 2.8.0 */
function install_plugins_upload() {
    
<?php if ( wp_check_post_lock( $post->ID ) ) { ?> disabled="disabled" <?php } else { ?> <# if ( data.attributes.current ) { #> disabled="disabled" <# } #> <?php } ?> <# if ( data.attributes.autosave ) { #> type="button" class="restore-revision button button-primary" value="<?php esc_attr_e( 'Restore This Autosave' ); ?>" /> <# } else { #> type="button" class="restore-revision button button-primary" value="<?php esc_attr_e( 'Restore This Revision' ); ?>" /> <# } #> <# } #> </div> <# if ( 'tooltip' === data.type ) { #> <div class="revisions-tooltip-arrow"><span></span></div> <# } #> <# } #> </script> <script id="tmpl-revisions-diff" type="text/html"> <div class="loading-indicator"><span class="spinner"></span></div> <div class="diff-error">
$option = (int) get_user_meta( get_current_user_id(), 'show_welcome_panel', true );
    // 0 = hide, 1 = toggled to show or single site creator, 2 = multisite site owner.     $hide = ( 0 === $option || ( 2 === $option && wp_get_current_user()->user_email !== get_option( 'admin_email' ) ) );
    if ( $hide ) {
        $classes .= ' hidden';
    }
    ?> <div id="welcome-panel" class="<?php echo esc_attr( $classes ); ?>"> <?php wp_nonce_field( 'welcome-panel-nonce', 'welcomepanelnonce', false ); ?> <a class="welcome-panel-close" href="<?php echo esc_url( admin_url( '?welcome=0' ) ); ?>" aria-label="<?php esc_attr_e( 'Dismiss the welcome panel' ); ?>"><?php _e( 'Dismiss' ); ?></a> <?php         /** * Fires when adding content to the welcome panel on the admin dashboard. * * To remove the default welcome panel, use remove_action(): * * remove_action( 'welcome_panel', 'wp_welcome_panel' ); * * @since 3.5.0 */
        do_action( 'welcome_panel' );
        
/* translators: %s: Version number. */
                        __( 'WordPress %s' ),
                        $display_version
                    );
                    ?> </h1> </div> <div class="about__header-text"></div> </div> <nav class="about__header-navigation nav-tab-wrapper wp-clearfix" aria-label="<?php esc_attr_e( 'Secondary menu' ); ?>"> <a href="about.php" class="nav-tab nav-tab-active" aria-current="page"><?php _e( 'What&#8217;s New' ); ?></a> <a href="credits.php" class="nav-tab"><?php _e( 'Credits' ); ?></a> <a href="freedoms.php" class="nav-tab"><?php _e( 'Freedoms' ); ?></a> <a href="privacy.php" class="nav-tab"><?php _e( 'Privacy' ); ?></a> <a href="contribute.php" class="nav-tab"><?php _e( 'Get Involved' ); ?></a> </nav> <div class="about__section changelog has-subtle-background-color"> <div class="column"> <h2><?php _e( 'Maintenance Release' ); ?></h2> <p>
<?php _e( 'Restore original image' ); ?> <span class="dashicons dashicons-arrow-down imgedit-help-toggle"></span></button></h2> <div class="imgedit-help imgedit-restore"> <p> <?php                     _e( 'Discard any changes and restore the original image.' );
                    if ( ! defined( 'IMAGE_EDIT_OVERWRITE' ) || ! IMAGE_EDIT_OVERWRITE ) {
                        echo ' ' . __( 'Previously edited copies of the image will not be deleted.' );
                    }
                    ?> </p> <div class="imgedit-submit"> <input type="button" onclick="imageEdit.action(<?php echo "$post_id, '$nonce'"; ?>, 'restore')" class="button button-primary" value="<?php esc_attr_e( 'Restore image' ); ?>" <?php echo $can_restore; ?> /> </div> </div> </div> </div> <?php } ?> <div class="imgedit-group"> <div id="imgedit-crop" tabindex="-1" class="imgedit-group-controls"> <div class="imgedit-group-top"> <h2><?php _e( 'Crop Image' ); ?></h2> <button type="button" class="dashicons dashicons-editor-help imgedit-help-toggle" onclick="imageEdit.toggleHelp(this);" aria-expanded="false"><span class="screen-reader-text"> <?php
<input type="hidden" name="interim-login" value="1" /> <?php } ?> <?php if ( isset( $_GET['redirect_to'] ) && '' !== $_GET['redirect_to'] ) { ?> <input type="hidden" name="redirect_to" value="<?php echo sanitize_url( $_GET['redirect_to'] ); ?>" /> <?php } ?> <?php if ( isset( $_GET['action'] ) && '' !== $_GET['action'] ) { ?> <input type="hidden" name="action" value="<?php echo esc_attr( $_GET['action'] ); ?>" /> <?php } ?> <input type="submit" class="button" value="<?php esc_attr_e( 'Change' ); ?>"> </form> </div> <?php } ?> <?php } ?> <?php
    if ( ! empty( $input_id ) ) {
        ?> <script type="text/javascript"> try{document.getElementById('<?php echo $input_id; ?>').focus();}catch(e){} if(typeof wpOnload==='function')wpOnload(); </script>
        /** * Fires when hidden sign-up form fields output when creating another site or user. * * @since MU (3.0.0) * * @param string $context A string describing the steps of the sign-up process. The value can be * 'create-another-site', 'validate-user', or 'validate-site'. */
        do_action( 'signup_hidden_fields', 'create-another-site' );
        ?> <?php show_blog_form( $blogname$blog_title$errors ); ?> <p class="submit"><input type="submit" name="submit" class="submit" value="<?php esc_attr_e( 'Create Site' ); ?>" /></p> </form> <?php }

/** * Validates a new site sign-up for an existing user. * * @since MU (3.0.0) * * @global string $blogname The new site's subdomain or directory name. * @global string $blog_title The new site's title. * @global WP_Error $errors Existing errors in the global scope. * @global string $domain The new site's domain. * @global string $path The new site's path. * * @return null|bool True if site signup was validated, false on error. * The function halts all execution if the user is not logged in. */
<?php _e( 'Results are still loading&hellip;' ); ?> </div> </div> <nav class="<?php echo implode( ' ', $wrapper_classes ); ?>" aria-label="<?php esc_attr_e( 'Secondary menu' ); ?>"> <?php         $tabs_slice = $tabs;

        /* * If there are more than 4 tabs, only output the first 3 inline, * the remaining links will be added to a sub-navigation. */
        if ( count( $tabs ) > 4 ) {
            $tabs_slice = array_slice( $tabs, 0, 3 );
        }

        
</span> <?php _e( 'Add a Widget' ); ?> </h3> </div> <div id="available-widgets-filter"> <label class="screen-reader-text" for="widgets-search"> <?php                     /* translators: Hidden accessibility text. */
                    _e( 'Search Widgets' );
                    ?> </label> <input type="text" id="widgets-search" placeholder="<?php esc_attr_e( 'Search widgets&hellip;' ); ?>" aria-describedby="widgets-search-desc" /> <div class="search-icon" aria-hidden="true"></div> <button type="button" class="clear-results"><span class="screen-reader-text"> <?php                     /* translators: Hidden accessibility text. */
                    _e( 'Clear Results' );
                    ?> </span></button> <p class="screen-reader-text" id="widgets-search-desc"> <?php                     /* translators: Hidden accessibility text. */
                    _e( 'The search results will be updated as you type.' );
                    
Home | Imprint | This part of the site doesn't use cookies.