Zen Follower
- Join Date:
- Feb 2008
- Location:
- Amersham, Buckinghamshire, United Kingdom
- Posts:
- 141
- Plugin Contributions:
- 1
Adding extra fields to admin copy of order confirmation email, and orders area.
sports guy:
This was in my error log:
I did change to your suggestion above and the same thing. Since the above error says this: 'extrafield1' is unknown in the field list and I see this code: "$account->fields['customers_extrafield'], 'id="extrafield"')" in another area of the module, should I try and change extrafield1 to customers_extrafield?
Maybe something like this:
echo $extra_field->fields['customer_extrafield'];
Also shouldn't this: Select extrafield1, extrafield2, extrafield3 be: Select customer_extrafield, customer_extrafield2, customer_extrafield3? I am seeing customers_extrafield, customers_extrafield2, customers_extrafield3 in the database under customers!
Yes - it looks like those are the fieldnames to use.
The
$extra_field->fields['customer_extrafield'] is then used as in your original post
$email_order = EMAIL_TEXT_HEADER . EMAIL_TEXT_FROM . STORE_NAME . "\n\n" .
$this->customer['firstname'] . ' ' . $this->customer['lastname'] . "\n\n" .
$extra_field->fields['customer_extrafield1']. "\n\n" .
$extra_field->fields['customer_extrafield3']. "\n\n" .
EMAIL_THANKS_FOR_SHOPPING . "\n" .
EMAIL_DETAILS_FOLLOW . "\n" ...etc
where they are being added to $email_order
Regards