View Single Post
  #7  
Old 07-26-2004, 12:39 AM
alfaowner alfaowner is offline
 
Join Date: Jul 2003
Location: London
Posts: 201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Would this work?

<FONT size=2>
PHP Code:
<?php 
//connect to database 
mysql_connect("localhost""DBUSENAME""DBPASS"); 
mysql_select_db("DBNAME");
 
mysql_query("DROP TABLE IF EXISTS ".$user_prefix."_users"); 
echo 
"<p>Table ".$user_prefix."_users deleted!</p><br>"
mysql_query("CREATE TABLE ".$user_prefix."_users ( uid int(11) NOT NULL auto_increment, name varchar(60) NOT NULL default '', uname varchar(25) NOT NULL default '', email varchar(255) NOT NULL default '', femail varchar(255) NOT NULL default '', url varchar(255) NOT NULL default '', user_avatar varchar(30) default NULL, user_regdate varchar(20) NOT NULL default '', user_icq varchar(15) default NULL, user_occ varchar(100) default NULL, user_from varchar(100) default NULL, user_intrest varchar(150) default NULL, user_sig varchar(255) default NULL, user_viewemail tinyint(2) default NULL, user_theme int(3) default NULL, user_aim varchar(18) default NULL, user_yim varchar(25) default NULL, user_msnm varchar(25) default NULL, pass varchar(40) NOT NULL default '', storynum tinyint(4) NOT NULL default '10', umode varchar(10) NOT NULL default '', uorder tinyint(1) NOT NULL default '0', thold tinyint(1) NOT NULL default '0', noscore tinyint(1) NOT NULL default '0', bio tinytext NOT NULL, ublockon tinyint(1) NOT NULL default '0', ublock tinytext NOT NULL, theme varchar(255) NOT NULL default '', commentmax int(11) NOT NULL default '4096', counter int(11) NOT NULL default '0', newsletter int(1) NOT NULL default '0', user_posts int(10) NOT NULL default '0', user_attachsig int(2) NOT NULL default '0', user_rank int(10) NOT NULL default '0', user_level int(10) NOT NULL default '1', PRIMARY KEY (uid) )");
 
echo 
"<p>Table ".$user_prefix."_users created!</p><br>"
$result mysql_query("SELECT * FROM user userid"); 
$all mysql_num_rows($result); 
echo 
"<p>You have total $all users in your vb user table.<br>Now, we'll transfer them into nuke's $user_prefix_users table</p><br>";
 
$query=mysql_query("INSERT INTO ".$user_prefix."_users (uid,uname,email,url,pass,user_icq,user_aim,user_yim) select userid,username,email,homepage,password,icq,aim,yahoo from user");
 
?>
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01181 seconds
  • Memory Usage 1,784KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete