|
||||
|
Zitat:
Hier der Code meiner /lang/german/german.php: --------------------------------------------------------------------------------------*/ include( 'includes/application_top.php'); // create smarty elements $smarty = new Smarty; // include boxes require(DIR_FS_CATALOG .'templates/'.CURRENT_TEMPLATE. '/source/boxes.php'); // include needed functions require_once(DIR_FS_INC . 'xtc_count_customer_orders.inc.php'); require_once(DIR_FS_INC . 'xtc_date_long.inc.php'); require_once(DIR_FS_INC . 'xtc_image_button.inc.php'); require_once(DIR_FS_INC . 'xtc_get_all_get_params.inc.php'); if (!isset($_SESSION['customer_id'])) { xtc_redirect(xtc_href_link(FILENAME_LOGIN, '', 'SSL')); } $breadcrumb->add(NAVBAR_TITLE_1_ACCOUNT_HISTORY, xtc_href_link(FILENAME_ACCOUNT, '', 'SSL')); $breadcrumb->add(NAVBAR_TITLE_2_ACCOUNT_HISTORY, xtc_href_link(FILENAME_ACCOUNT_HISTORY, '', 'SSL')); require(DIR_WS_INCLUDES . 'header.php'); $module_content=array(); if (($orders_total = xtc_count_customer_orders()) > 0) { $history_query_raw = "select o.orders_id, o.date_purchased, o.delivery_name, o.billing_name, ot.text as order_total, s.orders_status_name from " . TABLE_ORDERS . " o, " . TABLE_ORDERS_TOTAL . " ot, " . TABLE_ORDERS_STATUS . " s where o.customers_id = '" . (int)$_SESSION['customer_id'] . "' and o.orders_id = ot.orders_id and ot.class = 'ot_total' and o.orders_status = s.orders_status_id and s.language_id = '" . (int)$_SESSION['languages_id'] . "' order by orders_id DESC"; $history_split = new splitPageResults($history_query_raw, $_GET['page'], MAX_DISPLAY_ORDER_HISTORY); $history_query = xtc_db_query($history_split->sql_query); while ($history = xtc_db_fetch_array($history_query)) { $products_query = xtc_db_query("select count(*) as count from " . TABLE_ORDERS_PRODUCTS . " where orders_id = '" . $history['orders_id'] . "'"); $products = xtc_db_fetch_array($products_query); if (xtc_not_null($history['delivery_name'])) { $order_type = TEXT_ORDER_SHIPPED_TO; $order_name = $history['delivery_name']; } else { $order_type = TEXT_ORDER_BILLED_TO; $order_name = $history['billing_name']; } $module_content[]=array( 'ORDER_ID'=>$history['orders_id'], 'ORDER_STATUS'=>$history['orders_status_name'], 'ORDER_DATE'=>xtc_date_long($history['date_purchased']), 'ORDER_PRODUCTS'=>$products['count'], 'ORDER_TOTAL'=>strip_tags($history['order_total']), 'ORDER_BUTTON'=>'' . xtc_image_button('small_view.gif', SMALL_IMAGE_BUTTON_VIEW) . ''); } } if ($orders_total > 0) { $smarty->assign('SPLIT_BAR',' <tr> <td class="smallText" valign="top">'. $history_split->display_count(TEXT_DISPLAY_NUMBER_OF_ORDERS).'</td> <td class="smallText" align="right">'. TEXT_RESULT_PAGE . ' ' . $history_split->display_links(MAX_DISPLAY_PAGE_LINKS, xtc_get_all_get_params(array('page', 'info', 'x', 'y'))).'</td> </tr>'); } $smarty->assign('order_content',$module_content); $smarty->assign('language', $_SESSION['language']); $smarty->assign('BUTTON_BACK','' . xtc_image_button('button_back.gif', IMAGE_BUTTON_BACK) . ''); $smarty->caching = 0; $main_content=$smarty->fetch(CURRENT_TEMPLATE . '/module/account_history.html'); $smarty->assign('language', $_SESSION['language']); $smarty->assign('main_content',$main_content); $smarty->caching = 0; $smarty->display(CURRENT_TEMPLATE . '/index.html'); ?> |
![]() |
| Lesezeichen |
| Stichworte |
| absenden, bestellung, fehlermeldung |
| Themen-Optionen | |
| Ansicht | |
|
|