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();
?>
 
很明显,针对的w32平台下的。。。不过php和mdb结合。我的观点,怪异。。

Leave a Reply

Your email address will not be published.