Changeset 11720
- Timestamp:
- 07/18/2009 11:21:00 PM (15 years ago)
- Location:
- branches/2.8
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.8/wp-admin/comment.php
r11204 r11720 23 23 * @param string $msg Error Message. Assumed to contain HTML and be sanitized. 24 24 */ 25 function comment_footer_die( $msg ) { //25 function comment_footer_die( $msg ) { 26 26 echo "<div class='wrap'><p>$msg</p></div>"; 27 27 include('admin-footer.php'); … … 120 120 <tr> 121 121 <th scope="row"><?php _e('URL'); ?></th> 122 <td><a href= '<?php echo $comment->comment_author_url; ?>'><?php echo $comment->comment_author_url; ?></a></td>122 <td><a href="<?php echo $comment->comment_author_url; ?>"><?php echo $comment->comment_author_url; ?></a></td> 123 123 </tr> 124 124 <?php } ?> -
branches/2.8/wp-admin/edit-form-comment.php
r11383 r11720 25 25 <input type="hidden" name="user_ID" value="<?php echo (int) $user_ID ?>" /> 26 26 <input type="hidden" name="action" value='<?php echo $form_action . $form_extra ?>' /> 27 <?php28 29 $email = esc_attr( $comment->comment_author_email );30 $url = esc_attr( $comment->comment_author_url );31 // add_meta_box('submitdiv', __('Save'), 'comment_submit_meta_box', 'comment', 'side', 'core');32 ?>33 27 34 28 <div id="side-info-column" class="inner-sidebar"> … … 96 90 <td class="first"> 97 91 <?php 98 if ( $ email ) {92 if ( $comment->comment_author_email ) { 99 93 printf( __( 'E-mail (%s):' ), get_comment_author_email_link( __( 'send e-mail' ), '', '' ) ); 100 94 } else { … … 102 96 } 103 97 ?></td> 104 <td><input type="text" name="newcomment_author_email" size="30" value="<?php echo esc_attr($email); ?>" tabindex="2" id="email" /></td>98 <td><input type="text" name="newcomment_author_email" size="30" value="<?php echo $comment->comment_author_email; ?>" tabindex="2" id="email" /></td> 105 99 </tr> 106 100 <tr valign="top"> 107 101 <td class="first"> 108 102 <?php 109 $url = get_comment_author_url(); 110 if ( ! empty( $url ) && 'http://' != $url ) { 111 $link = "<a href='$url' rel='external nofollow' target='_blank'>" . __('visit site') . "</a>"; 103 if ( ! empty( $comment->comment_author_url ) && 'http://' != $comment->comment_author_url ) { 104 $link = '<a href="' . $comment->comment_author_url . '" rel="external nofollow" target="_blank">' . __('visit site') . '</a>'; 112 105 printf( __( 'URL (%s):' ), apply_filters('get_comment_author_link', $link ) ); 113 106 } else { -
branches/2.8/wp-admin/includes/comment.php
r11383 r11720 90 90 $comment->comment_author = format_to_edit( $comment->comment_author ); 91 91 $comment->comment_author_email = format_to_edit( $comment->comment_author_email ); 92 $comment->comment_author_url = format_to_edit( $comment->comment_author_url ); 92 93 $comment->comment_author_url = esc_url($comment->comment_author_url); 93 $comment->comment_author_url = format_to_edit( $comment->comment_author_url );94 94 95 95 return $comment; -
branches/2.8/wp-admin/includes/template.php
r11673 r11720 2086 2086 if ( 'http://' == $author_url ) 2087 2087 $author_url = ''; 2088 $author_url_display = $author_url; 2089 $author_url_display = str_replace('http://www.', '', $author_url_display); 2090 $author_url_display = str_replace('http://', '', $author_url_display); 2088 $author_url_display = preg_replace('|http://(www\.)?|i', '', $author_url); 2091 2089 if ( strlen($author_url_display) > 50 ) 2092 2090 $author_url_display = substr($author_url_display, 0, 49) . '...'; -
branches/2.8/wp-includes/comment-template.php
r11435 r11720 195 195 global $comment; 196 196 $url = ('http://' == $comment->comment_author_url) ? '' : $comment->comment_author_url; 197 $url = esc_url( $url, array('http', 'https') ); 197 198 return apply_filters('get_comment_author_url', $url); 198 199 }
Note: See TracChangeset
for help on using the changeset viewer.