Witam mam taką funkcję która odpowiada w moim sklepie za wysyłanie maili
public function sendEmailWithOrderDetails( $iOrder ){
$aData = $this->throwOrder( $iOrder );
$aUrls = throwSiteUrls( );
$sOrderUrlEmail = $aUrls['sHomeUrl'].$GLOBALS['oPage']->aPages[$config['order_print']]['sLinkName'].'&sKey='.$this->throwOrderKey( $aData );
$sMailContent = str_replace( '|n|', "\n", $lang['Order_customer_email_head']."\n------------------------\n".$lang['Order_customer_personal']."\n------------------------\n".$aData['sFirstName'].' '.$aData['sLastName'].( isset( $aData['sCompanyName'] ) ?
"\n".$aData['sCompanyName'] : null )."\n".$aData['sStreet']."\n".$aData['sZipCode'].' '.$aData['sCity']."\n".$aData['sPhone']."\n".$aData['sEmail'].( isset( $aData['sComment'] ) ?
"\n\n".$lang['Comment'].': '.$aData['sComment'] : null )."\n------------------------\n".$lang['Order_customer_products']."\n------------------------".$this->listProducts( $iOrder, true )."\n------------------------\n".( isset( $aData['iShipping'] ) ?
$lang['Order_customer_shipping']."\n------------------------\n".$aData['mShipping'].' ('.$aData['mPayment'].') = '.$this->aOrders[$iOrder]['sPaymentShippingPrice'].' '.$config['currency_symbol']."\n\n" : null ).$lang['Summary_cost'].': '.$this->aOrders[$iOrder]['sOrderSummary'].' '.$config['currency_symbol']."\n------------------------\n".$lang['Check_order_status_url']."\n".$sOrderUrlEmail."\n-------------------\n".$lang['Order_customer_email_foot'] );
// the following phrase must be present in the email's content. See the license - <a href="http://opensolution.org/licenses.html" target="_blank">http://opensolution.org/licenses.html</a>
$sMailContent .= "\n\n".( LANGUAGE == 'pl' ) ? 'Wysłane przez program Quick.Cart' : 'Sent by the Quick.Cart program';
if( $config['send_customer_order_details'] === true ){
@mail( $aData['sEmail'], '=?UTF-8?B?'.base64_encode( $lang['Order_customer_info_title'].$iOrder ).'?=', $sMailContent, 'MIME-Version: 1.0'."\r\n".'Content-type: text/plain; charset=UTF-8'."\r\n".( ( $config['emails_from_header_option'] == 2 ) ?
'Reply-to: '.$config['orders_email'] : 'From: '.$config['orders_email'] ) ); }
@mail( $config['orders_email'], '=?UTF-8?B?'.base64_encode( $lang['Order_customer_info_title'].$iOrder ).'?=', $sMailContent, 'MIME-Version: 1.0'."\r\n".'Content-type: text/plain; charset=UTF-8'."\r\n".( ( $config['order_details_from_customer'] === true && $config['emails_from_header_option'] == 1 ) ?
'From: '.$aData['sEmail'] : ( ( $config['emails_from_header_option'] == 1 ) ?
'From: '.$config['orders_email'] : 'Reply-to: '.$aData['sEmail'] ) ) ); }
Moje pytanie brzmi jak przerobić Mailcontent aby zrobić to ładnie estetycznie w htmlu