X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/bf5c68485ef07868ad0a91168ecd0092af7661ae..refs/tags/wordpress-3.4:/wp-admin/export.php diff --git a/wp-admin/export.php b/wp-admin/export.php index 70065524..8257b518 100644 --- a/wp-admin/export.php +++ b/wp-admin/export.php @@ -41,7 +41,7 @@ add_action( 'admin_head', 'add_js' ); get_current_screen()->add_help_tab( array( 'id' => 'overview', 'title' => __('Overview'), - 'content' => '

' . __('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 choose for the WXR file to include only certain posts or pages by setting the dropdown filters to limit the export by category, author, date range by month, or publishing status.') . '

' . + 'content' => '

' . __('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 choose for the WXR file to include only certain posts or pages by setting the dropdown filters to limit the export by category, author, date range by month, or publishing status.') . '

' . '

' . __('Once generated, your WXR file can be imported by another WordPress site or by another blogging platform able to access this format.') . '

', ) ); @@ -95,15 +95,15 @@ if ( isset( $_GET['download'] ) ) { require_once ('admin-header.php'); -function export_date_options() { +function export_date_options( $post_type = 'post' ) { global $wpdb, $wp_locale; - $months = $wpdb->get_results( " + $months = $wpdb->get_results( $wpdb->prepare( " SELECT DISTINCT YEAR( post_date ) AS year, MONTH( post_date ) AS month FROM $wpdb->posts - WHERE post_type = 'post' AND post_status != 'auto-draft' + WHERE post_type = %s AND post_status != 'auto-draft' ORDER BY post_date DESC - " ); + ", $post_type ) ); $month_count = count( $months ); if ( !$month_count || ( 1 == $month_count && 0 == $months[0]->month ) ) @@ -130,8 +130,8 @@ function export_date_options() {

-

-

+

+