本文章分享的是PHP链接ACCESS数据库的实现代码,希望对各位朋友有所帮助。下面就是实现PHP链接ACCESS数据库的代码:
<?
$dbc=new com("adodb.connection");
$dbc->open("driver=microsoft access driver (*.mdb);dbq=c:/member.mdb");
$rs=$dbc->execute("select * from tablename");
$i=0;
while (!$rs->eof){
$i+=1
$fld0=$rs->fields["UserName"];
$fld0=$rs->fields["Password"];
....
echo "$fld0->value $fld1->value ....";
$rs->movenext();
}
$rs->close();
?>