$address_content .= '' . "\n"; } else { $address_content .= '' . "\n"; } $address_content .= '<p><span class="bold">' . $addresses['firstname'] . ' ' . $addresses['secondname'] . ' ' . $addresses['lastname'] . '</span> ' . vam_draw_radio_field('address', $addresses['address_book_id'], $addresses['address_book_id'] == $_SESSION['billto']) . '</p> <p>' . vam_address_format($format_id, $addresses, true, ' ', ', ') . '</p>'; $radio_buttons++; } $address_content .= ''; $vamTemplate->assign('BLOCK_ADDRESS', $address_content); } } if ($addresses_count < MAX_ADDRESS_BOOK_ENTRIES) { require DIR_WS_MODULES . 'checkout_new_address.php'; } $vamTemplate->assign('BUTTON_CONTINUE', vam_draw_hidden_field('action', 'submit') . vam_image_submit('submit.png', IMAGE_BUTTON_CONTINUE)); if ($process == true) { $vamTemplate->assign('BUTTON_BACK', '<a class="button" href="' . vam_href_link(FILENAME_CHECKOUT_PAYMENT_ADDRESS, '', 'SSL') . '">' . vam_image_button('back.png', IMAGE_BUTTON_BACK) . '</a>'); } $vamTemplate->assign('FORM_END', '</form>'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/checkout_payment_address.html'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->assign('main_content', $main_content); $vamTemplate->caching = 0; if (!defined(RM)) { $vamTemplate->load_filter('output', 'note'); } $template = file_exists('templates/' . CURRENT_TEMPLATE . '/' . FILENAME_CHECKOUT_PAYMENT_ADDRESS . '.html') ? CURRENT_TEMPLATE . '/' . FILENAME_CHECKOUT_PAYMENT_ADDRESS . '.html' : CURRENT_TEMPLATE . '/index.html'; $vamTemplate->display($template);
$vamTemplate->assign('PERSONAL_MESSAGE', sprintf(PERSONAL_MESSAGE, $gv_result['customers_firstname'])); $vamTemplate->assign('POST_MESSAGE', stripslashes($_POST['message'])); } $vamTemplate->assign('HIDDEN_FIELDS', vam_draw_hidden_field('send_name', $send_name) . vam_draw_hidden_field('to_name', stripslashes($_POST['to_name'])) . vam_draw_hidden_field('email', $_POST['email']) . vam_draw_hidden_field('amount', $gv_amount) . vam_draw_hidden_field('message', stripslashes($_POST['message']))); $vamTemplate->assign('LINK_BACK', vam_image_submit('back.png', IMAGE_BUTTON_BACK, 'name=back') . '</a>'); $vamTemplate->assign('LINK_SUBMIT', vam_image_submit('submit.png', IMAGE_BUTTON_CONTINUE)); } elseif ($_GET['action'] == '' || $error) { $vamTemplate->assign('action', ''); $vamTemplate->assign('FORM_ACTION', '<form action="' . vam_href_link(FILENAME_GV_SEND, 'action=send', 'NONSSL') . '" method="post">'); $vamTemplate->assign('LINK_SEND', vam_href_link(FILENAME_GV_SEND, 'action=send', 'NONSSL')); $vamTemplate->assign('INPUT_TO_NAME', vam_draw_input_field('to_name', stripslashes($_POST['to_name']))); $vamTemplate->assign('INPUT_EMAIL', vam_draw_input_field('email', $_POST['email'])); $vamTemplate->assign('ERROR_EMAIL', $error_email); $vamTemplate->assign('INPUT_AMOUNT', vam_draw_input_field('amount', $_POST['amount'], '', 'text', false)); $vamTemplate->assign('ERROR_AMOUNT', $error_amount); $vamTemplate->assign('TEXTAREA_MESSAGE', vam_draw_textarea_field('message', 'soft', 50, 15, stripslashes($_POST['message']))); $vamTemplate->assign('LINK_SUBMIT', vam_image_submit('submit.png', IMAGE_BUTTON_CONTINUE)); } $vamTemplate->assign('FORM_END', '</form>'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/gv_send.html'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->assign('main_content', $main_content); $vamTemplate->caching = 0; if (!defined(RM)) { $vamTemplate->load_filter('output', 'note'); } $template = file_exists('templates/' . CURRENT_TEMPLATE . '/' . FILENAME_GV_SEND . '.html') ? CURRENT_TEMPLATE . '/' . FILENAME_GV_SEND . '.html' : CURRENT_TEMPLATE . '/index.html'; $vamTemplate->display($template); include 'includes/application_bottom.php';
} if (vam_not_null($order->info['comments'])) { $vamTemplate->assign('ORDER_COMMENTS', nl2br(htmlspecialchars($order->info['comments'])) . vam_draw_hidden_field('comments', $order->info['comments'])); } if (isset(${$_SESSION}['payment']->form_action_url) && !${$_SESSION}['payment']->tmpOrders) { $form_action_url = ${$_SESSION}['payment']->form_action_url; } else { $form_action_url = vam_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL'); } $vamTemplate->assign('CHECKOUT_FORM', vam_draw_form('checkout_confirmation', $form_action_url, 'post')); $payment_button = ''; if (is_array($payment_modules->modules)) { $payment_button .= $payment_modules->process_button(); } $vamTemplate->assign('MODULE_BUTTONS', $payment_button); $vamTemplate->assign('CHECKOUT_BUTTON', vam_image_submit('submit.png', IMAGE_BUTTON_CONFIRM_ORDER) . '</form>' . "\n"); //check if display conditions on checkout page is true if (DISPLAY_REVOCATION_ON_CHECKOUT == 'true') { if (GROUP_CHECK == 'true') { $group_check = "and group_ids LIKE '%c_" . $_SESSION['customers_status']['customers_status_id'] . "_group%'"; } $shop_content_query = "SELECT\r\n\t\t content_title,\r\n\t\t content_heading,\r\n\t\t content_text,\r\n\t\t content_file\r\n\t\t FROM " . TABLE_CONTENT_MANAGER . "\r\n\t\t WHERE content_group='" . REVOCATION_ID . "' " . $group_check . "\r\n\t\t AND languages_id='" . $_SESSION['languages_id'] . "'"; $shop_content_query = vam_db_query($shop_content_query); $shop_content_data = vam_db_fetch_array($shop_content_query); if ($shop_content_data['content_file'] != '') { ob_start(); if (strpos($shop_content_data['content_file'], '.txt')) { echo '<pre>'; } include DIR_FS_CATALOG . 'media/content/' . $shop_content_data['content_file']; if (strpos($shop_content_data['content_file'], '.txt')) {
require DIR_WS_INCLUDES . 'header.php'; if (!$product->isProduct()) { $vamTemplate->assign('error', ERROR_INVALID_PRODUCT); } else { $name = $customer_info['customers_firstname'] . ' ' . $customer_info['customers_lastname']; if ($name == ' ') { $customer_info['customers_lastname'] = TEXT_GUEST; } $vamTemplate->assign('PRODUCTS_NAME', $product->data['products_name']); $vamTemplate->assign('AUTHOR', $customer_info['customers_firstname'] . ' ' . $customer_info['customers_lastname']); $vamTemplate->assign('INPUT_TEXT', vam_draw_textarea_field('review', 'soft', 60, 15, $_POST['review'], '', false)); $input_rationg = '<td>' . vam_draw_radio_field('rating', '1') . '<br/><b>1</b></td><td>' . vam_draw_radio_field('rating', '2') . '<br/><b>2</b></td><td>' . vam_draw_radio_field('rating', '3') . '<br/><b>3</b></td><td>' . vam_draw_radio_field('rating', '4') . '<br/><b>4</b></td><td>' . vam_draw_radio_field('rating', '5') . '<br/><b>5</b></td>'; $vamTemplate->assign('INPUT_RATING', $input_rationg); $vamTemplate->assign('FORM_ACTION', vam_draw_form('product_reviews_write', vam_href_link(FILENAME_PRODUCT_REVIEWS_WRITE, 'action=process&' . vam_product_link($product->data['products_id'], $product->data['products_name'])), 'post', 'onsubmit="return checkForm();"')); $vamTemplate->assign('BUTTON_BACK', '<a class="button" href="javascript:history.back(1)">' . vam_image_button('back.png', IMAGE_BUTTON_BACK) . '</a>'); $vamTemplate->assign('BUTTON_SUBMIT', vam_image_submit('submit.png', IMAGE_BUTTON_CONTINUE) . vam_draw_hidden_field('get_params', $get_params)); $vamTemplate->assign('CAPTCHA_IMG', '<img src="' . vam_href_link(FILENAME_DISPLAY_CAPTCHA) . '" alt="captcha" name="captcha" />'); $vamTemplate->assign('CAPTCHA_INPUT', vam_draw_input_field('captcha', '', 'size="6"', 'text', false)); $vamTemplate->assign('FORM_END', '</form>'); } $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/product_reviews_write.html'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->assign('main_content', $main_content); $vamTemplate->caching = 0; if (!defined(RM)) { $vamTemplate->load_filter('output', 'note'); } $template = file_exists('templates/' . CURRENT_TEMPLATE . '/' . FILENAME_PRODUCT_REVIEWS_WRITE . '.html') ? CURRENT_TEMPLATE . '/' . FILENAME_PRODUCT_REVIEWS_WRITE . '.html' : CURRENT_TEMPLATE . '/index.html'; $vamTemplate->display($template);
---------------------------------------------------------------------------------------*/ include 'includes/application_top.php'; // create template elements $vamTemplate = new vamTemplate(); // include boxes require DIR_FS_CATALOG . 'templates/' . CURRENT_TEMPLATE . '/source/boxes.php'; // include needed functions require_once DIR_FS_INC . 'vam_get_categories.inc.php'; require_once DIR_FS_INC . 'vam_get_manufacturers.inc.php'; require_once DIR_FS_INC . 'vam_checkdate.inc.php'; $breadcrumb->add(NAVBAR_TITLE_ADVANCED_SEARCH, vam_href_link(FILENAME_ADVANCED_SEARCH)); require DIR_WS_INCLUDES . 'header.php'; $vamTemplate->assign('FORM_ACTION', vam_draw_form('advanced_search', vam_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false), 'get', 'onsubmit="return check_form(this);"') . vam_hide_session_id()); $vamTemplate->assign('INPUT_KEYWORDS', vam_draw_input_field('keywords', '', '')); $vamTemplate->assign('HELP_LINK', 'javascript:popupWindow(\'' . vam_href_link(FILENAME_POPUP_SEARCH_HELP) . '\')'); $vamTemplate->assign('BUTTON_SUBMIT', vam_image_submit('search.png', IMAGE_BUTTON_SEARCH)); $vamTemplate->assign('SELECT_CATEGORIES', vam_draw_pull_down_menu('categories_id', vam_get_categories(array(array('id' => '', 'text' => TEXT_ALL_CATEGORIES))))); $vamTemplate->assign('ENTRY_SUBCAT', vam_draw_checkbox_field('inc_subcat', '1', true)); $vamTemplate->assign('SELECT_MANUFACTURERS', vam_draw_pull_down_menu('manufacturers_id', vam_get_manufacturers(array(array('id' => '', 'text' => TEXT_ALL_MANUFACTURERS))))); $vamTemplate->assign('SELECT_PFROM', vam_draw_input_field('pfrom')); $vamTemplate->assign('SELECT_PTO', vam_draw_input_field('pto')); $error = ''; if (isset($_GET['errorno'])) { if (($_GET['errorno'] & 1) == 1) { $error .= str_replace('\\n', '<br />', JS_AT_LEAST_ONE_INPUT); } if (($_GET['errorno'] & 10) == 10) { $error .= str_replace('\\n', '<br />', JS_INVALID_FROM_DATE); } if (($_GET['errorno'] & 100) == 100) { $error .= str_replace('\\n', '<br />', JS_INVALID_TO_DATE);
$gift->assign('ACTIVATE_GIFT', 'true'); } if (isset($_SESSION['customer_id'])) { $gv_query = vam_db_query("select amount from " . TABLE_COUPON_GV_CUSTOMER . " where customer_id = '" . $_SESSION['customer_id'] . "'"); $gv_result = vam_db_fetch_array($gv_query); if ($gv_result['amount'] > 0) { $gift->assign('GV_AMOUNT', $vamPrice->Format($gv_result['amount'], true, 0, true)); $gift->assign('GV_SEND_TO_FRIEND_LINK', vam_href_link(FILENAME_GV_SEND)); } else { $gift->assign('GV_AMOUNT', 0); } } if (isset($_SESSION['gv_id'])) { $gv_query = vam_db_query("select coupon_amount from " . TABLE_COUPONS . " where coupon_id = '" . $_SESSION['gv_id'] . "'"); $coupon = vam_db_fetch_array($gv_query); $gift->assign('COUPON_AMOUNT2', $vamPrice->Format($coupon['coupon_amount'], true, 0, true)); } if (isset($_SESSION['cc_id'])) { $gift->assign('COUPON_HELP_LINK', '<a style="cursor: pointer" onclick="javascript:window.open(\'' . vam_href_link(FILENAME_POPUP_COUPON_HELP, 'cID=' . $_SESSION['cc_id']) . '\', \'popup\', \'toolbar=0,scrollbars=yes, width=350, height=350\')">'); } if (isset($_SESSION['customer_id'])) { $gift->assign('C_FLAG', 'true'); } $gift->assign('LINK_ACCOUNT', vam_href_link(FILENAME_CREATE_ACCOUNT)); $gift->assign('FORM_ACTION', vam_draw_form('gift_coupon', vam_href_link(FILENAME_SHOPPING_CART, 'action=check_gift', 'NONSSL'))); $gift->assign('INPUT_CODE', vam_draw_input_field('gv_redeem_code')); $gift->assign('BUTTON_SUBMIT', vam_image_submit('submit.png', IMAGE_REDEEM_GIFT)); $gift->assign('language', $_SESSION['language']); $gift->assign('FORM_END', '</form>'); $gift->caching = 0; $vamTemplate->assign('MODULE_gift_cart', $gift->fetch(CURRENT_TEMPLATE . '/module/gift_cart.html'));
function vam_get_filter_string($display_type, $filters_select_array, $target, $filter_name, $filter_value) { $filter_name = (string) $filter_name; if (is_array($filter_value)) { } else { $filter_value = (string) $filter_value; } $exclude_array = array($filter_name, 'page'); $additional_variables = vam_get_hidden_get_variables($exclude_array); $box_text = ''; switch ($display_type) { case 'pulldown': $box_text .= vam_draw_form('filter', $target, 'get'); $box_text .= vam_draw_pull_down_menu($filter_name, $filters_select_array, $filter_value, 'onChange="this.form.submit();"'); $box_text .= $additional_variables . vam_hide_session_id(); $box_text .= '<noscript>' . vam_image_submit('submit.png', TEXT_FIND_PRODUCTS) . '</noscript>'; $box_text .= '</form>'; break; case 'radio': $box_text .= vam_draw_form('filter', $target, 'get'); foreach ($filters_select_array as $filter) { $checked = $filter['id'] == $filter_value ? true : false; switch (true) { case $filter['count'] != '' && $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'none': break; case $filter['count'] != '' && $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'grey': /* $box_text .= '<input type="radio" name="0" value="0" disabled="disabled">'; $box_text .= '<span class="no_results">' . ' '; $box_text .= vam_output_string ($filter['text'] ); $box_text .= '</span>'; if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True' && $filter['count'] != '') { $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>'; } $box_text .= '<br>' . "\n"; */ break; default: $box_text .= vam_draw_radio_field($filter_name, $filter['id'], $checked, 'onClick="this.form.submit();"') . ' ' . $filter['text']; if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True' && $filter['count'] != '') { $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>'; } $box_text .= '<br>' . "\n"; break; } // switch (true) } $box_text .= $additional_variables . vam_hide_session_id(); $box_text .= '<noscript>' . vam_image_submit('submit.png', TEXT_FIND_PRODUCTS) . '</noscript>'; $box_text .= '</form>'; break; case 'text': $value = $filter_value != 0 ? $filter_value : ''; $box_text .= vam_draw_form('filter', $target, 'get'); //$box_text .= vam_draw_input_field($filter_name, $value); $box_text .= vam_draw_input_price_slider($filter_name, $value); $box_text .= $additional_variables . vam_hide_session_id(); //$box_text .= '<noscript>' . vam_image_submit('submit.png', TEXT_FIND_PRODUCTS) . '</noscript>'; $box_text .= '</form>'; break; case 'multi': $box_text .= vam_draw_form('filter', $target, 'get'); $box_text .= vam_draw_multi_pull_down_menu($filter_name . '[]', $filters_select_array, $filter_value, 'multiple="' . $filter_name . 'f"'); $box_text .= $additional_variables . vam_hide_session_id(); $box_text .= vam_image_submit('submit.png', TEXT_FIND_PRODUCTS); $box_text .= '</form>'; break; case 'checkbox': $box_text .= vam_draw_form('filter', $target, 'get'); $checkbox_id = 0; foreach ($filters_select_array as $filter) { $checked = $filter['id'] == $filter_value[$checkbox_id] ? true : false; switch (true) { case $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'none': break; case $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'grey': /* $box_text .= '<input type="checkbox" name="0" value="0" disabled="disabled">'; $box_text .= '<span class="no_results">' . ' '; $box_text .= vam_output_string ($filter['text'] ); $box_text .= '</span>'; if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True') { $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>'; } $box_text .= '<br>' . "\n"; */ break; default: $box_text .= vam_draw_checkbox_field($filter_name . '[' . $checkbox_id . ']', $filter['id'], $checked, 'onclick="this.form.submit();"') . ' ' . $filter['text']; if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True') { $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>'; } $box_text .= '<br>' . "\n"; break; } // switch (true) $checkbox_id++; } $box_text .= $additional_variables . vam_hide_session_id(); //$box_text .= vam_image_submit('submit.png', TEXT_FIND_PRODUCTS); $box_text .= '</form>'; break; case 'image': $value = $filter_value != 0 ? $filter_value : ''; $box_text .= vam_draw_images_menu($filter_name, $filters_select_array, $target, $value); break; case 'multiimage': $box_text .= vam_draw_form('filter', $target, 'get'); foreach ($filters_select_array as $filter) { $checked = $filter['id'] == $filter_value[$checkbox_id] ? true : false; $box_text .= vam_draw_checkbox_field($filter_name . '[' . $checkbox_id . ']', $filter['id'], $checked); $box_text .= ' ' . vam_image(DIR_WS_IMAGES . trim($filter['text']), $filter['text']) . '<br>' . "\n"; $box_text .= '<br>' . "\n"; $checkbox_id++; } $box_text .= $additional_variables . vam_hide_session_id(); $box_text .= vam_image_submit('submit.png', TEXT_FIND_PRODUCTS); $box_text .= '</form>'; break; case 'links': default: $box_text .= vam_draw_links_menu($filter_name, $filters_select_array, $target, $filter_value); break; } // switch ($display_type return $box_text; }
$vamTemplate->assign('text_heading', HEADING_PASSWORD_FORGOTTEN); $vamTemplate->assign('info_message', $info_message); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/password_messages.html'); break; case double_opt: $vamTemplate->assign('CAPTCHA_IMG', '<img src="' . vam_href_link(FILENAME_DISPLAY_CAPTCHA) . '" alt="captcha" />'); $vamTemplate->assign('CAPTCHA_INPUT', vam_draw_input_field('captcha', '', 'size="6"', 'text', false)); $vamTemplate->assign('text_heading', HEADING_PASSWORD_FORGOTTEN); // $vamTemplate->assign('info_message', $info_message); $vamTemplate->assign('message', TEXT_PASSWORD_FORGOTTEN); $vamTemplate->assign('SHOP_NAME', STORE_NAME); $vamTemplate->assign('FORM_ACTION', vam_draw_form('sign', vam_href_link(FILENAME_PASSWORD_DOUBLE_OPT, 'action=first_opt_in', 'NONSSL'))); $vamTemplate->assign('INPUT_EMAIL', vam_draw_input_field('email', vam_db_input($_POST['email']))); $vamTemplate->assign('BUTTON_SEND', vam_image_submit('submit.png', IMAGE_BUTTON_LOGIN)); $vamTemplate->assign('FORM_END', '</form>'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/password_double_opt_in.html'); break; } $vamTemplate->assign('main_content', $main_content); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; if (!defined(RM)) { $vamTemplate->load_filter('output', 'note'); } $template = file_exists('templates/' . CURRENT_TEMPLATE . '/' . FILENAME_PASSWORD_DOUBLE_OPT . '.html') ? CURRENT_TEMPLATE . '/' . FILENAME_PASSWORD_DOUBLE_OPT . '.html' : CURRENT_TEMPLATE . '/index.html'; $vamTemplate->display($template); include 'includes/application_bottom.php';
$module->assign('CATEGORIES_NAME', $category['categories_name']); $module->assign('CATEGORIES_HEADING_TITLE', $category['categories_heading_title']); $module->assign('CATEGORIES_IMAGE', $image); $module->assign('CATEGORIES_DESCRIPTION', $category['categories_description']); $query = "SELECT manufacturers_description FROM " . TABLE_MANUFACTURERS_INFO . " where manufacturers_id = '" . (int) $_GET['manufacturers_id'] . "' and languages_id = '" . $_SESSION['languages_id'] . "'"; $open_query = vamDBquery($query); $open_data = vam_db_fetch_array($open_query, true); $manufacturers_description = $open_data["manufacturers_description"]; $module->assign('MANUFACTURERS_DESCRIPTION', $manufacturers_description); $rows = 0; $listing_query = vamDBquery($listing_split->sql_query); while ($listing = vam_db_fetch_array($listing_query, true)) { $rows++; $module_content[] = $product->buildDataArray($listing); } $module->assign('BUTTON_COMPARE', vam_image_submit('view.png', TEXT_PRODUCT_COMPARE)); } else { // no product found $result = false; } // get default template if ($category['listing_template'] == '' or $category['listing_template'] == 'default') { $files = array(); if ($dir = opendir(DIR_FS_CATALOG . 'templates/' . CURRENT_TEMPLATE . '/module/product_listing/')) { while (($file = readdir($dir)) !== false) { if (is_file(DIR_FS_CATALOG . 'templates/' . CURRENT_TEMPLATE . '/module/product_listing/' . $file) and $file != "index.html" and substr($file, 0, 1) != ".") { $files[] = array('id' => $file, 'text' => $file); } //if } // while
Released under the GNU General Public License ---------------------------------------------------------------------------------------*/ $module = new vamTemplate(); $module->assign('tpl_path', 'templates/' . CURRENT_TEMPLATE . '/'); if (GROUP_CHECK == 'true') { $group_check = "and c.group_permission_" . $_SESSION['customers_status']['customers_status_id'] . "=1 "; } $category_query = "select\n cd.categories_description,\n cd.categories_name,\n cd.categories_heading_title, \n c.categories_template,\n c.categories_image from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd\n where c.categories_id = '" . $current_category_id . "'\n and cd.categories_id = '" . $current_category_id . "'\n " . $group_check . "\n and cd.language_id = '" . (int) $_SESSION['languages_id'] . "'"; $category_query = vamDBquery($category_query); $category = vam_db_fetch_array($category_query, true); $module->assign('CATEGORIES_NAME', $category['categories_name']); $module->assign('CATEGORIES_DESCRIPTION', $category['categories_description']); $module->assign('language', $_SESSION['language']); $module->assign('ERROR', $error); $module->assign('BUTTON', '<a class="button" href="javascript:history.back(1)">' . vam_image_button('back.png', IMAGE_BUTTON_CONTINUE) . '</a>'); $module->assign('language', $_SESSION['language']); // search field $module->assign('FORM_ACTION', vam_draw_form('new_find', vam_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false), 'get') . vam_hide_session_id()); $module->assign('INPUT_SEARCH', vam_draw_input_field('keywords', '', 'size="30" maxlength="30"')); $module->assign('BUTTON_SUBMIT', vam_image_submit('search.png', BOX_HEADING_SEARCH)); $module->assign('LINK_ADVANCED', vam_href_link(FILENAME_ADVANCED_SEARCH)); $module->assign('FORM_END', '</form>'); $module->caching = 0; $module->caching = 0; $module = $module->fetch(CURRENT_TEMPLATE . '/module/error_message.html'); if (strstr($PHP_SELF, FILENAME_PRODUCT_INFO)) { $product_info = $module; } $vamTemplate->assign('main_content', $module); //header('HTTP/1.0 404 Not Found');
$vamTemplate->assign('telephone', '1'); $vamTemplate->assign('INPUT_TEL', vam_draw_input_fieldNote(array('name' => 'telephone', 'text' => ' ' . (vam_not_null(ENTRY_TELEPHONE_NUMBER_TEXT) ? '<span class="Requirement">' . ENTRY_TELEPHONE_NUMBER_TEXT . '</span>' : '')), '', 'id="telephone"')); } else { $vamTemplate->assign('telephone', '0'); } if (ACCOUNT_FAX == 'true') { $vamTemplate->assign('fax', '1'); $vamTemplate->assign('INPUT_FAX', vam_draw_input_fieldNote(array('name' => 'fax', 'text' => ' ' . (vam_not_null(ENTRY_FAX_NUMBER_TEXT) ? '<span class="Requirement">' . ENTRY_FAX_NUMBER_TEXT . '</span>' : '')))); } else { $vamTemplate->assign('fax', '0'); } $vamTemplate->assign('customers_extra_fileds', '1'); $vamTemplate->assign('INPUT_CUSTOMERS_EXTRA_FIELDS', vam_get_extra_fields($_SESSION['customer_id'], $_SESSION['languages_id'])); $vamTemplate->assign('CAPTCHA_IMG', vam_image(HTTP_SERVER . DIR_WS_CATALOG . FILENAME_DISPLAY_CAPTCHA, 'captcha', '', '', 'name="captcha" ')); $vamTemplate->assign('CAPTCHA_INPUT', vam_draw_input_field('captcha', '', 'size="6" maxlength="6"', 'text', false)); $vamTemplate->assign('INPUT_PASSWORD', vam_draw_password_fieldNote(array('name' => 'password', 'text' => ' ' . (vam_not_null(ENTRY_PASSWORD_TEXT) ? '<span class="Requirement">' . ENTRY_PASSWORD_TEXT . '</span>' : '')), '', 'id="pass"')); $vamTemplate->assign('INPUT_CONFIRMATION', vam_draw_password_fieldNote(array('name' => 'confirmation', 'text' => ' ' . (vam_not_null(ENTRY_PASSWORD_CONFIRMATION_TEXT) ? '<span class="Requirement">' . ENTRY_PASSWORD_CONFIRMATION_TEXT . '</span>' : '')), '', 'id="confirmation"')); $vamTemplate->assign('FORM_END', '</form>'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $vamTemplate->assign('BUTTON_SUBMIT', vam_image_submit('', IMAGE_BUTTON_REGISTER)); $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/create_account.html'); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->assign('main_content', $main_content); $vamTemplate->caching = 0; if (!defined(RM)) { $vamTemplate->load_filter('output', 'note'); } $template = file_exists('templates/' . CURRENT_TEMPLATE . '/' . FILENAME_CREATE_ACCOUNT . '.html') ? CURRENT_TEMPLATE . '/' . FILENAME_CREATE_ACCOUNT . '.html' : CURRENT_TEMPLATE . '/index.html'; $vamTemplate->display($template); include 'includes/application_bottom.php';
$date_now = date('Ymd'); vam_db_query("update " . TABLE_AFFILIATE . " set affiliate_date_of_last_logon = now(), affiliate_number_of_logons = affiliate_number_of_logons + 1 where affiliate_id = '" . $_SESSION['affiliate_id'] . "'"); vam_redirect(vam_href_link(FILENAME_AFFILIATE_SUMMARY, '', 'SSL')); } } } $breadcrumb->add(NAVBAR_TITLE, vam_href_link(FILENAME_AFFILIATE, '', 'SSL')); require DIR_WS_INCLUDES . 'header.php'; if (isset($_GET['login']) && $_GET['login'] == 'fail') { $info_message = 'true'; } else { $info_message = 'false'; } $vamTemplate->assign('info_message', $info_message); $vamTemplate->assign('FORM_ACTION', vam_draw_form('login', vam_href_link(FILENAME_AFFILIATE, 'action=process', 'SSL'))); $vamTemplate->assign('LINK_TERMS', '<a href="' . vam_href_link(FILENAME_CONTENT, 'coID=9', 'SSL') . '">'); $vamTemplate->assign('INPUT_AFFILIATE_USERNAME', vam_draw_input_field('affiliate_username')); $vamTemplate->assign('INPUT_AFFILIATE_PASSWORD', vam_draw_password_field('affiliate_password')); $vamTemplate->assign('LINK_PASSWORD_FORGOTTEN', '<a href="' . vam_href_link(FILENAME_AFFILIATE_PASSWORD_FORGOTTEN, '', 'SSL') . '">'); $vamTemplate->assign('LINK_SIGNUP', '<a class="button" href="' . vam_href_link(FILENAME_AFFILIATE_SIGNUP, '', 'SSL') . '">' . vam_image_button('submit.png', IMAGE_BUTTON_CONTINUE) . '</a>'); $vamTemplate->assign('BUTTON_LOGIN', vam_image_submit('login.png', IMAGE_BUTTON_LOGIN)); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; $main_content = $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/affiliate_affiliate.html'); $vamTemplate->assign('main_content', $main_content); $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; if (!defined(RM)) { $vamTemplate->load_filter('output', 'note'); } $vamTemplate->display(CURRENT_TEMPLATE . '/index.html');
} vam_db_query("update " . TABLE_PRODUCTS_DESCRIPTION . " set products_viewed = products_viewed+1 where products_id = '" . $product->data['products_id'] . "' and language_id = '" . $_SESSION['languages_id'] . "'"); $products_price = $vamPrice->GetPrice($product->data['products_id'], $format = true, 1, $product->data['products_tax_class_id'], $product->data['products_price'], 1); //$products_price_old = $vamPrice->getOldPrice($vamPrice->getPprice($product->data['products_id']), $format = true); // check if customer is allowed to add to cart if ($_SESSION['customers_status']['customers_status_show_price'] != '0') { // fsk18 if ($_SESSION['customers_status']['customers_fsk18'] == '1') { if ($product->data['products_fsk18'] == '0') { $info->assign('ADD_QTY', vam_draw_input_field('products_qty', '1', 'size="3"') . ' ' . vam_draw_hidden_field('products_id', $product->data['products_id'])); //$info->assign('ADD_CART_BUTTON', vam_image_submit('buy.png', IMAGE_BUTTON_IN_CART, 'id="add_to_cart"')); $info->assign('ADD_CART_BUTTON', '<button type="submit" id="add_to_cart">'); } } else { $info->assign('ADD_QTY', vam_draw_input_field('products_qty', '1', 'size="3"') . ' ' . vam_draw_hidden_field('products_id', $product->data['products_id'])); $info->assign('ADD_CART_BUTTON', vam_image_submit('buy.png', IMAGE_BUTTON_IN_CART, 'id="add_to_cart"')); } } if ($product->data['products_fsk18'] == '1') { $info->assign('PRODUCTS_FSK18', 'true'); } if (ACTIVATE_SHIPPING_STATUS == 'true') { $info->assign('SHIPPING_NAME', $main->getShippingStatusName($product->data['products_shippingtime'])); $info->assign('SHIPPING_IMAGE', $main->getShippingStatusImage($product->data['products_shippingtime'])); } if (AJAX_CART == 'true') { $info->assign('FORM_ACTION', vam_draw_form('cart_quantity', vam_href_link(FILENAME_PRODUCT_INFO, vam_get_all_get_params(array('action')) . 'action=add_product'), 'post', 'onsubmit="doAddProduct(this); return false;"')); } else { $info->assign('FORM_ACTION', vam_draw_form('cart_quantity', vam_href_link(FILENAME_PRODUCT_INFO, vam_get_all_get_params(array('action')) . 'action=add_product'))); } $info->assign('FORM_END', '</form>');
$state_input = vam_draw_pull_down_menuNote(array('name' => 'state', 'text' => ' ' . (vam_not_null(ENTRY_STATE_TEXT) ? '<span class="Requirement">' . ENTRY_STATE_TEXT . '</span>' : '')), $zones_array, vam_get_zone_name($entry['entry_country_id'], $entry['entry_zone_id'], $entry['entry_state']), ' id="state"'); } else { $state_input = vam_draw_input_fieldNote(array('name' => 'state', 'text' => ' ' . (vam_not_null(ENTRY_STATE_TEXT) ? '<span class="Requirement">' . ENTRY_STATE_TEXT . '</span>' : '')), vam_get_zone_name(STORE_COUNTRY, STORE_ZONE), ' id="state"'); } $module->assign('INPUT_STATE', $state_input); } else { $module->assign('state', '0'); } if ($_POST['country']) { $selected = $_POST['country']; } else { $selected = $entry['entry_country_id']; } if (ACCOUNT_COUNTRY == 'true') { $module->assign('country', '1'); if ($process == true) { $entry['entry_country_id'] = (int) $_POST['country']; } $module->assign('SELECT_COUNTRY', vam_get_country_list('country', $entry['entry_country_id'], 'id="country"') . (vam_not_null(ENTRY_COUNTRY_TEXT) ? '<span class="Requirement">' . ENTRY_COUNTRY_TEXT . '</span>' : '')); $module->assign('SELECT_COUNTRY_NOSCRIPT', '<noscript><br />' . vam_image_submit('update.png', IMAGE_BUTTON_UPDATE, 'name=loadStateXML') . '<br />' . ENTRY_STATE_RELOAD . '</noscript>'); } else { $vamTemplate->assign('country', '0'); } if (isset($_GET['edit']) && $_SESSION['customer_default_address_id'] != $_GET['edit'] || isset($_GET['edit']) == false) { $module->assign('new', '1'); $module->assign('CHECKBOX_PRIMARY', vam_draw_checkbox_field('primary', 'on', false, 'id="primary"')); } $module->assign('language', $_SESSION['language']); $module->caching = 0; $main_content = $module->fetch(CURRENT_TEMPLATE . '/module/address_book_details.html'); $vamTemplate->assign('MODULE_address_book_details', $main_content);
(c) 2000-2001 The Exchange Project (earlier name of osCommerce) (c) 2002-2003 osCommercebased on original files from OSCommerce CVS 2.2 2002/08/28 02:14:35 www.oscommerce.com (c) 2003 nextcommerce (loginbox.php,v 1.10 2003/08/17); www.nextcommerce.org (c) 2004 xt:Commerce (loginbox.php,v 1.10 2003/08/13); xt-commerce.com Released under the GNU General Public License ----------------------------------------------------------------------------------------- Third Party contributions: Loginbox V1.0 Aubrey Kilian <*****@*****.**> Released under the GNU General Public License ---------------------------------------------------------------------------------------*/ $box = new vamTemplate(); $box->assign('tpl_path', 'templates/' . CURRENT_TEMPLATE . '/'); $box_content = ''; require_once DIR_FS_INC . 'vam_image_submit.inc.php'; require_once DIR_FS_INC . 'vam_draw_password_field.inc.php'; if (!vam_session_is_registered('customer_id')) { $box->assign('FORM_ACTION', '<form id="loginbox" method="post" action="' . vam_href_link(FILENAME_LOGIN, 'action=process', 'SSL') . '">'); $box->assign('FIELD_EMAIL', vam_draw_input_field('email_address', '', '')); $box->assign('FIELD_PWD', vam_draw_password_field('password', '', '')); $box->assign('BUTTON', vam_image_submit('login.png', IMAGE_BUTTON_LOGIN)); $box->assign('LINK_LOST_PASSWORD', vam_href_link(FILENAME_PASSWORD_DOUBLE_OPT, '', 'SSL')); $box->assign('LINK_NEW_ACCOUNT', vam_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL')); $box->assign('FORM_END', '</form>'); $box->assign('BOX_CONTENT', $loginboxcontent); $box->caching = 0; $box->assign('language', $_SESSION['language']); $box_loginbox = $box->fetch(CURRENT_TEMPLATE . '/boxes/box_login.html'); $vamTemplate->assign('box_LOGIN', $box_loginbox); }
} if ($_SESSION['customers_status']['customers_status_max_order'] != 0) { if ($total > $_SESSION['customers_status']['customers_status_max_order']) { $_SESSION['allow_checkout'] = 'false'; $less_to_buy = $total - $_SESSION['customers_status']['customers_status_max_order']; $max_order = $vamPrice->Format($_SESSION['customers_status']['customers_status_max_order'], true); $order_amount = $vamPrice->Format($less_to_buy, true); $vamTemplate->assign('info_message_1', MAXIMUM_ORDER_VALUE_REACHED_1); $vamTemplate->assign('info_message_2', MAXIMUM_ORDER_VALUE_REACHED_2); $vamTemplate->assign('order_amount', $order_amount); $vamTemplate->assign('min_order', $max_order); } } } if ($_GET['info_message']) { $vamTemplate->assign('info_message', str_replace('+', ' ', htmlspecialchars($_GET['info_message']))); } $vamTemplate->assign('BUTTON_RELOAD', vam_image_submit('update.png', IMAGE_BUTTON_UPDATE_CART)); $vamTemplate->assign('BUTTON_CHECKOUT', '<a class="button" href="' . vam_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL') . '">' . vam_image_button('', IMAGE_BUTTON_CHECKOUT) . '</a>'); } else { // empty cart $cart_empty = true; if ($_GET['info_message']) { $vamTemplate->assign('info_message', str_replace('+', ' ', htmlspecialchars($_GET['info_message']))); } $vamTemplate->assign('cart_empty', $cart_empty); $vamTemplate->assign('BUTTON_CONTINUE', '<a class="button close" href="javascript:void(0);">' . vam_image_button('', IMAGE_BUTTON_CONTINUE) . '</a>'); } $vamTemplate->assign('language', $_SESSION['language']); $vamTemplate->caching = 0; echo $vamTemplate->fetch(CURRENT_TEMPLATE . '/module/shopping_cart.html');
(c) 2004 xt:Commerce (add_a_quickie.php,v 1.10 2003/08/13); xt-commerce.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 ---------------------------------------------------------------------------------------*/ // reset var $box = new vamTemplate(); $box_content = ''; $box->assign('tpl_path', 'templates/' . CURRENT_TEMPLATE . '/'); $box->assign('FORM_ACTION', '<form id="quick_add" method="post" action="' . vam_href_link(basename($PHP_SELF), vam_get_all_get_params(array('action')) . 'action=add_a_quickie', 'NONSSL') . '">'); $box->assign('INPUT_FIELD', vam_draw_input_field('quickie', '', 'id="quick_add_quickie"')); $box->assign('SUBMIT_BUTTON', vam_image_submit('search.png', BOX_HEADING_ADD_PRODUCT_ID)); $box->assign('FORM_END', '</form>'); $box->assign('BOX_CONTENT', $box_content); $box->assign('language', $_SESSION['language']); // set cache ID if (!CacheCheck()) { $box->caching = 0; $box_add_a_quickie = $box->fetch(CURRENT_TEMPLATE . '/boxes/box_add_a_quickie.html'); } else { $box->caching = 1; $box->cache_lifetime = CACHE_LIFETIME; $box->cache_modified_check = CACHE_CHECK; $cache_id = $_SESSION['language']; $box_add_a_quickie = $box->fetch(CURRENT_TEMPLATE . '/boxes/box_add_a_quickie.html', $cache_id); } $vamTemplate->assign('box_ADD_QUICKIE', $box_add_a_quickie);
based on: (c) 2000-2001 The Exchange Project (earlier name of osCommerce) (c) 2002-2003 osCommerce(search.php,v 1.22 2003/02/10); www.oscommerce.com (c) 2003 nextcommerce (search.php,v 1.9 2003/08/17); www.nextcommerce.org (c) 2004 xt:Commerce (search.php,v 1.9 2003/08/13); xt-commerce.com Released under the GNU General Public License ---------------------------------------------------------------------------------------*/ $box = new vamTemplate(); $box->assign('tpl_path', 'templates/' . CURRENT_TEMPLATE . '/'); $box_content = ''; require_once DIR_FS_INC . 'vam_image_submit.inc.php'; require_once DIR_FS_INC . 'vam_hide_session_id.inc.php'; $box->assign('FORM_ACTION', vam_draw_form('quick_find', vam_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false), 'get') . vam_hide_session_id()); $box->assign('INPUT_SEARCH', vam_draw_input_field('keywords', '', 'id="quick_find_keyword"')); $box->assign('BUTTON_SUBMIT', vam_image_submit('', IMAGE_BUTTON_SEARCH)); $box->assign('FORM_END', '</form>'); $box->assign('LINK_ADVANCED', vam_href_link(FILENAME_ADVANCED_SEARCH)); $box->assign('BOX_CONTENT', $box_content); $box->assign('language', $_SESSION['language']); // set cache ID if (!CacheCheck()) { $box->caching = 0; $box_search = $box->fetch(CURRENT_TEMPLATE . '/boxes/box_search.html'); } else { $box->caching = 1; $box->cache_lifetime = CACHE_LIFETIME; $box->cache_modified_check = CACHE_CHECK; $cache_id = $_SESSION['language']; $box_search = $box->fetch(CURRENT_TEMPLATE . '/boxes/box_search.html', $cache_id); }
// if the modules status was changed when none were available, to save on implementing // a javascript force-selection method, also automatically select the cheapest shipping // method if more than one module is now enabled if (!isset($_SESSION['shipping']) || isset($_SESSION['shipping']) && $_SESSION['shipping'] == false && vam_count_shipping_modules() > 1) { $_SESSION['shipping'] = $shipping_modules->cheapest(); } $breadcrumb->add(NAVBAR_TITLE_1_CHECKOUT_SHIPPING, vam_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')); $breadcrumb->add(NAVBAR_TITLE_2_CHECKOUT_SHIPPING, vam_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')); require DIR_WS_INCLUDES . 'header.php'; if (ACCOUNT_STREET_ADDRESS == 'true') { $vamTemplate->assign('SHIPPING_ADDRESS', 'true'); } $vamTemplate->assign('FORM_ACTION', vam_draw_form('checkout_address', vam_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')) . vam_draw_hidden_field('action', 'process')); $vamTemplate->assign('ADDRESS_LABEL', vam_address_label($_SESSION['customer_id'], $_SESSION['sendto'], true, ' ', '<br />')); $vamTemplate->assign('BUTTON_ADDRESS', '<a class="button" href="' . vam_href_link(FILENAME_CHECKOUT_SHIPPING_ADDRESS, '', 'SSL') . '">' . vam_image_button('edit.png', IMAGE_BUTTON_CHANGE_ADDRESS) . '</a>'); $vamTemplate->assign('BUTON_CONTINUE', vam_image_submit('submit.png', IMAGE_BUTTON_CONTINUE)); $vamTemplate->assign('FORM_END', '</form>'); $module = new vamTemplate(); if (vam_count_shipping_modules() > 0) { $showtax = $_SESSION['customers_status']['customers_status_show_price_tax']; $module->assign('FREE_SHIPPING', $free_shipping); # free shipping or not... if ($free_shipping == true) { $module->assign('FREE_SHIPPING_TITLE', FREE_SHIPPING_TITLE); $module->assign('FREE_SHIPPING_DESCRIPTION', sprintf(FREE_SHIPPING_DESCRIPTION, $vamPrice->Format(MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER, true, 0, true)) . vam_draw_hidden_field('shipping', 'free_free')); $module->assign('FREE_SHIPPING_ICON', ''); } else { $radio_buttons = 0; #loop through installed shipping methods... for ($i = 0, $n = sizeof($quotes); $i < $n; $i++) { if (!isset($quotes[$i]['error'])) {