Ticket #13499: internal-link-show-post-parent.patch
File internal-link-show-post-parent.patch, 2.3 KB (added by , 13 years ago) |
---|
-
wp-includes/js/tinymce/plugins/wplink/css/wplink.dev.css
81 81 font-size: 11px; 82 82 float: right; 83 83 } 84 #wp-link .item-parent { 85 color: #666; 86 font-size: 10px; 87 88 display: block; 89 } 84 90 #search-results { 85 91 display: none; 86 92 } … … 105 111 #wp-link-update { 106 112 line-height: 23px; 107 113 float: right; 108 } 109 No newline at end of file 114 } -
wp-includes/js/tinymce/plugins/wplink/js/wplink.dev.js
356 356 list += '<input type="hidden" class="item-permalink" value="' + this['permalink'] + '" />'; 357 357 list += '<span class="item-title">'; 358 358 list += this['title'] ? this['title'] : '<em>'+ wpLinkL10n.untitled + '</em>'; 359 list += '</span><span class="item-info">' + this['info'] + '</span></li>'; 359 list += '</span>'; 360 361 list += '<span class="item-info">' + this['info'] + '</span>'; 362 if( this['parent'] ) 363 list += '<span class="item-parent">' + this['parent'] + '</span>'; 364 list += '</li>'; 360 365 alt = ! alt; 361 366 }); 362 367 } … … 419 424 }); 420 425 421 426 $(document).ready( wpLink.init ); 422 })(jQuery); 423 No newline at end of file 427 })(jQuery); -
wp-admin/includes/internal-linking.php
52 52 else 53 53 $info = $pts[ $post->post_type ]->labels->singular_name; 54 54 55 $parent = ''; 56 if($post->post_parent) { 57 $parent_post = get_post($post->post_parent); 58 $parent = __('Parent:') . ' ' . esc_html( strip_tags($parent_post->post_title) ); 59 } 60 55 61 $results[] = array( 56 62 'ID' => $post->ID, 57 63 'title' => esc_html( strip_tags($post->post_title) ), 58 64 'permalink' => get_permalink( $post->ID ), 59 65 'info' => $info, 66 'parent' => $parent 60 67 ); 61 68 } 62 69 … … 119 126 </form> 120 127 <?php 121 128 } 122 ?> 123 No newline at end of file 129 ?>