- md5
- 2cc49c9d20345f46f74e00d55d7ef10a
- sha1
- e0182852e90e14fff8ac27c130c3ed1e7732ee43
- sha256
- 818ed84730428a746dd27961167670e8bd3bcb5ed554d6e74343d6e76f1373cd
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
<?php
/**
* WordPress Export Administration Panel
*
* @package WordPress
* @subpackage Administration
*/
/** Load WordPress Bootstrap */
require_once ('admin.php');
/** Load WordPress export API */
require_once('includes/export.php');
$title = __('Export');
if ( isset( $_GET['download'] ) ) {
$author = isset($_GET['author']) ? $_GET['author'] : 'all';
export_wp( $author );
die();
}
require_once ('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo esc_html( $title ); ?></h2>
<p><?php _e('When you click the button below WordPress will create an XML file for you to save to your computer.'); ?></p>
<p><?php _e('This format, which we call WordPress eXtended RSS or WXR, will contain your posts, pages, comments, custom fields, categories, and tags.'); ?></p>
<p><?php _e('Once you’ve saved the download file, you can use the Import function on another WordPress blog to import this blog.'); ?></p>
<form action="" method="get">
<h3><?php _e('Options'); ?></h3>
<table class="form-table">
<tr>
<th><label for="author"><?php _e('Restrict Author'); ?></label></th>
<td>
<select name="author" id="author">
<option value="all" selected="selected"><?php _e('All Authors'); ?></option>
<?php
$authors = $wpdb->get_col( "SELECT post_author FROM $wpdb->posts GROUP BY post_author" );
foreach ( $authors as $id ) {
$o = get_userdata( $id );
echo "<option value='" . esc_attr($o->ID) . "'>$o->display_name</option>";
}
?>
</select>
</td>
</tr>
</table>
<p class="submit"><input type="submit" name="submit" class="button" value="<?php esc_attr_e('Download Export File'); ?>" />
<input type="hidden" name="download" value="true" />
</p>
</form>
</div>
<?php
include ('admin-footer.php');
?>
The same content is in 8 releases, WordPress 2.8-beta2 to 2.8.2. See them all, or every version of this file.