]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/import/livejournal.php
Wordpress 2.0.11
[autoinstalls/wordpress.git] / wp-admin / import / livejournal.php
index e8c48c4ad93b4e8b87948b4115dcc96a3f0c9e83..3c9cdab76ac61ac6a521dc26d59c9c6cb90136fe 100644 (file)
@@ -80,7 +80,7 @@ class LJ_Import {
                        $comments = $comments[1];
                        
                        if ( $comments ) {
                        $comments = $comments[1];
                        
                        if ( $comments ) {
-                               $comment_post_ID = $post_id;
+                               $comment_post_ID = (int) $post_id;
                                $num_comments = 0;
                                foreach ($comments as $comment) {
                                        preg_match('|<event>(.*?)</event>|is', $comment, $comment_content);
                                $num_comments = 0;
                                foreach ($comments as $comment) {
                                        preg_match('|<event>(.*?)</event>|is', $comment, $comment_content);
@@ -153,6 +153,7 @@ class LJ_Import {
                                $this->greet();
                                break;
                        case 1 :
                                $this->greet();
                                break;
                        case 1 :
+                               check_admin_referer('import-upload');
                                $this->import();
                                break;
                }
                                $this->import();
                                break;
                }
@@ -167,5 +168,5 @@ class LJ_Import {
 
 $livejournal_import = new LJ_Import();
 
 
 $livejournal_import = new LJ_Import();
 
-register_importer('livejournal', 'LiveJournal', __('Import posts from LiveJournal'), array ($livejournal_import, 'dispatch'));
+register_importer('livejournal', __('LiveJournal'), __('Import posts from LiveJournal'), array ($livejournal_import, 'dispatch'));
 ?>
 ?>