corneillie Posted May 25, 2007 Share Posted May 25, 2007 I do not know where in which forum I had to put this question, please move if not ok PHP is not my thing, the following i found with tutorials on google: <? $conn = new COM("ADODB.Connection") or die("Cannot start ADO"); // Microsoft Access connection string. $conn->Open("DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=E:\\inetpub\\vhosts\\mydomainname\\private\\database\\C-HOST.mdb"); // SQL statement to build recordset. $rs = $conn->Execute("SELECT Transfert FROM 1JaarGratis "); // Display all the values in the records set while (!$rs->EOF) { $fv = $rs->Fields("Transfert"); if($fv == true) { echo ("Promotie is ingeschakeld"); } else { echo ("Promotie is uitgeschakeld"); } $rs->MoveNext(); } $rs->Close(); ?> I want to have when the checkbox transfert is checked it says "promotie is ingeschakeld", when not checked "promotie is uitgeschakeld", but is does not work. Connection to the database is ok. The problem must be in the if statement. thanks for your help! Quote Link to comment https://forums.phpfreaks.com/topic/52986-need-some-help-please/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.