diff --git a/wp-admin/import/stp.php b/wp-admin/import/stp.php index f3b6d30e80..9d5371cf5d 100644 --- a/wp-admin/import/stp.php +++ b/wp-admin/import/stp.php @@ -1,7 +1,5 @@ '; echo '
'.__('To accommodate larger databases for those tag-crazy authors out there, we have made this into an easy 4-step program to help you kick that nasty Simple Tagging habit. Just keep clicking along and we will let you know when you are in the clear!').'
'; echo ''.__('Don’t be stupid - backup your database before proceeding!').'
'; echo ''; echo ''; } - function dispatch () { if ( empty( $_GET['step'] ) ) { $step = 0; } else { $step = (int) $_GET['step']; } - // load the header $this->header(); - switch ( $step ) { case 0 : $this->greet(); break; case 1 : - check_admin_referer('import-utw'); + check_admin_referer('import-stp'); $this->import_posts(); break; case 2: - check_admin_referer('import-utw'); + check_admin_referer('import-stp'); $this->import_t2p(); break; case 3: - check_admin_referer('import-utw'); + check_admin_referer('import-stp'); $this->cleanup_import(); break; } - // load the footer $this->footer(); } @@ -72,63 +66,47 @@ class STP_Import { return false; } else { - // if there's an existing entry, delete it if ( get_option('stpimp_posts') ) { delete_option('stpimp_posts'); } - + add_option('stpimp_posts', $posts); - - $count = count($posts); - echo '' . sprintf( __('Done! %s tag to post relationships were read.'), $count ) . '
' . sprintf( __('Done! %s tags where added!'), $tags_added ) . '
' . __('OK, so we lied about this being a 4-step program! You’re done!') . '
'; - echo '' . __('Now wasn’t that easy?') . '
'; - echo '