Customising e-mail receipt to include database content?
I have database content within an e-mail receipt page in webassist/email/templates/Blank_3.php.
When we receive the e-mail the database fields throw the error, taking one as an example...
Notice: Undefined variable: row_rsORDER in /home/led2014/public_html/webassist/email/templates/Blank_3.php on line 30
I tried adding the recordset to the page, along with the link to our connection script, but now when we run the script we get the following errors:
Notice: Undefined variable: database_connLED in /home/led2014/public_html/webassist/email/templates/Blank_3.php on line 54
Notice: Undefined variable: connLED in /home/led2014/public_html/webassist/email/templates/Blank_3.php on line 54
Warning: mysql_select_db() expects parameter 2 to be resource, null given in /home/led2014/public_html/webassist/email/templates/Blank_3.php on line 54
Notice: Undefined variable: connLED in /home/led2014/public_html/webassist/email/templates/Blank_3.php on line 56
Warning: mysql_query() expects parameter 2 to be resource, null given in /home/led2014/public_html/webassist/email/templates/Blank_3.php on line 56
Lines 54 - 56 are...
mysql_select_db($database_connLED, $connLED);
$query_rsORDER = sprintf("SELECT LEDOrderID, LEDOrderUserID, LEDOrderAmount, LEDOrderFirstName, LEDOrderSurname, LEDOrderShipAddress, LEDOrderShipAddress2, LEDOrderCity, LEDOrderRegion, LEDOrderPostcode, LEDOrderCountry, LEDOrderPhone, LEDOrderMobile, LEDOrderShipping, LEDOrderTax, LEDOrderEmail, LEDOrderDate, LEDOrderShipped, LEDOrderShippedDate, LEDOrderTrackingNo, LEDOrderSubTotal, LEDOrderDiscounts, LEDOrderCharges FROM LEDorder WHERE LEDOrderID = %s", GetSQLValueString($colname_rsORDER, "int"));
$rsORDER = mysql_query($query_rsORDER, $connLED) or die(mysql_error());
Would appreciate the advice, thank you.
Thank you
NJ