Code kopieren Der Code lautet wie folgt: //Verwenden Sie JavaScript, um Codebeispiele für die serverseitige Verbindung zur Datenbank zu schreiben <BR> var conn = new ActiveXObject("ADODB.Connection"); <BR> conn.Open("DBQ=c:\a .mdb;DRIVER={Microsoft Access Driver (*.mdb)};"); <BR> var rs = new ActiveXObject("ADODB.Recordset"); <BR> var sql="select * from friends_infor"; <BR> rs.open(sql, conn); <BR> shtml = "<table width='100%' border=1>" <br> shtml +="<tr bgcolor='#f4f4f4'>< ;td>au_id</td> ;<td>au_lname</td><td>au_fname</td></tr>"; <br> while(!rs.EOF) <br> { ;< td>" + rs("friend_id") + "</td><td>" + rs("friend_name") + "</td><td>" + rs("friend_nickname" ) + " </td></tr>"; <br>rs.moveNext; <br> } <br> shtml += "</table>"; <br> rs.close(); <br> rs = null; <br> conn.close(); <br> conn = null;<br><br><br> </div>