Ticket #16206: 16206.3.patch
File 16206.3.patch, 3.2 KB (added by , 9 years ago) |
---|
-
wp-includes/comment-template.php
1241 1241 * @global int $user_ID 1242 1242 * @global string $user_identity 1243 1243 * @global bool $overridden_cpage 1244 * @global bool $withcomments 1244 * @global bool $withcomments 1245 1245 * 1246 1246 * @param string $file Optional. The file to load. Default '/comments.php'. 1247 1247 * @param bool $separate_comments Optional. Whether to separate the comments by comment type. … … 2111 2111 2112 2112 $req = get_option( 'require_name_email' ); 2113 2113 $aria_req = ( $req ? " aria-required='true'" : '' ); 2114 $html_req = ( $req ? " required ='required'" : '' );2114 $html_req = ( $req ? " required" : '' ); 2115 2115 $html5 = 'html5' === $args['format']; 2116 2116 $fields = array( 2117 2117 'author' => '<p class="comment-form-author">' . '<label for="author">' . __( 'Name' ) . ( $req ? ' <span class="required">*</span>' : '' ) . '</label> ' . … … 2134 2134 $fields = apply_filters( 'comment_form_default_fields', $fields ); 2135 2135 $defaults = array( 2136 2136 'fields' => $fields, 2137 'comment_field' => '<p class="comment-form-comment"><label for="comment">' . _x( 'Comment', 'noun' ) . ' </label> <textarea id="comment" name="comment" cols="45" rows="8" maxlength="65525" aria-required="true" required="required"></textarea></p>',2137 'comment_field' => '<p class="comment-form-comment"><label for="comment">' . _x( 'Comment', 'noun' ) . ' <span class="required">*</span></label> <textarea id="comment" name="comment" cols="45" rows="8" maxlength="65525" aria-required="true" required></textarea></p>', 2138 2138 /** This filter is documented in wp-includes/link-template.php */ 2139 2139 'must_log_in' => '<p class="must-log-in">' . sprintf( __( 'You must be <a href="%s">logged in</a> to post a comment.' ), wp_login_url( apply_filters( 'the_permalink', get_permalink( $post_id ) ) ) ) . '</p>', 2140 2140 /** This filter is documented in wp-includes/link-template.php */ 2141 2141 'logged_in_as' => '<p class="logged-in-as">' . sprintf( __( '<a href="%1$s" aria-label="Logged in as %2$s. Edit your profile.">Logged in as %2$s</a>. <a href="%3$s">Log out?</a>' ), get_edit_user_link(), $user_identity, wp_logout_url( apply_filters( 'the_permalink', get_permalink( $post_id ) ) ) ) . '</p>', 2142 2142 'comment_notes_before' => '<p class="comment-notes"><span id="email-notes">' . __( 'Your email address will not be published.' ) . '</span>'. ( $req ? $required_text : '' ) . '</p>', 2143 'comment_notes_logged_in_before' => '<p class="comment-notes">'. $required_text . '</p>', 2143 2144 'comment_notes_after' => '', 2144 2145 'id_form' => 'commentform', 2145 2146 'id_submit' => 'submit', … … 2215 2216 do_action( 'comment_form_top' ); 2216 2217 2217 2218 if ( is_user_logged_in() ) : 2219 2218 2220 /** 2219 2221 * Filter the 'logged in' message for the comment form for display. 2220 2222 * … … 2228 2230 */ 2229 2231 echo apply_filters( 'comment_form_logged_in', $args['logged_in_as'], $commenter, $user_identity ); 2230 2232 2233 echo $args['comment_notes_logged_in_before']; 2234 2231 2235 /** 2232 2236 * Fires after the is_user_logged_in() check in the comment form. 2233 2237 *