function _sortSetting(&$smarty, $urlToSort) { $sort_string = STRING_PRODUCT_SORT; $sort_string = str_replace('{ASC_NAME}', '<a rel="nofollow" href="' . $urlToSort . '&sort=name&direction=ASC">' . STRING_ASC . '</a>', $sort_string); $sort_string = str_replace('{DESC_NAME}', '<a rel="nofollow" href="' . $urlToSort . '&sort=name&direction=DESC">' . STRING_DESC . '</a>', $sort_string); $sort_string = str_replace('{ASC_PRICE}', '<a rel="nofollow" href="' . $urlToSort . '&sort=Price&direction=ASC">' . STRING_ASC . '</a>', $sort_string); $sort_string = str_replace('{DESC_PRICE}', '<a rel="nofollow" href="' . $urlToSort . '&sort=Price&direction=DESC">' . STRING_DESC . '</a>', $sort_string); $sort_string = str_replace('{ASC_RATING}', '<a rel="nofollow" href="' . $urlToSort . '&sort=customers_rating&direction=ASC">' . STRING_ASC . '</a>', $sort_string); $sort_string = str_replace('{DESC_RATING}', '<a rel="nofollow" href="' . $urlToSort . '&sort=customers_rating&direction=DESC">' . STRING_DESC . '</a>', $sort_string); $smarty->assign('string_product_sort', html_amp($sort_string)); }
$_GET['page'] = 1; } else { $_GET['page'] = (int) $_GET['page'] > $TotalPages ? $TotalPages : (int) $_GET['page']; } if (isset($_GET['added']) || isset($_POST['added'])) { $error = STRING_ERROR_LE_LINK_ADDED; } $_SERVER['REQUEST_URI'] = set_query('added='); $lister = getListerRange($_GET['page'], $TotalPages); $le_Categories = le_getCategories(); if (isset($_GET['show_all']) || isset($_POST['show_all'])) { $ob_per_list = $ob_per_list * $TotalPages; $smarty->assign('showAllLinks', '1'); $_GET['page'] = 1; } $smarty->assign('REQUEST_URI', html_amp($_SERVER['REQUEST_URI'])); $smarty->assign('url_allcategories', set_query('le_categoryID=')); $smarty->assign('le_categories', $le_Categories); $smarty->assign('le_CategoryID', $_GET['le_categoryID']); $smarty->assign('curr_page', $_GET['page']); $smarty->assign('last_page', $TotalPages); if (isset($error)) { if ($error != STRING_ERROR_LE_LINK_ADDED) { $smarty->assign('error', $error); $smarty->assign('pst_LINK', html_spchars($_POST['LINK'])); } else { $smarty->assign('error_ok', $error); } } isset($_GET['le_categoryID']) ? (int) $_GET['le_categoryID'] : 1; $smarty->assign('le_links', le_getLinks((int) $_GET['page'], (int) $ob_per_list, ($_GET['le_categoryID'] ? "le_lCategoryID = {$_GET['le_categoryID']}" : '1') . " AND (le_lVerified IS NOT NULL AND le_lVerified <>'0000-00-00 00:00:00' )", 'le_lID, le_lText, le_lDesk, le_lURL, le_lCategoryID, le_lVerified', 'le_lVerified ASC, le_lURL ASC'));
_copyDataFromGetToPage($smarty, $order_statuses); $orders = array(); $offset = 0; $count = 0; $navigatorHtml = GetNavigatorHtml(_getUrlToNavigate(), 10, 'ordGetOrders', $callBackParam, $orders, $offset, $count); $smarty->assign("orders_navigator", $navigatorHtml); $smarty->assign("user_orders", $orders); $smarty->assign("urlToSort", _getUrlToSort()); } $smarty->assign("urlToReturn", html_amp(_getReturnUrl())); $smarty->assign("order_statuses", $order_statuses); $smarty->assign("main_content_template", "order_history.tpl"); } if (isset($order_detailed)) { $orderID = (int) $order_detailed; $smarty->assign("urlToReturn", html_amp(base64_decode($_GET["urlToReturn"]))); $order = ordGetOrder($orderID); if (!$order || $order["customerID"] != regGetIdByLogin($_SESSION["log"])) { unset($order); } else { $orderContent = ordGetOrderContent($orderID); $order_status_report = xNl2Br(stGetOrderStatusReport($orderID)); $order_statuses = ostGetOrderStatues(); $smarty->assign("completed_order_status", ostGetCompletedOrderStatus()); $smarty->assign("orderContent", $orderContent); $smarty->assign("order", $order); $smarty->assign("https_connection_flag", 1); $smarty->assign("order_status_report", $order_status_report); $smarty->assign("order_statuses", $order_statuses); $smarty->assign("order_detailed", 1); $smarty->assign("main_content_template", "order_history.tpl");
function _sortSetting(&$smarty, $urlToSort) { $sort_string = STRING_PRODUCT_SORT; $sort_string = str_replace("{ASC_NAME}", "<a href='" . $urlToSort . "&sort=name&direction=ASC'>" . STRING_ASC . "</a>", $sort_string); $sort_string = str_replace("{DESC_NAME}", "<a href='" . $urlToSort . "&sort=name&direction=DESC'>" . STRING_DESC . "</a>", $sort_string); $sort_string = str_replace("{ASC_PRICE}", "<a href='" . $urlToSort . "&sort=Price&direction=ASC'>" . STRING_ASC . "</a>", $sort_string); $sort_string = str_replace("{DESC_PRICE}", "<a href='" . $urlToSort . "&sort=Price&direction=DESC'>" . STRING_DESC . "</a>", $sort_string); $sort_string = str_replace("{ASC_RATING}", "<a href='" . $urlToSort . "&sort=customers_rating&direction=ASC'>" . STRING_ASC . "</a>", $sort_string); $sort_string = str_replace("{DESC_RATING}", "<a href='" . $urlToSort . "&sort=customers_rating&direction=DESC'>" . STRING_DESC . "</a>", $sort_string); $smarty->assign("string_product_sort", html_amp($sort_string)); }