Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Changing Checkout Email osc2.3.4


Sheik58

Recommended Posts

I need gender of customer in confirmation email.

In catalog/checkout_process.php there is around line 85:

 

'customers_name' => $order->customer['firstname']

for first name.

How to add for gender?

 

If that is not possible, how to query in DB?

 

Regards

 

Link to comment
Share on other sites

I would say that the correct way would be to modify the cart() and query() functions in includes/classes/order.php to fetch this data. Then modify checkout_process.php to persist it. This would require modifying the orders table structure in the database though.

 

The code just to get the gender would be something like

 

$customer_query = tep_db_query("SELECT customers_gender FROM " . TABLE_CUSTOMERS . " WHERE customers_id = '" . (int)$customer_id . "'");
$customer_data = tep_db_fetch_array($customer_query);
$customer_gender = $customer_data['customers_gender'];

Always back up before making changes.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...