Output extra fields in emails to administrator

  • Posts: 66
  • Thank you received: 3
13 years 5 months ago #18869

Hello,

Using business edition 1.5.1 with succes for more than a month now.

But need your help with the following.

Created an extra field for date delivery in table order. After customizing the email file "Order administrator notification" beginning of the email looks like this.



I would like to have the date alone in bold text. Second I would like to have the (full) dayname besides the date. Any ideas/suggestions would be welcome. Thank you.

The file I have used for the email is attached.

File Attachment:

File Name: order_admi...tion.txt
File Size:7 KB

Attachments:
Last edit: 13 years 5 months ago by didero.

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 5 months ago #18871

You can change that line:
echo "<br/>".$fieldsClass->trans($oneExtraField->field_realname).' : '.$fieldsClass->show($oneExtraField,$data->$fieldName);

to:
if($fieldName=='column_name_of_date_field'){
echo "<br/>".$fieldsClass->trans($oneExtraField->field_realname).' : <span style="font-size:2em;">'.$fieldsClass->show($oneExtraField,$data->$fieldName).' '.date('l',strtotime($data->$fieldName)).'</span>';
}else{
echo "<br/>".$fieldsClass->trans($oneExtraField->field_realname).' : '.$fieldsClass->show($oneExtraField,$data->$fieldName);
}

You of course need to change the column_name_of_date_field to your custom field's column name.

Please Log in or Create an account to join the conversation.

Time to create page: 0.054 seconds
Powered by Kunena Forum