Ticket #15197: 15197.filtering-js.diff
File 15197.filtering-js.diff, 2.3 KB (added by , 14 years ago) |
---|
-
wp-admin/export.php
16 16 require_once('./includes/export.php'); 17 17 $title = __('Export'); 18 18 19 function add_js() { 20 ?> 21 <script type="text/javascript"> 22 //<![CDATA[ 23 jQuery(document).ready(function($){ 24 var form = $('#export-filters'), 25 filters = form.find('.export-filters'); 26 filters.hide(); 27 form.find('input:radio').change(function() { 28 filters.slideUp('fast'); 29 switch ( $(this).val() ) { 30 case 'posts': $('#post-filters').slideDown(); break; 31 case 'pages': $('#page-filters').slideDown(); break; 32 } 33 }); 34 }); 35 //]]> 36 </script> 37 <?php 38 } 39 add_action( 'admin_head', 'add_js' ); 40 19 41 add_contextual_help( $current_screen, 20 42 '<p>' . __('You can export a file of your site’s content in order to import it into another installation or platform. The export file will be an XML file format called WXR. Posts, pages, comments, custom fields, categories, and tags can be included. You can set filters to have the WXR file only include a certain date, author, category, tag, all posts or all pages, certain publishing statuses.') . '</p>' . 21 43 '<p>' . __('Once generated, your WXR file can be imported by another WordPress site or by another blogging platform able to access this format.') . '</p>' . … … 142 164 <p><label><input type="radio" name="content" value="pages" /> <?php _e( 'Pages' ); ?></label></p> 143 165 <ul id="page-filters" class="export-filters"> 144 166 <li> 145 <label><?php _e( 'Author :' ); ?></label>167 <label><?php _e( 'Authors:' ); ?></label> 146 168 <?php wp_dropdown_users( array( 'name' => 'page_author', 'multi' => true, 'show_option_all' => __('All') ) ); ?> 147 169 </li> 148 170 <li> -
wp-admin/includes/export.php
243 243 244 244 foreach( $authors as $author ) { 245 245 echo "\t<wp:author>"; 246 echo '<wp:author_id>' . $author->ID . '</wp:author_id>'; 246 247 echo '<wp:author_login>' . $author->user_login . '</wp:author_login>'; 247 248 echo '<wp:author_email>' . $author->user_email . '</wp:author_email>'; 248 249 echo '<wp:author_display_name>' . wxr_cdata( $author->display_name ) . '</wp:author_display_name>';