Jump to content

[SOLVED] HELP, is this ok?


dh526

Recommended Posts

The values of $cardid etc are from some tables and they are all echoed out correctly and do return a number... (or email address)

 

<form method='POST' action='buy.php'>
<input type='hidden' value=$cardid name='cardid' />
<input type='hidden' value=$addid name='addid'  /> 
<input type='hidden' value=$email name='email'  />  
<input type='hidden' value=$prodid name='prodid'  />
<input type='submit' value='confirm order' >
</form>

 

Then on the next page I want to insert these values into a table. So I have done this :

 

$conn=odbc_connect('db09','','');

$sql="INSERT INTO tblOrders (ProductID, username, AddressID, CardID ) VALUES ($product,'$username', $addid, $cardid)";

 

but it doesn't work. I get a [Microsoft][ODBC Microsoft Access Driver] Syntax error in INSERT INTO statement error.

 

What is wrong ?? can anyone help??

 

thank you in advance :)

Link to comment
https://forums.phpfreaks.com/topic/159738-solved-help-is-this-ok/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.