<?php
//admin
$a = 'adm_id,adm_username,adm_password';
$b = 'adm_id,adm_user,adm_password';
sql_query("insert into ".$db_prefix."admin ($a) select $b from admin");
sql_query("update ".$db_prefix."admin set adm_grade = 1,adm_power = 'all'");

//article
$a = 'art_id,art_cat_id,art_type,art_title,art_text,art_author,art_top,art_index,art_show,art_keywords,art_description,art_url';
$b = $a;
sql_query("insert into ".$db_prefix."article ($a) select $b from article");
sql_query("update ".$db_prefix."article set art_lang = 'zh-cn',art_add_time = ".time());

//cat_art
$a = 'cat_id,cat_parent_id,cat_name,cat_best,cat_top,cat_index,cat_show';
$b = $a;
sql_query("insert into ".$db_prefix."cat_art ($a) select $b from cat_art");
sql_query("update ".$db_prefix."cat_art set cat_lang = 'zh-cn'");

//cat_pro
$a = 'cat_id,cat_parent_id,cat_name,cat_best,cat_top,cat_index,cat_show';
$b = $a;
sql_query("insert into ".$db_prefix."cat_pro ($a) select $b from cat_pro");
sql_query("update ".$db_prefix."cat_pro set cat_lang = 'zh-cn'");

//link
$a = 'lin_id,lin_word,lin_url,lin_img,lin_title,lin_top,lin_index,lin_show';
$b = $a;
sql_query("insert into ".$db_prefix."link ($a) select $b from link");
sql_query("update ".$db_prefix."link set lin_lang = 'zh-cn'");

//menu
$a = 'men_id,men_type,men_name,men_url,men_top,men_index,men_show';
$b = $a;
sql_query("insert into ".$db_prefix."menu ($a) select $b from menu");
sql_query("update ".$db_prefix."menu set men_lang = 'zh-cn'");

//message
$a = 'mes_id,mes_text,mes_reply,mes_show';
$b = $a;
sql_query("insert into ".$db_prefix."message ($a) select $b from message");
sql_query("update ".$db_prefix."message set mes_lang = 'zh-cn',mes_type = '留言',mes_add_time = ".time());

//picture
$a = 'pic_id,pic_type,pic_title,pic_path,pic_url,pic_site,pic_top,pic_index,pic_show';
$b = $a;
sql_query("insert into ".$db_prefix."picture ($a) select $b from picture");
sql_query("update ".$db_prefix."picture set pic_lang = 'zh-cn'");

//product
$a = 'pro_id,pro_cat_id,pro_title,pro_number,pro_img,pro_reduce_img,pro_text,pro_keywords,pro_description,pro_best,pro_top,pro_index,pro_show';
$b = $a;
sql_query("insert into ".$db_prefix."product ($a) select $b from product");
sql_query("update ".$db_prefix."product set pro_lang = 'zh-cn',pro_add_time = ".time());

//research
$a = 'res_id,res_text';
$b = $a;
sql_query("insert into ".$db_prefix."research ($a) select $b from research");
sql_query("update ".$db_prefix."research set res_lang = 'zh-cn',res_add_time = ".time());

//红头船
?>