如何把excel文件用php导入到mysql的数据表中。
excel中的格式是:
question;answer1;answer2;answer3;answer4
mysql中的question的表为:
create table question(
id INT AUTO_INCREMENT NOT NULL,
question char(200) not null,
answer1 char(50) not null,
answer2 char(50) not null,
answer3 char(50) not null,
answer4 char(50) not null,
PRIMARY KEY (id),
);
数据库的联结为:DB.php.inc
如何用php把excel文件中的数据批量导入mysql中的表中呢?
有具体的代码吗?
谢谢