Jump to content

MrRim

Members
  • Content count

    7
  • Joined

  • Last visited

  1. MrRim

    Fancier Invoice & Packingslip v1.0

    Add: <style type="text/css"> <!-- body {background-color: #FFFFFF;} body,td,th {color: #000000;} ? --> </style> After: <link href="stylesheet.css" rel="stylesheet" type="text/css"> Before: </head> Black TEXT, White BACKGROUND.
  2. MrRim

    Fancier Invoice & Packingslip v1.0

    When you use the one included with v5.6 it prints like standard osCommerce when you press the PRINT BUTTON in account history This one's like Fancier Invoice format.
  3. MrRim

    Fancier Invoice & Packingslip v1.0

    Try this replacement code for file catalog/print_my_invoice.php <?php /* $Id: print_my_invoice.php,v 5.5 2005/05/11 23:03:52 PopTheTop Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ require('includes/application_top.php'); if (!tep_session_is_registered('customer_id')) { $navigation->set_snapshot(); tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL')); } if (!isset($HTTP_GET_VARS['order_id']) || (isset($HTTP_GET_VARS['order_id']) && !is_numeric($HTTP_GET_VARS['order_id']))) { tep_redirect(tep_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); } $orders_query = tep_db_query("select orders_id from " . TABLE_ORDERS . " where orders_id = '" . tep_db_input($oID) . "'"); $customer_info_query = tep_db_query("select customers_id from " . TABLE_ORDERS . " where orders_id = '". (int)$HTTP_GET_VARS['order_id'] . "'"); $customer_info = tep_db_fetch_array($customer_info_query); if ($customer_info['customers_id'] != $customer_id) { tep_redirect(tep_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); } require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_ORDERS_PRINTABLE_INFO); $breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_ACCOUNT, '', 'SSL')); $breadcrumb->add(NAVBAR_TITLE_2, tep_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); $breadcrumb->add(sprintf(NAVBAR_TITLE_3, $HTTP_GET_VARS['order_id']), tep_href_link(FILENAME_ORDERS_PRINTABLE_INFO, 'order_id=' . $HTTP_GET_VARS['order_id'], 'SSL')); require(DIR_WS_CLASSES . 'order.php'); $order = new order($HTTP_GET_VARS['order_id']); ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <html <?php echo HTML_PARAMS; ?>> <head> <title><?php echo STORE_NAME; ?> <?php echo INVOICE_TEXT_INVOICE; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?><?php echo date("y"); ?><?php echo INVOICE_TEXT_DASH; ?><?php echo $oID; ?></title> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>"> <script type="text/javascript" src='includes/admin_comments_popup.js'></script> <link href="stylesheet.css" rel="stylesheet" type="text/css"> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" onload="window.print();return false"> <!-- body_text //--> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td align="left"><?php echo '<input type="image" src="' . INVOICE_IMAGE . '" width="' . INVOICE_IMAGE_WIDTH . '" height="' . INVOICE_IMAGE_HEIGHT . '" " alt="' . INVOICE_IMAGE_ALT_TEXT . '" onClick="javascript:ShowHide(\'comments_open\',\'comments_close\');">'; ?></td> <TD ALIGN="right" VALIGN="top"><FONT COLOR="#006699" SIZE="2" FACE="Verdana" class="smallTextBlue"><strong><?php echo INVOICE_TEXT_INVOICE; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?> <?php echo date("y"); ?><?php echo INVOICE_TEXT_DASH; ?><?php echo $order_id; ?><BR> <?php echo $date; ?></strong></font></TD> </tr> <tr> <td colspan="2"> <table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <TD COLSPAN="2" ALIGN="right" class="smallAddressBlue"><FONT FACE="Verdana" SIZE="1" COLOR="#006699"><strong><?php echo nl2br(STORE_NAME_ADDRESS); ?></strong></font></TD> </tr> <tr> <TD> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td colspan="4"> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td width="10%"><hr size="2"></td> <td align="center" class="pageHeading"><em><b><?php echo INVOICE_TEXT_INVOICE; ?></b></em></td> <td width="100%"><hr size="2"></td> </tr> </table></td> </tr> <tr> <td colspan="4"><?php echo tep_draw_separator('pixel_trans.gif', '100', '5'); ?></td> </tr> <tr> <td width="3"> </td> <td valign="top"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="11"><img src="images/borders/maingrey_01.gif" width="11" height="16" alt=""></td> <td background="images/borders/maingrey_02.gif"><img src="images/borders/maingrey_02.gif" width="24" height="16" alt="" ></td> <td width="19"><img src="images/borders/maingrey_03.gif" width="19" height="16" alt=""></td> </tr> <tr> <td background="images/borders/maingrey_04.gif"><img src="images/borders/maingrey_04.gif" width="11" height="21" alt=""></td> <td align="center" bgcolor="#F2F2F2"> <table width="100%" border="0" cellspacing="0" cellpadding="0" class="main"> <tr> <td align="left" valign="top" class="order_infobox_heading"><b><?php echo ENTRY_SOLD_TO; ?></b></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '5'); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_address_format($order->customer['format_id'], $order->customer, 1, '', '<br> '); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo $order->customer['telephone']; ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo $order->customer['email_address']; ?></td> </tr> <tr> <td class="order_infobox_data"><?php echo tep_draw_separator('pixel_trans.gif', '1', '7'); ?></td> </tr> </table></td> <td background="images/borders/maingrey_06.gif"><img src="images/borders/maingrey_06.gif" width="19" height="21" alt=""></td> </tr> <tr> <td><img src="images/borders/maingrey_07.gif" width="11" height="18" alt=""></td> <td background="images/borders/maingrey_08.gif"><img src="images/borders/maingrey_08.gif" width="24" height="18" alt=""></td> <td><img src="images/borders/maingrey_09.gif" width="19" height="18" alt=""></td> </tr> </table></td> <td width="45"> </td> <td valign="top"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="11"><img src="images/borders/mainwhite_01.gif" width="11" height="16" alt=""></td> <td background="images/borders/mainwhite_02.gif"><img src="images/borders/mainwhite_02.gif" width="24" height="16" alt=""></td> <td width="19"><img src="images/borders/mainwhite_03.gif" width="19" height="16" alt=""></td> </tr> <tr> <td background="images/borders/mainwhite_04.gif"><img src="images/borders/mainwhite_04.gif" width="11" height="21" alt=""></td> <td align="center" bgcolor="#FFFFFF"> <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main"> <tr> <td align="left" valign="top" class="order_infobox_heading"><b><?php echo ENTRY_SHIP_TO; ?></b></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '5'); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br> '); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td> </tr> <tr> <td class="order_infobox_data"> </td> </tr> <tr> <td class="order_infobox_data"> </td> </tr> <tr> <td class="order_infobox_data"><?php echo tep_draw_separator('pixel_trans.gif', '1', '7'); ?></td> </tr> </table></td> <td background="images/borders/mainwhite_06.gif"><img src="images/borders/mainwhite_06.gif" width="19" height="21" alt=""></td> </tr> <tr> <td><img src="images/borders/mainwhite_07.gif" width="11" height="18" alt=""></td> <td background="images/borders/mainwhite_08.gif"><img src="images/borders/mainwhite_08.gif" width="24" height="18" alt=""></td> <td><img src="images/borders/mainwhite_09.gif" width="19" height="18" alt=""></td> </tr> </table></td> </tr> </table></TD> </tr> <tr> <TD COLSPAN="2"><?php echo tep_draw_separator('pixel_trans.gif', '100', '15'); ?></td> </tr> <tr> <TD COLSPAN="2"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="9"> </td> <td> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="11"><img src="images/borders/maingrey_01.gif" width="11" height="16" alt=""></td> <td background="images/borders/maingrey_02.gif"><img src="images/borders/maingrey_02.gif" width="24" height="16" alt="" ></td> <td width="19"><img src="images/borders/maingrey_03.gif" width="19" height="16" alt=""></td> </tr> <tr> <td background="images/borders/maingrey_04.gif"><img src="images/borders/maingrey_04.gif" width="11" height="21" alt=""></td> <td align="center" bgcolor="#F2F2F2"> <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main"> <tr> <td width="33%" class="order_infobox_data"><strong> <?php echo INVOICE_TEXT_ORDER; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?><?php echo INVOICE_TEXT_COLON; ?></strong> <?php echo tep_db_input( $order_id); ?></td> <td width="33%" class="order_infobox_data"><strong> <?php echo INVOICE_TEXT_DATE_OF_ORDER; ?><?php echo INVOICE_TEXT_COLON; ?> </strong><?php echo tep_date_short($order->info['date_purchased']); ?></td> <?php if (tep_not_null($order->info['cc_number'])) { $this->cc_card_number_less_middle_digits = substr($order->info['cc_number'], 0, 4) . str_repeat('x', (strlen($order->info['cc_number']) - 8)) . substr($order->info['cc_number'], -4); ?> <td class="order_infobox_data"><span class="order_infobox_heading"> <b><?php echo ENTRY_PAYMENT_METHOD; ?></b></span> <?php echo $order->info['payment_method']; ?> (<?php echo $order->info['cc_type']; ?>)<br> <?php echo tep_draw_separator('pixel_trans.gif', '100%', '6'); ?><br> <span class="order_infobox_heading"> <b><?php echo ENTRY_PAYMENT_CC_NUMBER; ?></b></span> <?php echo $this->cc_card_number_less_middle_digits; ?></td> <?php } else { ?> <td class="order_infobox_data"><span class="order_infobox_heading"> <b><?php echo ENTRY_PAYMENT_METHOD; ?></b></span> <?php echo $order->info['payment_method']; ?></td> <?php } ?> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '1', '7'); ?></td> </tr> </table></td> <td background="images/borders/maingrey_06.gif"><img src="images/borders/maingrey_06.gif" width="19" height="21" alt=""></td> </tr> <tr> <td><img src="images/borders/maingrey_07.gif" width="11" height="18" alt=""></td> <td background="images/borders/maingrey_08.gif"><img src="images/borders/maingrey_08.gif" width="24" height="18" alt=""></td> <td><img src="images/borders/maingrey_09.gif" width="19" height="18" alt=""></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <TD COLSPAN="2"><?php echo tep_draw_separator('pixel_trans.gif', '1', '15'); ?></td> </tr> <tr> <TD COLSPAN="2"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td> </tr> <tr> <TD COLSPAN="2"><table border="0" width="99%" cellspacing="0" cellpadding="2"> <tr class="dataTableHeadingContent"> <td colspan="2" class="dataTableHeadingContent"> <font color="#000000"><?php echo TABLE_HEADING_PRODUCTS; ?></font></td> <td WIDTH="80" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_PRODUCTS_MODEL; ?></font></td> <td WIDTH="80" align="right" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_UNIT_PRICE; ?></font></td> <TD WIDTH="80" ALIGN="right" CLASS="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_TOTAL; ?></font> </TD> </tr> <?php for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) { echo ' <tr class="dataTableRow">' . "\n" . ' <td class="dataTableContent" valign="top" align="right">' . $order->products[$i]['qty'] . ' x</td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['name']; if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) { for ($j = 0; $j < $k; $j++) { echo '<br><nobr><small> <i> - ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value']; if ($order->products[$i]['attributes'][$j]['price'] != '0') echo ' (' . $order->products[$i]['attributes'][$j]['prefix'] . $currencies->format($order->products[$i]['attributes'][$j]['price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ')'; echo '</i></small></nobr>'; } } echo ' </td>' . "\n" . ' <td WIDTH="80" class="dataTableContent" valign="top">' . $order->products[$i]['model'] . '</td>' . "\n"; echo ' <td WIDTH="80" class="dataTableContent" align="right" valign="top">' . $currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']) . '</td>' . "\n" . ' <td WIDTH="80" class="dataTableContent" align="right" valign="top"><b>' . $currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ' </b></td>' . "\n"; echo ' </tr>' . "\n"; } ?> <tr> <td align="right" colspan="5"> <table border="0" cellspacing="0" cellpadding="2"> <?php for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) { echo ' <tr>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['title'] . '</td>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['text'] . '</td>' . "\n" . ' </tr>' . "\n"; } ?> </table></td> </tr> </table></td> </tr> </table> <!-- ORDER COMMENTS CODE STARTS HERE //--> <div id="comments_open" style="position: relative;"> <?php $orders_status_history_query = tep_db_query("select * from " . TABLE_ORDERS_STATUS_HISTORY . " where orders_id = '" . tep_db_input($oID) . "' order by date_added"); if (tep_db_num_rows($orders_status_history_query)) { $has_comments = false; echo ' <br><br>'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="9"> </td>'; echo ' <td>'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="11"><img src="images/borders/maingrey_01.gif" width="11" height="16" alt=""></td>'; echo ' <td background="images/borders/maingrey_02.gif"><img src="images/borders/maingrey_02.gif" width="24" height="16" alt="" ></td>'; echo ' <td width="19"><img src="images/borders/maingrey_03.gif" width="19" height="16" alt=""></td>'; echo ' </tr>'; echo ' <tr>'; echo ' <td background="images/borders/maingrey_04.gif"><img src="images/borders/maingrey_04.gif" width="11" height="21" alt=""></td>'; echo ' <td align="center" bgcolor="#F2F2F2">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="95%"> <b>' . TABLE_HEADING_COMMENTS . '</b><br><br></td>'; echo ' </tr>'; while ($orders_comments = tep_db_fetch_array($orders_status_history_query)) { if (tep_not_null($orders_comments['comments'])) { $has_comments = true; // Not Null = Has Comments if (tep_not_null($orders_comments['comments'])) { $sInfo = new objectInfo($orders_comments); echo ' <tr>'; echo ' <td align="center" width="95%">'; echo ' <table width="95%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="95%" class="smallText">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="150" align="left" valign="top" class="smallText"><strong><u>' . TABLE_HEADING_DATE_ADDED . '</u></strong></td>'; echo ' <td align="left" valign="top" class="smallText"><strong><u>' . TABLE_HEADING_COMMENT_LEFT . '</u></strong></td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' <tr>'; echo ' <td align="center" width="95%">'; echo ' <table width="95%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="95%" class="smallText">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="150" align="left" valign="top" class="smallText">' . tep_date_short($sInfo->date_added) . '</td>'; echo ' <td align="left" valign="top" class="smallText">' . nl2br(tep_db_output($orders_comments['comments'])) . '<br><br></td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; } } } if ($has_comments == false) { echo ' <tr>'; echo ' <td align="center" width="95%">'; echo ' <table width="95%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="95%" class="smallText">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="100%" align="left" valign="top" class="smallText">' . INVOICE_TEXT_NO_COMMENT . '</td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; } echo ' <tr>'; echo ' <td>' . tep_draw_separator('pixel_trans.gif', '1', '7') . '</td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' <td background="images/borders/maingrey_06.gif"><img src="images/borders/maingrey_06.gif" width="19" height="21" alt=""></td>'; echo ' </tr>'; echo ' <tr>'; echo ' <td><img src="images/borders/maingrey_07.gif" width="11" height="18" alt=""></td>'; echo ' <td background="images/borders/maingrey_08.gif"><img src="images/borders/maingrey_08.gif" width="24" height="18" alt=""></td>'; echo ' <td><img src="images/borders/maingrey_09.gif" width="19" height="18" alt=""></td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; } ?> <!-- ORDER COMMENTS CODE ENDS HERE //--> </div> <p class="smallTextBlue"> </p> <p class="smallTextBlue"><br> </p> <CENTER class="order_infobox_data"> <p><span class="smallTextBlue"><FONT FACE="Verdana" COLOR="#006699"><strong><?php echo INVOICE_TEXT_THANK_YOU; ?><BR> <?php echo STORE_NAME; ?><BR> <?php echo STORE_URL_ADDRESS; ?></strong></font></span><span class="smallText"> <!-- body_text_eof //--> <br> </span></p> </CENTER> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td><div align="center"> <hr size="2"> <span class="dataTableContent">Copyright © <?php echo date("Y"); ?>, All Rights Reserved</span><span class="dataTableSmallText"><br> </span> <hr size="2"> <p class="style4"> </p> </div></td> </tr> </table> <p> </p> </table> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> Add your new V5.6 css code to the bottom of catalog/stylesheet.css /* BEGIN Fancier Invoice and Packingslip */ .dataTableHeadingRow { background-color: #C9C9C9; } .dataTableHeadingContent {font-family: Verdana, Arial, sans-serif;font-size: 10px;font-weight: bold;background-color: #C9C9C9;} .dataTableRow { background-color: #F0F1F1; } .dataTableContent { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #000000; } .smallText { font-family: Verdana, Arial, sans-serif; font-size: 10px; } .smallTextBlue { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #006699; } .smallAddressBlue { font-family: Arial; font-size: 9px; color: #006699; } .main { font-family: Verdana, Arial, sans-serif; font-size: 12px; } /* END Fancier Invoice and Packingslip */ Could have some lines of code not used at top made from the file invoice.php and print_my_invoice.php
  4. Try this replacement code for file catalog/print_my_invoice.php <?php /* $Id: print_my_invoice.php,v 5.5 2005/05/11 23:03:52 PopTheTop Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ require('includes/application_top.php'); if (!tep_session_is_registered('customer_id')) { $navigation->set_snapshot(); tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL')); } if (!isset($HTTP_GET_VARS['order_id']) || (isset($HTTP_GET_VARS['order_id']) && !is_numeric($HTTP_GET_VARS['order_id']))) { tep_redirect(tep_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); } $orders_query = tep_db_query("select orders_id from " . TABLE_ORDERS . " where orders_id = '" . tep_db_input($oID) . "'"); $customer_info_query = tep_db_query("select customers_id from " . TABLE_ORDERS . " where orders_id = '". (int)$HTTP_GET_VARS['order_id'] . "'"); $customer_info = tep_db_fetch_array($customer_info_query); if ($customer_info['customers_id'] != $customer_id) { tep_redirect(tep_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); } require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_ORDERS_PRINTABLE_INFO); $breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_ACCOUNT, '', 'SSL')); $breadcrumb->add(NAVBAR_TITLE_2, tep_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); $breadcrumb->add(sprintf(NAVBAR_TITLE_3, $HTTP_GET_VARS['order_id']), tep_href_link(FILENAME_ORDERS_PRINTABLE_INFO, 'order_id=' . $HTTP_GET_VARS['order_id'], 'SSL')); require(DIR_WS_CLASSES . 'order.php'); $order = new order($HTTP_GET_VARS['order_id']); ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <html <?php echo HTML_PARAMS; ?>> <head> <title><?php echo STORE_NAME; ?> <?php echo INVOICE_TEXT_INVOICE; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?><?php echo date("y"); ?><?php echo INVOICE_TEXT_DASH; ?><?php echo $oID; ?></title> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>"> <script type="text/javascript" src='includes/admin_comments_popup.js'></script> <link href="stylesheet.css" rel="stylesheet" type="text/css"> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" onload="window.print();return false"> <!-- body_text //--> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td align="left"><?php echo '<input type="image" src="' . INVOICE_IMAGE . '" width="' . INVOICE_IMAGE_WIDTH . '" height="' . INVOICE_IMAGE_HEIGHT . '" " alt="' . INVOICE_IMAGE_ALT_TEXT . '" onClick="javascript:ShowHide(\'comments_open\',\'comments_close\');">'; ?></td> <TD ALIGN="right" VALIGN="top"><FONT COLOR="#006699" SIZE="2" FACE="Verdana" class="smallTextBlue"><strong><?php echo INVOICE_TEXT_INVOICE; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?> <?php echo date("y"); ?><?php echo INVOICE_TEXT_DASH; ?><?php echo $order_id; ?><BR> <?php echo $date; ?></strong></font></TD> </tr> <tr> <td colspan="2"> <table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <TD COLSPAN="2" ALIGN="right" class="smallAddressBlue"><FONT FACE="Verdana" SIZE="1" COLOR="#006699"><strong><?php echo nl2br(STORE_NAME_ADDRESS); ?></strong></font></TD> </tr> <tr> <TD> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td colspan="4"> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td width="10%"><hr size="2"></td> <td align="center" class="pageHeading"><em><b><?php echo INVOICE_TEXT_INVOICE; ?></b></em></td> <td width="100%"><hr size="2"></td> </tr> </table></td> </tr> <tr> <td colspan="4"><?php echo tep_draw_separator('pixel_trans.gif', '100', '5'); ?></td> </tr> <tr> <td width="3"> </td> <td valign="top"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="11"><img src="images/borders/maingrey_01.gif" width="11" height="16" alt=""></td> <td background="images/borders/maingrey_02.gif"><img src="images/borders/maingrey_02.gif" width="24" height="16" alt="" ></td> <td width="19"><img src="images/borders/maingrey_03.gif" width="19" height="16" alt=""></td> </tr> <tr> <td background="images/borders/maingrey_04.gif"><img src="images/borders/maingrey_04.gif" width="11" height="21" alt=""></td> <td align="center" bgcolor="#F2F2F2"> <table width="100%" border="0" cellspacing="0" cellpadding="0" class="main"> <tr> <td align="left" valign="top" class="order_infobox_heading"><b><?php echo ENTRY_SOLD_TO; ?></b></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '5'); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_address_format($order->customer['format_id'], $order->customer, 1, '', '<br> '); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo $order->customer['telephone']; ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo $order->customer['email_address']; ?></td> </tr> <tr> <td class="order_infobox_data"><?php echo tep_draw_separator('pixel_trans.gif', '1', '7'); ?></td> </tr> </table></td> <td background="images/borders/maingrey_06.gif"><img src="images/borders/maingrey_06.gif" width="19" height="21" alt=""></td> </tr> <tr> <td><img src="images/borders/maingrey_07.gif" width="11" height="18" alt=""></td> <td background="images/borders/maingrey_08.gif"><img src="images/borders/maingrey_08.gif" width="24" height="18" alt=""></td> <td><img src="images/borders/maingrey_09.gif" width="19" height="18" alt=""></td> </tr> </table></td> <td width="45"> </td> <td valign="top"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="11"><img src="images/borders/mainwhite_01.gif" width="11" height="16" alt=""></td> <td background="images/borders/mainwhite_02.gif"><img src="images/borders/mainwhite_02.gif" width="24" height="16" alt=""></td> <td width="19"><img src="images/borders/mainwhite_03.gif" width="19" height="16" alt=""></td> </tr> <tr> <td background="images/borders/mainwhite_04.gif"><img src="images/borders/mainwhite_04.gif" width="11" height="21" alt=""></td> <td align="center" bgcolor="#FFFFFF"> <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main"> <tr> <td align="left" valign="top" class="order_infobox_heading"><b><?php echo ENTRY_SHIP_TO; ?></b></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '5'); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br> '); ?></td> </tr> <tr> <td class="order_infobox_data"> <?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td> </tr> <tr> <td class="order_infobox_data"> </td> </tr> <tr> <td class="order_infobox_data"> </td> </tr> <tr> <td class="order_infobox_data"><?php echo tep_draw_separator('pixel_trans.gif', '1', '7'); ?></td> </tr> </table></td> <td background="images/borders/mainwhite_06.gif"><img src="images/borders/mainwhite_06.gif" width="19" height="21" alt=""></td> </tr> <tr> <td><img src="images/borders/mainwhite_07.gif" width="11" height="18" alt=""></td> <td background="images/borders/mainwhite_08.gif"><img src="images/borders/mainwhite_08.gif" width="24" height="18" alt=""></td> <td><img src="images/borders/mainwhite_09.gif" width="19" height="18" alt=""></td> </tr> </table></td> </tr> </table></TD> </tr> <tr> <TD COLSPAN="2"><?php echo tep_draw_separator('pixel_trans.gif', '100', '15'); ?></td> </tr> <tr> <TD COLSPAN="2"> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="9"> </td> <td> <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="11"><img src="images/borders/maingrey_01.gif" width="11" height="16" alt=""></td> <td background="images/borders/maingrey_02.gif"><img src="images/borders/maingrey_02.gif" width="24" height="16" alt="" ></td> <td width="19"><img src="images/borders/maingrey_03.gif" width="19" height="16" alt=""></td> </tr> <tr> <td background="images/borders/maingrey_04.gif"><img src="images/borders/maingrey_04.gif" width="11" height="21" alt=""></td> <td align="center" bgcolor="#F2F2F2"> <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main"> <tr> <td width="33%" class="order_infobox_data"><strong> <?php echo INVOICE_TEXT_ORDER; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?><?php echo INVOICE_TEXT_COLON; ?></strong> <?php echo tep_db_input( $order_id); ?></td> <td width="33%" class="order_infobox_data"><strong> <?php echo INVOICE_TEXT_DATE_OF_ORDER; ?><?php echo INVOICE_TEXT_COLON; ?> </strong><?php echo tep_date_short($order->info['date_purchased']); ?></td> <?php if (tep_not_null($order->info['cc_number'])) { $this->cc_card_number_less_middle_digits = substr($order->info['cc_number'], 0, 4) . str_repeat('x', (strlen($order->info['cc_number']) - 8)) . substr($order->info['cc_number'], -4); ?> <td class="order_infobox_data"><span class="order_infobox_heading"> <b><?php echo ENTRY_PAYMENT_METHOD; ?></b></span> <?php echo $order->info['payment_method']; ?> (<?php echo $order->info['cc_type']; ?>)<br> <?php echo tep_draw_separator('pixel_trans.gif', '100%', '6'); ?><br> <span class="order_infobox_heading"> <b><?php echo ENTRY_PAYMENT_CC_NUMBER; ?></b></span> <?php echo $this->cc_card_number_less_middle_digits; ?></td> <?php } else { ?> <td class="order_infobox_data"><span class="order_infobox_heading"> <b><?php echo ENTRY_PAYMENT_METHOD; ?></b></span> <?php echo $order->info['payment_method']; ?></td> <?php } ?> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '1', '7'); ?></td> </tr> </table></td> <td background="images/borders/maingrey_06.gif"><img src="images/borders/maingrey_06.gif" width="19" height="21" alt=""></td> </tr> <tr> <td><img src="images/borders/maingrey_07.gif" width="11" height="18" alt=""></td> <td background="images/borders/maingrey_08.gif"><img src="images/borders/maingrey_08.gif" width="24" height="18" alt=""></td> <td><img src="images/borders/maingrey_09.gif" width="19" height="18" alt=""></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <TD COLSPAN="2"><?php echo tep_draw_separator('pixel_trans.gif', '1', '15'); ?></td> </tr> <tr> <TD COLSPAN="2"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td> </tr> <tr> <TD COLSPAN="2"><table border="0" width="99%" cellspacing="0" cellpadding="2"> <tr class="dataTableHeadingContent"> <td colspan="2" class="dataTableHeadingContent"> <font color="#000000"><?php echo TABLE_HEADING_PRODUCTS; ?></font></td> <td WIDTH="80" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_PRODUCTS_MODEL; ?></font></td> <td WIDTH="80" align="right" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_UNIT_PRICE; ?></font></td> <TD WIDTH="80" ALIGN="right" CLASS="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_TOTAL; ?></font> </TD> </tr> <?php for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) { echo ' <tr class="dataTableRow">' . "\n" . ' <td class="dataTableContent" valign="top" align="right">' . $order->products[$i]['qty'] . ' x</td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['name']; if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) { for ($j = 0; $j < $k; $j++) { echo '<br><nobr><small> <i> - ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value']; if ($order->products[$i]['attributes'][$j]['price'] != '0') echo ' (' . $order->products[$i]['attributes'][$j]['prefix'] . $currencies->format($order->products[$i]['attributes'][$j]['price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ')'; echo '</i></small></nobr>'; } } echo ' </td>' . "\n" . ' <td WIDTH="80" class="dataTableContent" valign="top">' . $order->products[$i]['model'] . '</td>' . "\n"; echo ' <td WIDTH="80" class="dataTableContent" align="right" valign="top">' . $currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']) . '</td>' . "\n" . ' <td WIDTH="80" class="dataTableContent" align="right" valign="top"><b>' . $currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ' </b></td>' . "\n"; echo ' </tr>' . "\n"; } ?> <tr> <td align="right" colspan="5"> <table border="0" cellspacing="0" cellpadding="2"> <?php for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) { echo ' <tr>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['title'] . '</td>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['text'] . '</td>' . "\n" . ' </tr>' . "\n"; } ?> </table></td> </tr> </table></td> </tr> </table> <!-- ORDER COMMENTS CODE STARTS HERE //--> <div id="comments_open" style="position: relative;"> <?php $orders_status_history_query = tep_db_query("select * from " . TABLE_ORDERS_STATUS_HISTORY . " where orders_id = '" . tep_db_input($oID) . "' order by date_added"); if (tep_db_num_rows($orders_status_history_query)) { $has_comments = false; echo ' <br><br>'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="9"> </td>'; echo ' <td>'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="11"><img src="images/borders/maingrey_01.gif" width="11" height="16" alt=""></td>'; echo ' <td background="images/borders/maingrey_02.gif"><img src="images/borders/maingrey_02.gif" width="24" height="16" alt="" ></td>'; echo ' <td width="19"><img src="images/borders/maingrey_03.gif" width="19" height="16" alt=""></td>'; echo ' </tr>'; echo ' <tr>'; echo ' <td background="images/borders/maingrey_04.gif"><img src="images/borders/maingrey_04.gif" width="11" height="21" alt=""></td>'; echo ' <td align="center" bgcolor="#F2F2F2">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="95%"> <b>' . TABLE_HEADING_COMMENTS . '</b><br><br></td>'; echo ' </tr>'; while ($orders_comments = tep_db_fetch_array($orders_status_history_query)) { if (tep_not_null($orders_comments['comments'])) { $has_comments = true; // Not Null = Has Comments if (tep_not_null($orders_comments['comments'])) { $sInfo = new objectInfo($orders_comments); echo ' <tr>'; echo ' <td align="center" width="95%">'; echo ' <table width="95%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="95%" class="smallText">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="150" align="left" valign="top" class="smallText"><strong><u>' . TABLE_HEADING_DATE_ADDED . '</u></strong></td>'; echo ' <td align="left" valign="top" class="smallText"><strong><u>' . TABLE_HEADING_COMMENT_LEFT . '</u></strong></td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' <tr>'; echo ' <td align="center" width="95%">'; echo ' <table width="95%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="95%" class="smallText">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="150" align="left" valign="top" class="smallText">' . tep_date_short($sInfo->date_added) . '</td>'; echo ' <td align="left" valign="top" class="smallText">' . nl2br(tep_db_output($orders_comments['comments'])) . '<br><br></td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; } } } if ($has_comments == false) { echo ' <tr>'; echo ' <td align="center" width="95%">'; echo ' <table width="95%" border="0" cellpadding="0" cellspacing="0">'; echo ' <tr>'; echo ' <td width="95%" class="smallText">'; echo ' <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main">'; echo ' <tr>'; echo ' <td width="100%" align="left" valign="top" class="smallText">' . INVOICE_TEXT_NO_COMMENT . '</td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; } echo ' <tr>'; echo ' <td>' . tep_draw_separator('pixel_trans.gif', '1', '7') . '</td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' <td background="images/borders/maingrey_06.gif"><img src="images/borders/maingrey_06.gif" width="19" height="21" alt=""></td>'; echo ' </tr>'; echo ' <tr>'; echo ' <td><img src="images/borders/maingrey_07.gif" width="11" height="18" alt=""></td>'; echo ' <td background="images/borders/maingrey_08.gif"><img src="images/borders/maingrey_08.gif" width="24" height="18" alt=""></td>'; echo ' <td><img src="images/borders/maingrey_09.gif" width="19" height="18" alt=""></td>'; echo ' </tr>'; echo ' </table>'; echo ' </td>'; echo ' </tr>'; echo ' </table>'; } ?> <!-- ORDER COMMENTS CODE ENDS HERE //--> </div> <p class="smallTextBlue"> </p> <p class="smallTextBlue"><br> </p> <CENTER class="order_infobox_data"> <p><span class="smallTextBlue"><FONT FACE="Verdana" COLOR="#006699"><strong><?php echo INVOICE_TEXT_THANK_YOU; ?><BR> <?php echo STORE_NAME; ?><BR> <?php echo STORE_URL_ADDRESS; ?></strong></font></span><span class="smallText"> <!-- body_text_eof //--> <br> </span></p> </CENTER> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td><div align="center"> <hr size="2"> <span class="dataTableContent">Copyright © <?php echo date("Y"); ?>, All Rights Reserved</span><span class="dataTableSmallText"><br> </span> <hr size="2"> <p class="style4"> </p> </div></td> </tr> </table> <p> </p> </table> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> Open: catalog/stylesheet.css Add this to the bottom of your file: /* BEGIN Fancier Invoice and Packingslip */ .dataTableHeadingRow { background-color: #C9C9C9; } .dataTableHeadingContent {font-family: Verdana, Arial, sans-serif;font-size: 10px;font-weight: bold;background-color: #C9C9C9;} .dataTableRow { background-color: #F0F1F1; } .dataTableContent { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #000000; } .smallText { font-family: Verdana, Arial, sans-serif; font-size: 10px; } .smallTextBlue { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #006699; } .smallAddressBlue { font-family: Arial; font-size: 9px; color: #006699; } .main { font-family: Verdana, Arial, sans-serif; font-size: 12px; } /* END Fancier Invoice and Packingslip */ Could have some lines of code not used at top made from the file invoice.php and print_my_invoice.php
  5. MrRim

    Fancier Invoice & Packingslip v1.0

    Try installing the New E-mailed HTML Invoice Template... Copy the below text into a text file and save it as box_invoice.php then upload it to your catalog/includes/modules/email_invoice/templates folder Then under Admin / Config / E-mail Options, change the template file name to box_invopice.php <?php /* ?$Id: box_invoice.php,v 5.5 2005/05/15 00:37:30 PopTheTop Exp $ ?osCommerce, Open Source E-Commerce Solutions ?http://www.oscommerce.com ?Copyright (c) 2003 osCommerce ?Released under the GNU General Public License */ ?class objectInfo { // class constructor ? ?function objectInfo($object_array) { ? ? ?reset($object_array); ? ? ?while (list($key, $value) = each($object_array)) { ? ? ? ?$this->$key = tep_db_prepare_input($value); ? ? ?} ? ?} ?} ?> <html> <head> <title></title> <style type="text/css"> .dataTableHeadingRow { background-color: #C9C9C9; } .dataTableHeadingContent { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #ffffff; font-weight: bold; } .dataTableRow { background-color: #F0F1F1; } .dataTableRowSelected { background-color: #DEE4E8; } .dataTableRowOver { background-color: #FFFFFF; cursor: pointer; cursor: hand; } .dataTableContent { font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #000000;} .dataTableSmallText {font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 10px;} </style> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body> <table width="600"> <tr> ?<td height="6" colspan="2"> </td> </tr> <tr> ?<td width="4"> </td> ?<td> <!-- START Top Header --> <table width=100% bgcolor="#FFFFFF" cellpadding="5" style="border-collapse: collapse" bordercolor="#EEEEEE" cellspacing="0" border="3"> <tr> ?<td width="100%"> ? <table width="100%"> ? ?<tr> ? ? <td align="left"><?php echo '<img src="' . INVOICE_IMAGE . '" border="0" alt="' . INVOICE_IMAGE_ALT_TEXT . '" width="' . INVOICE_IMAGE_WIDTH . '" height="' . INVOICE_IMAGE_HEIGHT . '" hspace="10">'; ?></td> ? ? <TD ALIGN="right" VALIGN="top" NOWRAP><FONT FACE="Arial" SIZE="2" COLOR="#006699"><strong><?php echo INVOICE_TEXT_INVOICE; ?> <?php echo INVOICE_TEXT_NUMBER_SIGN; ?> </strong></font><FONT FACE="Verdana" SIZE="2" COLOR="#006699"><strong><?php echo date("y"); ?></strong></font><FONT FACE="Arial" SIZE="2" COLOR="#006699"><strong><?php echo INVOICE_TEXT_DASH; ?><?php echo $oID; ?><BR> ? ? ? ? ? ? ?<?php echo $date; ?></strong></font><br> ? ? ? ? ? ?<br><span class="pageHeadingSM"><FONT FACE="Arial" SIZE="1" COLOR="#006699"><strong><?php echo nl2br(STORE_NAME_ADDRESS); ?></strong></font></span></TD> ? ?</tr> ? </table> ?</td> </tr> </table> <!-- END Top Header --> <!-- START INVOICE --> <table width=100% bgcolor="#C9C9C9" cellpadding="2"> ?<tr class="dataTableHeadingRow"> ? ?<td> <font face="Arial Black" size="3" color="#FFFFFF"><i>Invoice</i></font></td> ?</tr> </table> <!-- END INVOICE --> <table width="100%" border="3" cellpadding="5" bordercolor="#EEEEEE" bgcolor="#FFFFFF" style="border-collapse: collapse"> ?<tr> ? ?<td width="50%" valign="top"> <!-- START Billing Info --> ? ? ? ? <table width="100%" border="0" cellspacing="0" cellpadding="0" class="main"> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td align="left" valign="top"><FONT FACE="Arial" SIZE="2" COLOR="#006699"><b><?php echo ENTRY_SOLD_TO; ?></b></font></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '8', '8'); ?></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td NOWRAP> <FONT FACE="Arial" SIZE="2" COLOR="#006699"><?php echo tep_address_format($order->customer['format_id'], $order->customer, 1, '', '<br> '); ?></font></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '8', '8'); ?></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td NOWRAP> <FONT FACE="Arial" SIZE="2" COLOR="#006699"><?php echo $order->customer['telephone']; ?></font></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td NOWRAP> <FONT FACE="Arial" SIZE="2" COLOR="#006699"><?php echo $order->customer['email_address']; ?></font></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '8', '8'); ?></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ?</table> <!-- END Billing Info --> ? ?</td> ? ?<td width="50%" valign="top"> <!-- START Shipping Info --> ? ? ? ? <table width="100%" border="0" cellpadding="0" cellspacing="0" class="main"> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td align="left" valign="top"><FONT FACE="Arial" SIZE="2" COLOR="#006699"><b><?php echo ENTRY_SHIP_TO; ?></b></font></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '8', '8'); ?></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td NOWRAP> <FONT FACE="Arial" SIZE="2" COLOR="#006699"><?php echo tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br> '); ?></font></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '8', '8'); ?></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td> </td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td> </td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '8', '8'); ?></td> ? ? ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? </table> <!-- END Shipping Info --> ?</td> </tr> </table> <!-- START Product Info --> <table border="0" width="100%" cellspacing="0" cellpadding="2"> ? ? ? ? ? ? ? ? ?<tr bgcolor="#CCCCCC"> ? ? ? ? ? ? ? ? ? ?<td colspan="2" class="dataTableHeadingContent"> <font color="#000000"><?php echo TABLE_HEADING_PRODUCTS; ?></font></td> ? ? ? ? ? ? ? ? ? ?<td WIDTH="80" bgcolor="#CCCCCC" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_PRODUCTS_MODEL; ?></font></span></td> ? ? ? ? ? ? ? ? ? ?<td WIDTH="80" align="right" bgcolor="#CCCCCC" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_UNIT_PRICE; ?></font></td> ? ? ? ? ? ? ? ? ? ?<TD WIDTH="80" ALIGN="right" bgcolor="#CCCCCC" CLASS="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_TOTAL; ?></font> </TD> ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ? ? ? ? ?<?php ? ?for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) { ?echo ' ? ? ?<tr class="dataTableRow">' . "\n" . ? ? ? ' ? ? ? ?<td class="dataTableContent" valign="top" align="right">' . $order->products[$i]['qty'] . ' x</td>' . "\n" . ? ? ? ' ? ? ? ?<td class="dataTableContent" valign="top">' . $order->products[$i]['name']; ? ? ?if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) { ? ? ? ?for ($j = 0; $j < $k; $j++) { ? ? ? ? ?echo '<br><nobr><small> <i> - ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value']; ? ? ? ? ?if ($order->products[$i]['attributes'][$j]['price'] != '0') echo ' (' . $order->products[$i]['attributes'][$j]['prefix'] . $currencies->format($order->products[$i]['attributes'][$j]['price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ')'; ? ? ? ? ?echo '</i></small></nobr>'; ? ? ? ?} ? ? ?} ? ? ?echo ' ? ? ? ? ?</td>' . "\n" . ? ? ? ? ? ' ? ? ? ? ?<td WIDTH="80" class="dataTableContent" valign="top">' . $order->products[$i]['model'] . '</td>' . "\n"; ? ? ?echo ' ? ? ? ? ?<td WIDTH="80" class="dataTableContent" align="right" valign="top">' . $currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']) . '</td>' . "\n" . ? ? ? ? ? ' ? ? ? ? ?<td WIDTH="80" class="dataTableContent" align="right" valign="top"><b>' . $currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ' </b></td>' . "\n"; ? ? ?echo ' ? ? ? ? </tr>' . "\n"; ? ?} ?> ? ? ? ? ? ? ? ? ?<tr> ? ? ? ? ? ? ? ? ? ?<td align="right" colspan="5"> ? ? ? ? ? ? ? ? ? ? ?<table border="0" cellspacing="0" cellpadding="2"> ? ? ? ? ? ? ? ? ? ? ? ?<?php ?for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) { ? ?echo ' ? ? ? ? <tr>' . "\n" . ? ? ? ? ' ? ? ? ? ?<td align="right" class="dataTableSmallText">' . $order->totals[$i]['title'] . '</td>' . "\n" . ? ? ? ? ' ? ? ? ? ?<td align="right" class="dataTableSmallText">' . $order->totals[$i]['text'] . '</td>' . "\n" . ? ? ? ? ' ? ? ? ? </tr>' . "\n"; ?} ?> ? ? ? ? ? ? ? ? ? ?</table></td> ? ? ? ? ? ? ? ? ?</tr> ? ? ? ? ?</table> <!-- END Product Info --> <!-- START Customer Thank You and Order Link --> <table width="100%" border="3" cellpadding="5" bordercolor="#EEEEEE" bgcolor="#FFFFFF" style="border-collapse: collapse"> <tr> ?<td colspan="2" align="center"><br><font size=2 face="Arial" color="#006699">Thank you for purchasing from <?php echo STORE_NAME; ?><br><?php echo STORE_URL_ADDRESS; ?><br>Please print this invoice for your records</font><br><br></td> </tr> <!-- END Customer Thank You and Order Link --> </table> <!-- START Footer --> <table width=100% bgcolor="#C9C9C9" cellpadding="2"> ?<tr> ? ?<td> ? ? ?<div align="center" class="dataTableSmallText"> ? ? ? ?<p>Copyright ? 20<?php echo date("y"); ?> <?php echo STORE_NAME; ?>, ? ? All Rights Reserved<br> ? Company No. 1234456 ? - Registered in England <br> ? ? ? ? ? ?Registered Office: Your Address Here </p> ? ? ? ?</div></td> ?</tr> </table> <!-- END Footer --> ?</td> </tr> </table> </body> </html> This is my hacked version had problems with picking up the css file so included it in code.
  6. MrRim

    Fancier Invoice & Packingslip v1.0

    Yes that's not the file sending the e-mail out catalog/admin/invoice.php is the file used when you PRINT a invoice from within the admin program "Customers" "Orders" and using the "Invoice button"
  7. MrRim

    Fancier Invoice & Packingslip v1.0

    catalog/admin/invoice.php ===== Find: ===== <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr class="dataTableHeadingRow"> <td class="dataTableHeadingContent" colspan="2"><?php echo TABLE_HEADING_PRODUCTS; ?></td> <td class="dataTableHeadingContent"><?php echo TABLE_HEADING_PRODUCTS_MODEL; ?></td> <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_TAX; ?></td> <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_PRICE_EXCLUDING_TAX; ?></td> <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_PRICE_INCLUDING_TAX; ?></td> <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_TOTAL_EXCLUDING_TAX; ?></td> <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_TOTAL_INCLUDING_TAX; ?></td> </tr> <?php for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) { echo ' <tr class="dataTableRow">' . "\n" . ' <td class="dataTableContent" valign="top" align="right">' . $order->products[$i]['qty'] . ' x</td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['name']; if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) { for ($j = 0; $j < $k; $j++) { echo '<br><nobr><small> <i> - ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value']; if ($order->products[$i]['attributes'][$j]['price'] != '0') echo ' (' . $order->products[$i]['attributes'][$j]['prefix'] . $currencies->format($order->products[$i]['attributes'][$j]['price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ')'; echo '</i></small></nobr>'; } } echo ' </td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['model'] . '</td>' . "\n"; echo ' <td class="dataTableContent" align="right" valign="top">' . tep_display_tax_value($order->products[$i]['tax']) . '%</td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"><b>' . $currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']) . '</b></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"><b>' . $currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']), true, $order->info['currency'], $order->info['currency_value']) . '</b></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"><b>' . $currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . '</b></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"><b>' . $currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']) * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . '</b></td>' . "\n"; echo ' </tr>' . "\n"; } ?> <tr> <td align="right" colspan="8"> <table border="0" cellspacing="0" cellpadding="2"> <?php for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) { echo ' <tr>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['title'] . '</td>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['text'] . '</td>' . "\n" . ' </tr>' . "\n"; } ?> </table> </td> </tr> </table> ========= Replace with: ========= <table border="0" width="99%" cellspacing="0" cellpadding="2"> <tr bgcolor="#CCCCCC"> <td colspan="2" class="dataTableHeadingContent"> <font color="#000000"><?php echo TABLE_HEADING_PRODUCTS; ?></font></td> <td WIDTH="80" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_PRODUCTS_MODEL; ?></font></span></td> <td WIDTH="80" align="right" class="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_UNIT_PRICE; ?></font></td> <TD WIDTH="80" ALIGN="right" CLASS="dataTableHeadingContent"><font color="#000000"><?php echo TABLE_HEADING_TOTAL; ?></font> </TD> </tr> <?php for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) { echo ' <tr class="dataTableRow">' . "\n" . ' <td class="dataTableContent" valign="top" align="right">' . $order->products[$i]['qty'] . ' x</td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['name']; if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) { for ($j = 0; $j < $k; $j++) { echo '<br><nobr><small> <i> - ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value']; if ($order->products[$i]['attributes'][$j]['price'] != '0') echo ' (' . $order->products[$i]['attributes'][$j]['prefix'] . $currencies->format($order->products[$i]['attributes'][$j]['price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ')'; echo '</i></small></nobr>'; } } echo ' </td>' . "\n" . ' <td WIDTH="80" class="dataTableContent" valign="top">' . $order->products[$i]['model'] . '</td>' . "\n"; echo ' <td WIDTH="80" class="dataTableContent" align="right" valign="top">' . $currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']) . '</td>' . "\n" . ' <td WIDTH="80" class="dataTableContent" align="right" valign="top"><b>' . $currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ' </b></td>' . "\n"; echo ' </tr>' . "\n"; } ?> <tr> <td align="right" colspan="5"> <table border="0" cellspacing="0" cellpadding="2"> <?php for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) { echo ' <tr>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['title'] . '</td>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['text'] . '</td>' . "\n" . ' </tr>' . "\n"; } ?> </table></td> </tr> </table> Hope this is of some help.
×