function olc_catalog_href_link($page = '', $parameters = '', $connection = NONSSL, $add_session_id = false, $search_engine_safe = false, $create_ajax_link = true) { global $use_catalog_link; $use_catalog_link = true; return olc_href_link($page, $parameters, $connection, $add_session_id, $search_engine_safe, $create_ajax_link); $use_catalog_link = false; }
function olc_create_navigation_links($cart_is_filled, $is_logogff) { global $smarty; $sep = HTML_NBSP . "|" . HTML_NBSP; $a_end = '">'; $index = "index"; if ($cart_is_filled) { require_once DIR_FS_INC . 'olc_get_smarty_config_variable.inc.php'; $my_navigation = HTML_A_START . olc_href_link(FILENAME_SHOPPING_CART) . $a_end . olc_get_smarty_config_variable($smarty, $index, "link_cart") . HTML_A_END; $my_navigation .= $sep . HTML_A_START . olc_href_link(FILENAME_CHECKOUT_SHIPPING) . $a_end . olc_get_smarty_config_variable($smarty, $index, "link_checkout") . HTML_A_END; } $login_link = HTML_A_START . olc_href_link(FILENAME_LOGIN) . $a_end . olc_get_smarty_config_variable($smarty, $index, "link_login") . HTML_A_END; if ($my_navigation) { $my_navigation .= $sep; } if ($is_logogff) { $my_navigation .= $login_link; } else { if (ISSET_CUSTOMER_ID) { $my_navigation .= HTML_A_START . olc_href_link(FILENAME_LOGOFF) . $a_end . olc_get_smarty_config_variable($smarty, $index, "link_logoff") . HTML_A_END; if (CUSTOMER_STATUS_ID != DEFAULT_CUSTOMERS_STATUS_ID_GUEST) { $my_navigation .= $sep . HTML_A_START . olc_href_link(FILENAME_ACCOUNT) . $a_end . olc_get_smarty_config_variable($smarty, $index, "link_account") . HTML_A_END; } } else { $my_navigation .= $login_link; } } $my_navigation .= HTML_NBSP; $smarty->assign(BOX_NAVIGATION, $my_navigation); }
function olc_display_banner($action, $identifier) { if ($action == 'dynamic') { $banners_query = olc_db_query(SELECT_COUNT . " as count from " . TABLE_BANNERS . " where status = '1' and banners_group = '" . $identifier . APOS); $banners = olc_db_fetch_array($banners_query); if ($banners['count'] > 0) { $banner = olc_random_select("select banners_id, banners_title, banners_image, banners_html_text from " . TABLE_BANNERS . " where status = '1' and banners_group = '" . $identifier . APOS); } else { return '<b>OLC ERROR! (olc_display_banner(' . $action . ', ' . $identifier . ') -> No banners with group \'' . $identifier . '\' found!</b>'; } } elseif ($action == 'static') { if (is_array($identifier)) { $banner = $identifier; } else { $banner_query = olc_db_query("select banners_id, banners_title, banners_image, banners_html_text from " . TABLE_BANNERS . " where status = '1' and banners_id = '" . $identifier . APOS); if (olc_db_num_rows($banner_query)) { $banner = olc_db_fetch_array($banner_query); } else { return '<b>OLC ERROR! (olc_display_banner(' . $action . ', ' . $identifier . ') -> Banner with id \'' . $identifier . '\' not found, or status inactive</b>'; } } } else { return '<b>OLC ERROR! (olc_display_banner(' . $action . ', ' . $identifier . ') -> Unknown $action parameter value - it must be either \'dynamic\' or \'static\'' . HTML_B_END; } if (olc_not_null($banner['banners_html_text'])) { $banner_string = $banner['banners_html_text']; } else { $banner_string = HTML_A_START . olc_href_link(FILENAME_REDIRECT, 'action=banner&goto=' . $banner['banners_id']) . '" target="_blank">' . olc_image(DIR_WS_IMAGES . 'banner/' . $banner['banners_image'], $banner['banners_title']) . HTML_A_END; } olc_update_banner_display_count($banner['banners_id']); return $banner_string; }
function get_category_tree($parent_id = '0', $spacing = EMPTY_STRING, $exclude = EMPTY_STRING, $category_tree_array = EMPTY_STRING, $include_itself = false, $cPath = EMPTY_STRING) { if ($parent_id == 0) { $cPath = EMPTY_STRING; } else { $cPath .= $parent_id . '_'; } if (!is_array($category_tree_array)) { $category_tree_array = array(); } if (sizeof($category_tree_array) < 1 && $exclude != '0') { $category_tree_array[] = array('id' => '0', 'text' => TEXT_TOP); } if ($include_itself) { $category_query = olc_db_query("\n\t\t\tselect cd.categories_name\n\t\t\tfrom " . TABLE_CATEGORIES_DESCRIPTION . " cd\n\t\t\tWHERE c.categories_status = '1' AND cd.language_id = '" . SESSION_LANGUAGE_ID . "'\n\t\t\tand cd.categories_id = '" . $parent_id . APOS); $category = olc_db_fetch_array($category_query); $category_tree_array[] = array('id' => $parent_id, 'text' => $category['categories_name']); } $categories_query = olc_db_query("\n\t\tselect\n\t\tc.categories_id,\n\t\tcd.categories_name,\n\t\tc.parent_id\n\t\tfrom " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd\n\t\twhere c.categories_id = cd.categories_id\n\t\tand cd.language_id = '" . SESSION_LANGUAGE_ID . "'\n\t\tand c.parent_id = '" . $parent_id . "'\n\t\tand c.categories_status = '1'\n\t\torder by c.sort_order, cd.categories_name"); while ($categories = olc_db_fetch_array($categories_query)) { $categories_id = $categories['categories_id']; if ($exclude != $categories_id) { $category_tree_array[] = array('id' => $categories_id, 'text' => $spacing . $categories['categories_name'], 'link' => olc_href_link(FILENAME_DEFAULT, 'cPath=' . $cPath . $categories_id, NONSSL, false, true, false), 'pcount' => olc_count_products_in_category($categories_id)); $category_tree_array = get_category_tree($categories_id, $spacing . ' ', $exclude, $category_tree_array, false, $cPath); } } return $category_tree_array; }
function olc_customer_greeting() { if (CUSTOMER_ID) { $greeting_string = sprintf(TEXT_GREETING_PERSONAL, trim($_SESSION['customer_first_name'] . BLANK . $_SESSION['customer_last_name']), olc_href_link(FILENAME_PRODUCTS_NEW)); } else { $greeting_string = sprintf(TEXT_GREETING_GUEST, olc_href_link(FILENAME_LOGIN, EMPTY_STRING, SSL), olc_href_link(FILENAME_CREATE_ACCOUNT, EMPTY_STRING, SSL)); } return $greeting_string; }
function olc_create_sort_heading($sortby, $colnum, $heading) { $sort_prefix = ''; $sort_suffix = ''; if ($sortby) { $sort_prefix = HTML_A_START . olc_href_link(CURRENT_SCRIPT, olc_get_all_get_params(array('page', 'info', 'sort')) . 'page=1&sort=' . $colnum . ($sortby == $colnum . 'a' ? 'd' : 'a')) . '" title="' . TEXT_SORT_PRODUCTS . ($sortby == $colnum . 'd' || substr($sortby, 0, 1) != $colnum ? TEXT_ASCENDINGLY : TEXT_DESCENDINGLY) . TEXT_BY . $heading . '" class="productListing-heading">'; $sort_suffix = (substr($sortby, 0, 1) == $colnum ? substr($sortby, 1, 1) == 'a' ? '+' : '-' : '') . HTML_A_END; } return $sort_prefix . $heading . $sort_suffix; }
function menuBox($heading, $contents) { $this->table_data_parameters = 'class="menuBoxHeading"'; $heading_link = $heading[0]['link']; $heading_text = $heading[0]['text']; if ($heading_link) { $heading_text = HTML_A_START . olc_href_link($heading_link) . '" class="menuBoxHeadingLink">' . $heading_text . HTML_A_END; } $heading[0]['text'] = HTML_NBSP . $heading_text . HTML_NBSP; $this->heading = $this->tableBlock($heading); $this->table_data_parameters = 'class="menuBoxContent"'; $this->contents = $this->tableBlock($contents); return $this->heading . $this->contents; }
function olc_show_category($counter, $img = '') { global $foo, $categories_string, $id; $current_entry = $foo[$counter]; if ($current_entry['parent'] == 0) { $cPath_new = $counter; } else { $cPath_new = $current_entry['path']; } $cPath_new = 'cPath=' . $cPath_new; $two_blank = HTML_NBSP . HTML_NBSP; for ($a = 0; $a < $current_entry['level']; $a++) { $indent = $two_blank; } $link = olc_href_link(FILENAME_DEFAULT, $cPath_new); $link = HTML_A_START . $link . '" title="' . $current_entry['title'] . '">'; $make_bold = $id && in_array($counter, $id); if ($make_bold) { $link .= HTML_B_START; } // display category name $link .= $current_entry['name']; if ($make_bold) { $link .= HTML_B_END; } $link .= HTML_A_END; if (SHOW_COUNTS == TRUE_STRING_S) { $products_in_category = olc_count_products_in_category($counter, false); if ($products_in_category > 0) { $link .= HTML_NBSP . ltrim(LPAREN) . $products_in_category . RPAREN; } } if (strlen($categories_string) > 0) { $categories_string .= HTML_BR; } $categories_string .= $indent . $img . $link; $file = CURRENT_TEMPLATE_IMG . 'img_underline.gif'; if (is_file(DIR_FS_CATALOG . $file)) { $categories_string .= HTML_BR . olc_image($file); } $next_id = $current_entry['next_id']; if ($next_id) { olc_show_category($next_id, $img); } }
function olc_draw_form($name, $action, $method = 'post', $action_parameters = '', $form_parameters = '') { //W. Kaiser - AJAX //QUOTE='"'; $html_quot = '"'; $form_name = olc_parse_input_field_data($name, array(QUOTE => $html_quot)); $method_par = olc_parse_input_field_data($method, array(QUOTE => $html_quot)); $action_par = olc_parse_input_field_data($action, array(QUOTE => $html_quot)); if (IS_ADMIN_FUNCTION) { //Note: the admin prog modules use different calling parameter order! $form = $action_parameters; $action_parameters = $method_par; $method_par = $form; $action_par = olc_href_link($action, $action_parameters, NONSSL, true, true, false); $action_parameters = EMPTY_STRING; } else { $form_parameters = $action_parameters; } if ($method_par == EMPTY_STRING) { $method_par = "post"; } if ($form_parameters != EMPTY_STRING) { $form_parameters = BLANK . $form_parameters; } if (USE_AJAX) { //Remove AJAX Javascript routine from "action"-url, as we need it in its original form for the xhttprequest /* if ((strpos($action_par, AJAX_REQUEST_FUNC_START) !== false)) { $action_par = str_replace(AJAX_REQUEST_FUNC_START, EMPTY_STRING, $action_par); $action_par = str_replace(AJAX_REQUEST_FUNC_END, EMPTY_STRING, $action_par); } */ $onsubmit = "onsubmit"; if (strpos(strtolower($form_parameters), strtolower($onsubmit)) === false) { $form_parameters .= BLANK . $onsubmit . '="return make_AJAX_Request_POST(\'' . $name . '\',\'' . $action_par . '\');"'; } $form_name .= '" id="' . $form_name; } //W. Kaiser - AJAX $form = '<form name="' . $form_name . '" action="' . $action_par . '" method="' . $method_par . QUOTE . $form_parameters . '>'; return $form; }
function display_links($query_numrows, $max_rows_per_page, $max_page_links, $current_page_number, $parameters = '', $page_name = 'page') { if (olc_not_null($parameters) && substr($parameters, -1) != '&') { $parameters .= '&'; } // calculate number of pages needing links $num_pages = ceil($query_numrows / $max_rows_per_page); $pages_array = array(); for ($i = 1; $i <= $num_pages; $i++) { $pages_array[] = array('id' => $i, 'text' => $i); } if ($num_pages > 1) { $display_links = olc_draw_form('pages', CURRENT_SCRIPT, '', 'get'); if ($current_page_number > 1) { $display_links .= HTML_A_START . olc_href_link(CURRENT_SCRIPT, $parameters . $page_name . '=' . ($current_page_number - 1), NONSSL) . '" class="splitPageLink">' . PREVNEXT_BUTTON_PREV . '</a> '; } else { $display_links .= PREVNEXT_BUTTON_PREV . ' '; } $display_links .= sprintf(TEXT_RESULT_PAGE, olc_draw_pull_down_menu($page_name, $pages_array, $current_page_number, 'onchange="this.form.submit();"'), $num_pages); if ($current_page_number < $num_pages && $num_pages != 1) { $display_links .= ' <a href="' . olc_href_link(CURRENT_SCRIPT, $parameters . $page_name . '=' . ($current_page_number + 1), NONSSL) . '" class="splitPageLink">' . PREVNEXT_BUTTON_NEXT . HTML_A_END; } else { $display_links .= ' ' . PREVNEXT_BUTTON_NEXT; } if ($parameters != '') { if (substr($parameters, -1) == '&') { $parameters = substr($parameters, 0, -1); } $pairs = explode('&', $parameters); while (list(, $pair) = each($pairs)) { list($key, $value) = explode('=', $pair); $display_links .= olc_draw_hidden_field(rawurldecode($key), rawurldecode($value)); } } if (SID) { $display_links .= olc_draw_hidden_field(session_name(), session_id()); } $display_links .= '</form>'; } else { $display_links = sprintf(TEXT_RESULT_PAGE, $num_pages, $num_pages); } return $display_links; }
function olc_show_category_content($counter) { global $foo, $categories_string, $id; for ($a = 0; $a < $foo[$counter]['level']; $a++) { $categories_string .= " "; } $categories_string .= HTML_A_START; if ($foo[$counter]['parent'] == 0) { $cPath = $counter; } else { $cPath = $foo[$counter]['path']; } $cPath_new = 'cPath=' . $cPath; $categories_string .= olc_href_link(FILENAME_DEFAULT, $cPath_new) . '">'; if ($id && in_array($counter, $id)) { $categories_string .= HTML_B_START; } // display category name $categories_string .= $foo[$counter]['name']; if ($id && in_array($counter, $id)) { $categories_string .= HTML_B_END; } if (olc_has_category_subcategories($counter)) { $categories_string .= '->'; } $categories_string .= HTML_A_END; if (SHOW_COUNTS == TRUE_STRING_S) { $products_in_category = olc_count_products_in_category($counter); if ($products_in_category > 0) { $categories_string .= ' (' . $products_in_category . RPAREN; } } $categories_string .= HTML_BR; if ($foo[$counter]['next_id']) { olc_show_category_content($foo[$counter]['next_id']); } }
</td> </tr> <tr> <td width="10%" valign="top"><?php echo TEXT_BODY; ?> </td> <td width="90%"><?php $sw = new SPAW_Wysiwyg($control_name = 'newsletter_body', $value = stripslashes($newsletters_data['body']), $lang = EMPTY_STRING, $mode = 'full', $theme = 'default', $width = '100%', $height = '800px', $css_stylesheet = SPAW_STYLESHEET, $dropdown_data = EMPTY_STRING); $sw->show(); ?> </td> </tr> </table> <a href="<?php echo olc_href_link(FILENAME_MODULE_NEWSLETTER); ?> "> <?php echo olc_image_button('button_back.gif', IMAGE_BACK); ?> </a> <right><?php echo olc_image_submit('button_save.gif', IMAGE_SAVE); ?> </right> </form> <?php break; } // end switch
} else { $smarty->assign('GLOBAL_NOTIFICATION', '1'); } if ($global['global_product_notifications'] != '1') { $products_check_query = olc_db_query("select count(*) as total from " . TABLE_PRODUCTS_NOTIFICATIONS . " where customers_id = '" . (int) $_SESSION['customer_id'] . APOS); $products_check = olc_db_fetch_array($products_check_query); if ($products_check['total'] > 0) { $counter = 0; $notifications_products = '<table width="100%" border="0" cellspacing="0" cellpadding="0">'; $products_query = olc_db_query("select pd.products_id, pd.products_name from " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_NOTIFICATIONS . " pn where pn.customers_id = '" . (int) $_SESSION['customer_id'] . "' and pn.products_id = pd.products_id and pd.language_id = '" . SESSION_LANGUAGE_ID . "' order by pd.products_name"); while ($products = olc_db_fetch_array($products_query)) { $notifications_products .= ' <tr class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="javascript:checkBox(\'products[' . $counter . ']\')"> <td class="main" width="30">' . olc_draw_checkbox_field('products[' . $counter . ']', $products['products_id'], true, 'onclick="javascript:checkBox(\'products[' . $counter . ']\')"') . '</td> <td class="main"><b>' . $products['products_name'] . '</b></td> </tr> '; $counter++; } $notifications_products .= '</table>'; $smarty->assign('PRODUCTS_NOTIFICATION', $notifications_products); } else { } } $smarty->assign('FORM_ACTION', olc_draw_form('account_notifications', olc_href_link(FILENAME_ACCOUNT_NOTIFICATIONS, '', SSL)) . olc_draw_hidden_field('action', 'process')); $smarty->assign('BUTTON_BACK', HTML_A_START . olc_href_link(FILENAME_ACCOUNT, '', SSL) . '">' . olc_image_button('button_back.gif', IMAGE_BUTTON_BACK) . HTML_A_END); $smarty->assign('BUTTON_CONTINUE', olc_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE)); $main_content = $smarty->fetch(CURRENT_TEMPLATE_MODULE . 'account_notifications' . HTML_EXT, SMARTY_CACHE_ID); $smarty->assign(MAIN_CONTENT, $main_content); require BOXES; $smarty->display(INDEX_HTML);
function draw_href_link($ppURLText, $ppURLParams = '', $ppURL = FILENAME_PAYPAL, $js = true) { //$ppURL = olc_href_link(FILENAME_PAYPAL,'action=details&info='.$ppTxnID); $ppURL = olc_href_link($ppURL, $ppURLParams); if ($js === true) { $ppScriptLink = '<script language="javascript" type="text/javascript"><!-- document.write("<a style=\\"color: #0033cc; text-decoration: none;\\" href=\\"javascript:openWindow(\'' . $ppURL . '\');\\" tabindex=\\"-1\\">' . $ppURLText . '</a>"); --></script><noscript><a style="text-decoration: none;" href="' . $ppURL . '" target="PayPal">' . $ppURLText . '</a></noscript>'; } else { $ppScriptLink = '<a style="text-decoration: none;" href="' . $ppURL . '" target="PayPal">' . $ppURLText . HTML_A_END; } return $ppScriptLink; }
$coupon_code = create_coupon_code(); $insert_query = olc_db_query(INSERT_INTO . TABLE_COUPONS . " (coupon_code, coupon_type, coupon_amount, date_created) values ('" . $coupon_code . "', 'G', '" . NEW_SIGNUP_GIFT_VOUCHER_AMOUNT . "', now())"); $insert_id = olc_db_insert_id($insert_query); $insert_query = olc_db_query(INSERT_INTO . TABLE_COUPON_EMAIL_TRACK . " (coupon_id, customer_id_sent, sent_firstname, emailed_to, date_sent) values ('" . $insert_id . "', '0', 'Admin', '" . $customers_email_address . "', now() )"); $html_mail .= '<br/><br/>' . sprintf(EMAIL_GV_INCENTIVE_HEADER, $currencies->format(NEW_SIGNUP_GIFT_VOUCHER_AMOUNT)) . "<br/><br/>" . sprintf(EMAIL_GV_REDEEM, $coupon_code) . "<br/><br/>" . EMAIL_GV_LINK . olc_href_link(FILENAME_GV_REDEEM, 'gv_no=' . $coupon_code, NONSSL, false) . "<br/><br/>"; $txt_mail .= "\n\n" . sprintf(EMAIL_GV_INCENTIVE_HEADER, $currencies->format(NEW_SIGNUP_GIFT_VOUCHER_AMOUNT)) . "\n\n" . sprintf(EMAIL_GV_REDEEM, $coupon_code) . "\n\n" . EMAIL_GV_LINK . olc_href_link(FILENAME_GV_REDEEM, 'gv_no=' . $coupon_code, NONSSL, false) . "\n\n"; } if (NEW_SIGNUP_DISCOUNT_COUPON != '') { $coupon_code = NEW_SIGNUP_DISCOUNT_COUPON; $coupon_query = olc_db_query("select * from " . TABLE_COUPONS . " where coupon_code = '" . $coupon_code . APOS); $coupon = olc_db_fetch_array($coupon_query); $coupon_id = $coupon['coupon_id']; $coupon_desc_query = olc_db_query("select * from " . TABLE_COUPONS_DESCRIPTION . " where coupon_id = '" . $coupon_id . "' and language_id = '" . (int) $_SESSION['languages_id'] . APOS); $coupon_desc = olc_db_fetch_array($coupon_desc_query); $insert_query = olc_db_query(INSERT_INTO . TABLE_COUPON_EMAIL_TRACK . " (coupon_id, customer_id_sent, sent_firstname, emailed_to, date_sent) values ('" . $coupon_id . "', '0', 'Admin', '" . $customers_email_address . "', now() )"); $html_mail .= "<br/><br/>" . EMAIL_COUPON_INCENTIVE_HEADER . HTML_BR . sprintf("%s", $coupon_desc['coupon_description']) . "<br/><br/>" . sprintf(EMAIL_COUPON_REDEEM, $coupon['coupon_code']) . "<br/><br/>" . "<br/><br/>"; $txt_mail .= "\n\n" . EMAIL_COUPON_INCENTIVE_HEADER . NEW_LINE . sprintf("%s", $coupon_desc['coupon_description']) . "\n\n" . sprintf(EMAIL_COUPON_REDEEM, $coupon['coupon_code']) . "\n\n" . "\n\n"; } // ICW - CREDIT CLASS CODE BLOCK ADDED ******************************************************* END // GV Code End // W. Kaiser - eMail-type by customer olc_php_mail(EMAIL_SUPPORT_ADDRESS, EMAIL_SUPPORT_NAME, $customers_email_address, $name, EMAIL_SUPPORT_FORWARDING_STRING, EMAIL_SUPPORT_REPLY_ADDRESS, EMAIL_SUPPORT_REPLY_ADDRESS_NAME, '', '', EMAIL_SUPPORT_SUBJECT, $html_mail, $txt_mail, $customers_email_type); // W. Kaiser - eMail-type by customer if (!isset($mail_error)) { olc_redirect(olc_href_link(FILENAME_SHOPPING_CART)); } } } // W. Kaiser - Common code for "create_account.php" and "customers.php" include DIR_FS_INC . 'olc_show_customer_data_form.inc.php'; // W. Kaiser - Common code for "create_account.php" and "customers.php"
Released under the GNU General Public License --------------------------------------------------------------*/ require 'includes/application_top.php'; //select all auctions which transformed to a real order $auctionssql = SELECT_ALL . TABLE_AUCTION_LIST . " l, " . TABLE_AUCTION_DETAILS . " d\nWHERE l.auction_id=d.auction_id AND l.ended=1 AND d.order_number!=0 " . $ordersql; $myauctions = olc_db_query($auctionssql); $orderby = "auction_id"; //Default order field require_once DIR_WS_FUNCTIONS . 'list_sorting.php'; $heading = array(array($name_text => AUCTIONS_TEXT_AUCTION_AMOUNT, $attributes_text => $align_center_text, $sort_text => str_replace(HASH, $auction_title_text, $sort0), $link_text => $file . $auction_title_text), array($name_text => AUCTIONS_TEXT_AUCTION_LIST_EBAY_ID, $attributes_text => $align_center_text, $sort_text => str_replace(HASH, $auction_id_text, $sort0), $link_text => $file . $auction_id_text), array($name_text => AUCTIONS_TEXT_AUCTION_SOLD_BUYER, $attributes_text => $align_right_text, $sort_text => str_replace(HASH, $buyer_id_text, $sort0), $link_text => $file . $buyer_id_text), array($name_text => AUCTIONS_TEXT_AUCTION_SOLD_COUNTRY, $attributes_text => $align_center_text, $sort_text => str_replace(HASH, $buyer_land_text, $sort0), $link_text => $file . $buyer_land_text), array($name_text => AUCTIONS_TEXT_AUCTION_SOLD_PRICE, $attributes_text => $align_center_text, $sort_text => str_replace(HASH, auction_endprice_text, $sort0), $link_text => $file . auction_endprice_text), array($name_text => AUCTIONS_TEXT_AUCTION_LIST_END_TIME, $attributes_text => $align_center_text, $sort_text => str_replace(HASH, $endtime_text, $sort0), $link_text => $file . $endtime_text), array($name_text => AUCTIONS_TEXT_AUCTION_SOLD_ORDER_ORDERNR, $attributes_text => $align_center_text, $sort_text => str_replace(HASH, $order_number_text, $sort0), $link_text => $file . $order_number_text)); /* print table heading */ $main_content .= tableheading($heading); $auction_endprice_text = 'auction_endprice'; $order_number_text = 'order_number'; $order_icon = olc_image(DIR_WS_ICONS . 'order.gif', BOX_ORDERS) . BLANK; $link = olc_href_link(FILENAME_ORDERS, 'oID=#&action=edit'); $i = 0; while ($auctions_values = olc_db_fetch_array($myauctions)) { $i++; if ($i % 2 == 0) { $class = $dataTableRow_1_text; } else { $class = $dataTableRow_text; } /* define content array */ $quantity = $auctions_values[$quantity_text]; $auction_id = $auctions_values[$auction_id_text]; $buyer_id = $auctions_values[$buyer_id_text]; $buyer_land = $auctions_values[$buyer_land_text]; $auction_endprice = $auctions_values[$auction_endprice_text]; $auction_endprice = olc_format_price($auction_endprice, 1, 1, 1);
} $sql_command .= ");"; olc_db_query($sql_command); $time_end = microtime_float(); $time = $time_end - $time_start; $main_content = '<br/><b>' . $blzs . ' Datensätze wurden aus Datei: \'' . $filename . ' \' aktualisiert.</b><br/><br/>'; if ($old_status != EMPTY_STRING) { $main_content .= 'Alter Stand: ' . $old_status . HTML_BR; } $pos = strrpos($filename, '.'); $main_content .= 'Neuer Stand: ' . substr($filename, 0, $pos) . "<br/><br/>"; } else { $err_message = 'Keine BLZ-Daten in Datei \'' . $upload_dir . '/' . $filename . '\' gefunden'; } } else { $button_continue = HTML_A_START . olc_href_link(CURRENT_SCRIPT, 'full=1&ignorestatus=true', NONSSL) . '">' . olc_template_image_button('button_continue.gif', 'Weiter mit dem BLZ-Update') . HTML_A_END; $err_message = '<div class="main"><br/> Die BLZ-Datenbank hat schon den aktuellen Stand <b>"' . $old_status . '"</b>. <p>Trotzdem weiter?</p> <table border="0" cellspacing="0" cellpadding="0"> <tr> <td class="main" align="left" valign="bottom">' . $button_back . ' </td> <td class="main" align="right" valign="bottom"><b><font color="#FF0000">Die Bearbeitung kann 3 bis 5 Minuten dauern! Bitte keinesfalls unterbrechen!<br/> </font></b><br/>' . $button_continue . '</td> </tr> </table> </div> '; echo $err_message; exit;
---------------------------------------------------------------------------------------*/ include 'includes/application_top.php'; // include needed functions require_once DIR_FS_INC . 'olc_word_count.inc.php'; require_once DIR_FS_INC . 'olc_date_long.inc.php'; $breadcrumb->add(NAVBAR_TITLE_REVIEWS, olc_href_link(FILENAME_REVIEWS)); require DIR_WS_INCLUDES . 'header.php'; $reviews_query_raw = "\nselect r.reviews_id,\nleft(rd.reviews_text, 250) as reviews_text,\nr.reviews_rating,\nr.date_added,\np.products_id,\npd.products_name,\np.products_image,\nr.customers_name\nfrom " . TABLE_REVIEWS . " r, " . TABLE_REVIEWS_DESCRIPTION . " rd, " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd\nwhere\np.products_status = 1 and\np.products_id = r.products_id and\nr.reviews_id = rd.reviews_id and\np.products_id = pd.products_id and\npd.language_id = " . SESSION_LANGUAGE_ID . " and\nrd.languages_id = " . SESSION_LANGUAGE_ID . "\norder by r.reviews_id DESC"; $reviews_split = new splitPageResults($reviews_query_raw, $_GET['page'], MAX_DISPLAY_NEW_REVIEWS); if ($reviews_split->number_of_rows > 0 && (PREV_NEXT_BAR_LOCATION == '1' || PREV_NEXT_BAR_LOCATION == '3')) { $smarty->assign('NAVBAR', ' <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText">' . $reviews_split->display_count(TEXT_DISPLAY_NUMBER_OF_REVIEWS) . '</td> <td align="right" class="smallText">' . TEXT_RESULT_PAGE . BLANK . $reviews_split->display_links(MAX_DISPLAY_PAGE_LINKS, olc_get_all_get_params(array('page', 'info', 'x', 'y'))) . '</td> </tr> </table> '); } $module_data = array(); if ($reviews_split->number_of_rows > 0) { $reviews_query = olc_db_query($reviews_split->sql_query); while ($reviews = olc_db_fetch_array($reviews_query)) { $module_data[] = array('PRODUCTS_IMAGE' => DIR_WS_THUMBNAIL_IMAGES . $reviews['products_image'], $reviews['products_name'], 'PRODUCTS_LINK' => olc_href_link(FILENAME_PRODUCT_REVIEWS_INFO, 'products_id=' . $reviews['products_id'] . '&reviews_id=' . $reviews['reviews_id']), 'PRODUCTS_NAME' => $reviews['products_name'], 'AUTHOR' => $reviews['customers_name'], 'TEXT' => sprintf(TEXT_REVIEW_WORD_COUNT, olc_word_count($reviews['reviews_text'], BLANK)) . ')<br/>' . htmlspecialchars($reviews['reviews_text']) . '..', 'RATING' => olc_image(DIR_WS_IMAGES . 'stars_' . $reviews['reviews_rating'] . '.gif', sprintf(BOX_REVIEWS_TEXT_OF_5_STARS, $reviews['reviews_rating']))); } $smarty->assign(MODULE_CONTENT, $module_data); } $main_content = $smarty->fetch(CURRENT_TEMPLATE_MODULE . 'reviews' . HTML_EXT, SMARTY_CACHE_ID); $smarty->assign(MAIN_CONTENT, $main_content); require BOXES; $smarty->display(INDEX_HTML);
$products_price = abs(olc_get_products_price($prid, $price_special = 0, $quantity = 1)); $price_raw += $products_price; $products[] = array('id' => $products_id, 'name' => $current_product['products_name'], 'model' => $current_product['products_model'], 'image' => $current_product['products_image'], 'price' => $current_product_price, 'discount_allowed' => $current_product['products_discount_allowed'], 'quantity' => $products_basket['customers_basket_quantity'], 'weight' => $current_product['products_weight'], 'final_price' => $products_price, 'tax_class_id' => $current_product['products_tax_class_id']); } } $show_saved_cart = true; $module_content_save = $module_content; include_once DIR_WS_MODULES . 'order_details_cart.php'; $module_content = $module_content_save; $show_saved_cart = false; } } else { $parameters = 'basket_id=' . $basket_id; $cart_content = EMPTY_STRING; } $link = olc_href_link(CURRENT_SCRIPT, $parameters); $date = $basket['basket_date_added']; $date = substr($date, 6, 2) . DOT . substr($date, 4, 2) . DOT . substr($date, 0, 4); $module_content[] = array('show_order_details' => $show_order_details, 'BOX_SELECT' => olc_draw_radio_field('cart_select[]', $basket_id, $selected), 'NAME' => $basket['basket_name'], 'DATE' => $date, 'BOX_DELETE' => olc_draw_checkbox_field('cart_delete[]', $basket_id), 'LINK' => $link); } } else { $error_message = olc_get_smarty_config_variable($smarty, 'shopping_cart', 'text_no_saved_cart'); } $cart_restore_text = 'cart_restore'; if ($error_message) { $module_smarty->assign('ERROR_MESSAGE', $error_message); } else { $module_smarty->assign(MODULE_CONTENT, $module_content); if ($bid) { $MODULE_order_details_text = 'MODULE_order_details'; $module_smarty->assign($MODULE_order_details_text, $smarty->_tpl_vars[$MODULE_order_details_text]);
function before_process() { if ($_POST['x_response_code'] != '1') { if (USE_AJAX) { ajax_error(MODULE_PAYMENT_2CHECKOUT_TEXT_ERROR_MESSAGE); } else { olc_redirect(olc_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_2CHECKOUT_TEXT_ERROR_MESSAGE), SSL, true, false)); } } }
function display() { $customers_statuses_array = olc_get_customers_statuses(); // build Currency Select $curr = ''; $currencies = olc_db_query("SELECT code FROM " . TABLE_CURRENCIES); while ($currencies_data = olc_db_fetch_array($currencies)) { $curr .= olc_draw_radio_field('currencies', $currencies_data['code'], true) . $currencies_data['code'] . HTML_BR; } return array('text' => EXPORT_STATUS_TYPE . HTML_BR . EXPORT_STATUS . HTML_BR . olc_draw_pull_down_menu('status', $customers_statuses_array, '1') . HTML_BR . CURRENCY . HTML_BR . CURRENCY_DESC . HTML_BR . $curr . EXPORT_TYPE . HTML_BR . EXPORT . HTML_BR . olc_draw_radio_field('export', 'no', false) . EXPORT_NO . HTML_BR . olc_draw_radio_field('export', 'yes', true) . EXPORT_YES . HTML_BR . HTML_BR . olc_image_submit('button_export.gif', IMAGE_UPDATE) . HTML_A_START . olc_href_link(FILENAME_MODULE_EXPORT, 'set=' . $_GET['set'] . '&module=kelkoo') . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END); }
$contents[] = array('text' => TEXT_INFO_EDIT_INTRO); $contents[] = array('text' => HTML_BR . TEXT_INFO_CLASS_TITLE . HTML_BR . olc_draw_input_field('tax_class_title', $tcInfo->tax_class_title)); $contents[] = array('text' => HTML_BR . TEXT_INFO_CLASS_DESCRIPTION . HTML_BR . olc_draw_input_field('tax_class_description', $tcInfo->tax_class_description)); $contents[] = array('align' => 'center', 'text' => HTML_BR . olc_image_submit('button_update.gif', IMAGE_UPDATE) . ' <a href="' . olc_href_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $tcInfo->tax_class_id) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END); break; case 'delete': $heading[] = array('text' => HTML_B_START . TEXT_INFO_HEADING_DELETE_TAX_CLASS . HTML_B_END); $contents = array('form' => olc_draw_form('classes', FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $tcInfo->tax_class_id . '&action=deleteconfirm')); $contents[] = array('text' => TEXT_INFO_DELETE_INTRO); $contents[] = array('text' => '<br/><b>' . $tcInfo->tax_class_title . HTML_B_END); $contents[] = array('align' => 'center', 'text' => HTML_BR . olc_image_submit('button_delete.gif', IMAGE_DELETE) . ' <a href="' . olc_href_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $tcInfo->tax_class_id) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END); break; default: if (is_object($tcInfo)) { $heading[] = array('text' => HTML_B_START . $tcInfo->tax_class_title . HTML_B_END); $contents[] = array('align' => 'center', 'text' => HTML_A_START . olc_href_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $tcInfo->tax_class_id . '&action=edit') . '">' . olc_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . olc_href_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $tcInfo->tax_class_id . '&action=delete') . '">' . olc_image_button('button_delete.gif', IMAGE_DELETE) . HTML_A_END); $contents[] = array('text' => HTML_BR . TEXT_INFO_DATE_ADDED . BLANK . olc_date_short($tcInfo->date_added)); $contents[] = array('text' => '' . TEXT_INFO_LAST_MODIFIED . BLANK . olc_date_short($tcInfo->last_modified)); $contents[] = array('text' => HTML_BR . TEXT_INFO_CLASS_DESCRIPTION . HTML_BR . $tcInfo->tax_class_description); } break; } if (olc_not_null($heading) && olc_not_null($contents)) { echo ' <td width="25%" valign="top">' . NEW_LINE; $box = new box(); echo $box->infoBox($heading, $contents); echo ' </td>' . NEW_LINE; } ?> </tr> </table></td>
case 'delete': $heading[] = array('text' => HTML_B_START . TEXT_HEADING_DELETE_BLACKLIST_CARD . HTML_B_END); $contents = array('form' => olc_draw_form('blacklisted', FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $bInfo->blacklist_id . '&action=deleteconfirm')); $contents[] = array('text' => TEXT_DELETE_INTRO); $contents[] = array('text' => '<br/><b>' . $bInfo->blacklist_card_number . HTML_B_END); // $contents[] = array('text' => HTML_BR . olc_draw_checkbox_field('delete_image', '', true) . BLANK . TEXT_DELETE_IMAGE); // if ($mInfo->products_count > 0) { // $contents[] = array('text' => HTML_BR . olc_draw_checkbox_field('delete_products') . BLANK . TEXT_DELETE_PRODUCTS); // $contents[] = array('text' => HTML_BR . sprintf(TEXT_DELETE_WARNING_PRODUCTS, $mInfo->products_count)); // } $contents[] = array('align' => 'center', 'text' => HTML_BR . olc_image_submit('button_delete.gif', IMAGE_DELETE) . BLANK . HTML_A_START . olc_href_link(FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $bInfo->blacklist_id) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END); break; default: if (is_object($bInfo)) { $heading[] = array('text' => HTML_B_START . $bInfo->blacklist_card_number . HTML_B_END); $contents[] = array('align' => 'center', 'text' => HTML_A_START . olc_href_link(FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $bInfo->blacklist_id . '&action=edit') . '">' . olc_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . olc_href_link(FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $bInfo->blacklist_id . '&action=delete') . '">' . olc_image_button('button_delete.gif', IMAGE_DELETE) . HTML_A_END); $contents[] = array('text' => HTML_BR . TEXT_DATE_ADDED . BLANK . olc_date_short($bInfo->date_added)); if (olc_not_null($bInfo->last_modified)) { $contents[] = array('text' => TEXT_LAST_MODIFIED . BLANK . olc_date_short($bInfo->last_modified)); } // $contents[] = array('text' => HTML_BR . olc_info_image($mInfo->manufacturers_image, $mInfo->manufacturers_name)); // $contents[] = array('text' => HTML_BR . TEXT_PRODUCTS . BLANK . $mInfo->products_count); } break; } if (olc_not_null($heading) && olc_not_null($contents)) { echo ' <td width="25%" valign="top">' . NEW_LINE; $box = new box(); echo $box->infoBox($heading, $contents); echo ' </td>' . NEW_LINE; }
Guest account idea by Ingo T. <*****@*****.**> ---------------------------------------------------------------------------------------*/ $IsGuest = true; require_once 'includes/application_top.php'; require_once BOXES; $IsCreateAccount = true; $IsUserMode = true; define('MESSAGE_STACK_NAME', 'create_account'); define('SMARTY_TEMPLATE', MESSAGE_STACK_NAME); $process = $_POST['action'] == 'process'; if ($process) { // W. Kaiser - Common code for "create_account.php" and "customers.php" include DIR_FS_INC . 'olc_get_check_customer_data.php'; // W. Kaiser - Common code for "create_account.php" and "customers.php" if ($error) { if (IS_AJAX_PROCESSING) { //Add messagestackinfo if (is_object($messageStack)) { $m = $messageStack->size(MESSAGE_STACK_NAME); if ($m > 0) { ajax_error($messageStack->output(MESSAGE_STACK_NAME)); } } } } else { olc_redirect(olc_href_link(FILENAME_CHECKOUT_SHIPPING)); } } // W. Kaiser - Common code for "create_account.php" and "customers.php" include DIR_FS_INC . 'olc_show_customer_data_form.inc.php'; // W. Kaiser - Common code for "create_account.php" and "customers.php"
// Re-Post all POST'ed variables reset($_POST); while (list($key, $value) = each($_POST)) { if (!is_array($_POST[$key])) { echo olc_draw_hidden_field($key, htmlspecialchars(stripslashes($value))); } } ?> <table border="0" width="100%" cellpadding="0" cellspacing="2"> <tr> <td><?php echo olc_image_submit('button_back.gif', IMAGE_BACK, 'name="back"'); ?> </td> <td align="right"><?php echo HTML_A_START . olc_href_link(FILENAME_MAIL) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . '</a> ' . olc_image_submit('button_send_mail.gif', IMAGE_SEND_EMAIL); ?> </td> </tr> </table></td> </tr> </table></td> </form></tr> <?php } else { ?> <tr><?php echo olc_draw_form('mail', FILENAME_MAIL, 'action=preview'); ?> <td><table border="0" cellpadding="0" cellspacing="2"> <tr>
<?php /* ----------------------------------------------------------------------------------------- $Id: add_a_quickie.php,v 1.2 2004/02/17 16:20:07 fanta2k Exp $ OL-Commerce Version 5.x/AJAX http://www.ol-commerce.com, http://www.seifenparadies.de Copyright (c) 2004 OL-Commerce, 2006 Dipl.-Ing.(TH) Winfried Kaiser (w.kaiser@fortune.de, info@seifenparadies.de) ----------------------------------------------------------------------------------------- based on: (c) 2000-2001 The Exchange Project (earlier name of osCommerce) (c) 2002-2003 osCommerce(add_a_quickie.php,v 1.10 2001/12/19); www.oscommerce.com Released under the GNU General Public License ----------------------------------------------------------------------------------------- Third Party contribution: Add A Quickie v1.0 Autor Harald Ponce de Leon Released under the GNU General Public License ---------------------------------------------------------------------------------------*/ olc_smarty_init($box_smarty, $cacheid); $box_content = olc_draw_form('quick_add', olc_href_link('index' . PHP), 'get'); $box_smarty->assign('FORM_ACTION', $box_content); $box_smarty->assign('INPUT_FIELD', olc_draw_hidden_field('action', 'buy_now') . olc_draw_input_field('BUYproducts_model', EMPTY_STRING, 'size=10')); $box_smarty->assign('SUBMIT_BUTTON', olc_image_submit('button_buy_now.gif', BOX_HEADING_ADD_PRODUCT_ID)); $box_add_a_quickie = $box_smarty->fetch(CURRENT_TEMPLATE_BOXES . 'box_add_a_quickie' . HTML_EXT, $cacheid); $smarty->assign('box_ADD_A_QUICKIE', $box_add_a_quickie);
Copyright (c) 2005 OL-Commerce , 2006 Dipl.-Ing.(TH) Winfried Kaiser (w.kaiser@fortune.de, info@seifenparadies.de) ----------------------------------------------------------------------------- based on: (c) 2003 OSC-Affiliate (affiliate_signup_ok.php, v 1.6 2003/02/23); http://oscaffiliate.sourceforge.net/ Contribution based on: osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2002 - 2003 osCommerce Copyright (c) 2003 netz-designer Copyright (c) 2005 OL-Commerce , 2006 Dipl.-Ing.(TH) Winfried Kaiser (w.kaiser@fortune.de, info@seifenparadies.de) Copyright (c) 2002 - 2003 osCommerce Released under the GNU General Public License ---------------------------------------------------------------------------*/ require 'includes/application_top.php'; // include needed functions require_once DIR_FS_INC . 'olc_image_button.inc.php'; $breadcrumb->add(NAVBAR_TITLE, olc_href_link(FILENAME_AFFILIATE, '', SSL)); $breadcrumb->add(NAVBAR_TITLE_SIGNUP_OK); require DIR_WS_INCLUDES . 'header.php'; $smarty->assign('LINK_SUMMARY', HTML_A_START . olc_href_link(FILENAME_AFFILIATE_SUMMARY, '', SSL) . '">' . olc_image_button('button_continue.gif', IMAGE_BUTTON_CONTINUE) . HTML_A_END); $main_content = $smarty->fetch(CURRENT_TEMPLATE_MODULE . 'affiliate_signup_ok' . HTML_EXT, SMARTY_CACHE_ID); $smarty->assign(MAIN_CONTENT, $main_content); require BOXES; $smarty->display(INDEX_HTML);
if ($last_name != '') { $first_name = $_POST['first_name']; $fon = $_POST['fon']; $fax = $_POST['fax']; require_once $dir . 'includes/functions/address_validation.php'; //IsValidAddress('81', $postcode, $city, $street, $last_name, $fon, $fax, $message); IsValidAddress('81', $postcode, $city, $street_address, $last_name, $first_name, $fon, $fax, $message); $build_input = false; } } } } echo '<html><body><p align="center"><b><font size="4" color="#FF0000">Online Adress-Validierung</font></b></p>'; //W. Kaiser - AJAX //echo '<form method="POST" action="check_address.php">'; echo olc_draw_form('check_address', olc_href_link('check_address.php')); //W. Kaiser - AJAX echo '<table border="0" align="center">'; show_input_field('last_name', 'last_name', $build_input, $last_name); show_input_field('Vorame', 'first_name', $build_input, $first_name); show_input_field('Strasse', 'street', $build_input, $street); show_input_field('Postleitzahl', 'postcode', $build_input, $postcode); show_input_field('Ort', 'city', $build_input, $city); show_input_field('Fon', 'fon', $build_input, $fon); show_input_field('Fax', 'fax', $build_input, $fax); if (!$build_input) { echo '<tr> <td colspan="2"><br/><hr/>' . str_replace(HTML_NBSP, '', $message) . '<br/><br/><hr/> </td> </tr> ';
$heading[] = array('text' => HTML_B_START . $abInfo->affiliate_banners_title . HTML_B_END); $contents = array('form' => olc_draw_form('affiliate_banners', FILENAME_AFFILIATE_BANNER_MANAGER, 'page=' . $_GET['page'] . '&abID=' . $abInfo->affiliate_banners_id . '&action=deleteconfirm')); $contents[] = array('text' => TEXT_INFO_DELETE_INTRO); $contents[] = array('text' => '<br/><b>' . $abInfo->affiliate_banners_title . HTML_B_END); if ($abInfo->affiliate_banners_image) { $contents[] = array('text' => HTML_BR . olc_draw_checkbox_field('delete_image', 'on', true) . BLANK . TEXT_INFO_DELETE_IMAGE); } $contents[] = array('align' => 'center', 'text' => HTML_BR . olc_image_submit('button_delete.gif', IMAGE_DELETE) . ' <a href="' . olc_href_link(FILENAME_AFFILIATE_BANNER_MANAGER, 'page=' . $_GET['page'] . '&abID=' . $_GET['abID']) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END); break; default: if (is_object($abInfo)) { $sql = "select products_name from " . TABLE_PRODUCTS_DESCRIPTION . " where products_id = '" . $abInfo->affiliate_products_id . "' and language_id = '" . SESSION_LANGUAGE_ID . APOS; $product_description_query = olc_db_query($sql); $product_description = olc_db_fetch_array($product_description_query); $heading[] = array('text' => HTML_B_START . $abInfo->affiliate_banners_title . HTML_B_END); $contents[] = array('align' => 'center', 'text' => HTML_A_START . olc_href_link(FILENAME_AFFILIATE_BANNER_MANAGER, 'page=' . $_GET['page'] . '&abID=' . $abInfo->affiliate_banners_id . '&action=new') . '">' . olc_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . olc_href_link(FILENAME_AFFILIATE_BANNER_MANAGER, 'page=' . $_GET['page'] . '&abID=' . $abInfo->affiliate_banners_id . '&action=delete') . '">' . olc_image_button('button_delete.gif', IMAGE_DELETE) . HTML_A_END); $contents[] = array('text' => $product_description['products_name']); $contents[] = array('text' => HTML_BR . TEXT_BANNERS_DATE_ADDED . BLANK . olc_date_short($abInfo->affiliate_date_added)); $contents[] = array('text' => '' . sprintf(TEXT_BANNERS_STATUS_CHANGE, olc_date_short($abInfo->affiliate_date_status_change))); } break; } if (olc_not_null($heading) && olc_not_null($contents)) { echo ' <td width="25%" valign="top">' . NEW_LINE; $box = new box(); echo $box->infoBox($heading, $contents); echo ' </td>' . NEW_LINE; } ?> </tr> </table></td>
</table></td> <?php $heading = array(); $contents = array(); switch ($_GET['action']) { case 'delete': $heading[] = array('text' => HTML_B_START . TEXT_INFO_HEADING_DELETE_REVIEW . HTML_B_END); $contents = array('form' => olc_draw_form('reviews', FILENAME_REVIEWS, 'page=' . $_GET['page'] . '&rID=' . $rInfo->reviews_id . '&action=deleteconfirm')); $contents[] = array('text' => TEXT_INFO_DELETE_REVIEW_INTRO); $contents[] = array('text' => '<br/><b>' . $rInfo->products_name . HTML_B_END); $contents[] = array('align' => 'center', 'text' => HTML_BR . olc_image_submit('button_delete.gif', IMAGE_DELETE) . BLANK . HTML_A_START . olc_href_link(FILENAME_REVIEWS, 'page=' . $_GET['page'] . '&rID=' . $rInfo->reviews_id) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END); break; default: if (is_object($rInfo)) { $heading[] = array('text' => HTML_B_START . $rInfo->products_name . HTML_B_END); $contents[] = array('align' => 'center', 'text' => HTML_A_START . olc_href_link(FILENAME_REVIEWS, 'page=' . $_GET['page'] . '&rID=' . $rInfo->reviews_id . '&action=edit') . '">' . olc_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . olc_href_link(FILENAME_REVIEWS, 'page=' . $_GET['page'] . '&rID=' . $rInfo->reviews_id . '&action=delete') . '">' . olc_image_button('button_delete.gif', IMAGE_DELETE) . HTML_A_END); $contents[] = array('text' => HTML_BR . TEXT_INFO_DATE_ADDED . BLANK . olc_date_short($rInfo->date_added)); if (olc_not_null($rInfo->last_modified)) { $contents[] = array('text' => TEXT_INFO_LAST_MODIFIED . BLANK . olc_date_short($rInfo->last_modified)); } $contents[] = array('text' => HTML_BR . olc_info_image($rInfo->products_image, $rInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)); $contents[] = array('text' => HTML_BR . TEXT_INFO_REVIEW_AUTHOR . BLANK . $rInfo->customers_name); $contents[] = array('text' => TEXT_INFO_REVIEW_RATING . BLANK . olc_image(DIR_WS_CATALOG_IMAGES . 'stars_' . $rInfo->reviews_rating . '.gif')); $contents[] = array('text' => TEXT_INFO_REVIEW_READ . BLANK . $rInfo->reviews_read); $contents[] = array('text' => HTML_BR . TEXT_INFO_REVIEW_SIZE . BLANK . $rInfo->reviews_text_size . ' bytes'); $contents[] = array('text' => HTML_BR . TEXT_INFO_PRODUCTS_AVERAGE_RATING . BLANK . number_format($rInfo->average_rating, 2) . '%'); } break; } if (olc_not_null($heading) && olc_not_null($contents)) { echo ' <td width="25%" valign="top">' . NEW_LINE;