Changeset 3769

Show
Ignore:
Timestamp:
05/10/06 20:34:17 (3 years ago)
Author:
matt
Message:

New import and export, v0.1

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-admin/import.php

    r3262 r3769  
    22require_once ('admin.php'); 
    33$title = __('Import'); 
    4 $parent_file = 'import.php'; 
     4$parent_file = 'edit.php'; 
    55require_once ('admin-header.php'); 
    66?> 
     
    3131} else { 
    3232?> 
    33 <table width="100%" cellpadding="3" cellspacing="3"> 
     33<table class="widefat"> 
    3434 
    3535<?php 
     
    4343        echo " 
    4444            <tr $style> 
    45                 <td class=\"togl\">$action</td> 
    46                 <td class=\"desc\">{$data[1]}</td> 
     45                <td class='import-system'>$action</td> 
     46                <td class='desc'>{$data[1]}</td> 
    4747            </tr>"; 
    4848    } 
  • trunk/wp-admin/import/blogger.php

    r3609 r3769  
    663663$blogger_import = new Blogger_Import(); 
    664664 
    665 register_importer('blogger', 'Blogger', __('Import posts and comments from a Blogger account'), array ($blogger_import, 'start')); 
     665register_importer('blogger', 'Blogger and Blogspot', __('Import <strong>posts and comments</strong> from your Blogger account'), array ($blogger_import, 'start')); 
    666666 
    667667?> 
  • trunk/wp-admin/import/mt.php

    r3749 r3769  
    1212    function header() { 
    1313        echo '<div class="wrap">'; 
    14         echo '<h2>'.__('Import Movable Type').'</h2>'; 
     14        echo '<h2>'.__('Import Movable Type and Typepad').'</h2>'; 
    1515    } 
    1616 
     
    149149        foreach ($authors as $author) { 
    150150            ++ $j; 
    151             echo '<li><i>'.$author.'</i><br />'.'<input type="text" value="'.$author.'" name="'.'user[]'.'" maxlength="30">'; 
     151            echo '<li>Current author: <strong>'.$author.'</strong><br />'.'Create user <input type="text" value="'.$author.'" name="'.'user[]'.'" maxlength="30"> <br /> or map to existing '; 
    152152            $this->users_form($j); 
    153153            echo '</li>'; 
     
    163163        $file = wp_import_handle_upload(); 
    164164        if ( isset($file['error']) ) { 
    165             echo $file['error']; 
     165            $this->header(); 
     166            echo '<p>Sorry, there has been an error.</p>'; 
     167            echo '<p><strong>' . $file['error'] . '</strong></p>'; 
     168            $this->footer(); 
    166169            return; 
    167170        } 
     
    332335                } 
    333336                if ( $num_comments ) 
    334                     printf(__('(%s comments)'), $num_comments); 
     337                    printf(__(' (%s comments)'), $num_comments); 
    335338 
    336339                // Finally the pings 
     
    380383                } 
    381384                if ( $num_pings ) 
    382                     printf(__('(%s pings)'), $num_pings); 
     385                    printf(__(' (%s pings)'), $num_pings); 
    383386 
    384387                echo "</li>"; 
     
    395398    function import() { 
    396399        $this->id = (int) $_GET['id']; 
     400         
    397401        $this->file = get_attached_file($this->id); 
    398402        $this->get_authors_from_post(); 
     
    427431$mt_import = new MT_Import(); 
    428432 
    429 register_importer('mt', 'Movable Type', __('Import posts and comments from your Movable Type blog'), array ($mt_import, 'dispatch')); 
     433register_importer('mt', 'Movable Type and Typepad', __('Imports <strong>posts and comments</strong> from your Movable Type or Typepad blog'), array ($mt_import, 'dispatch')); 
    430434?> 
  • trunk/wp-admin/menu.php

    r3756 r3769  
    1616    $menu[35] = array(__('Profile'), 'read', 'profile.php'); 
    1717$menu[40] = array(__('Options'), 'manage_options', 'options-general.php'); 
    18 $menu[45] = array(__('Import'), 'import', 'import.php'); 
     18 
    1919 
    2020$submenu['post-new.php'][5] = array(__('Write Post'), 'edit_posts', 'post-new.php'); 
     
    2828$submenu['edit.php'][25] = array(sprintf(__("Awaiting Moderation (%s)"), "<span id='awaitmod'>$awaiting_mod</span>"), 'edit_posts', 'moderation.php'); 
    2929$submenu['edit.php'][30] = array(__('Files'), 'edit_files', 'templates.php'); 
     30$submenu['edit.php'][35] = array(__('Import'), 'import', 'import.php'); 
     31$submenu['edit.php'][40] = array(__('Export'), 'import', 'export.php'); 
    3032 
    3133$submenu['link-manager.php'][5] = array(__('Manage Bookmarks'), 'manage_links', 'link-manager.php');