Esempio n. 1
0
 function quote($method = '')
 {
     global $order, $shipping_weight, $shipping_num_boxes;
     if (!$order) {
         $order = new order();
         $shipping_weight = $_SESSION['cart']->show_weight();
     }
     $order_delivery_country = $order->delivery['country'];
     if (MODULE_SHIPPING_TABLE_MODE == 'price') {
         $order_total = $_SESSION['cart']->show_total();
     } else {
         $order_total = $shipping_weight;
     }
     $table_cost = split("[:,]", MODULE_SHIPPING_TABLE_COST);
     $size = sizeof($table_cost);
     for ($i = 0, $n = $size; $i < $n; $i += 2) {
         if ($order_total <= $table_cost[$i]) {
             $shipping = $table_cost[$i + 1];
             break;
         }
     }
     if (MODULE_SHIPPING_TABLE_MODE == 'weight') {
         $shipping = $shipping * $shipping_num_boxes;
     }
     $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_TABLE_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => MODULE_SHIPPING_TABLE_TEXT_WAY, 'cost' => $shipping + MODULE_SHIPPING_TABLE_HANDLING)));
     if ($this->tax_class > 0) {
         $this->quotes['tax'] = olc_get_tax_rate($this->tax_class, $order_delivery_country['id'], $order->delivery['zone_id']);
     }
     if (olc_not_null($this->icon)) {
         $this->quotes['icon'] = olc_image($this->icon, $this->title);
     }
     return $this->quotes;
 }
 function quote($method = '')
 {
     // W. Kaiser - Show missing amount for free shipping
     $CurrentAmount = $_SESSION['cart']->show_total();
     //	W. Kaiser - Free shipping national/international
     require_once DIR_FS_INC . 'olc_get_free_shipping_amount.inc.php';
     olc_get_free_shipping_amount();
     if (FREE_AMOUNT > 0) {
         $MissingAmount = FREE_AMOUNT - $CurrentAmount;
         if ($MissingAmount > 0 && MODULE_SHIPPING_FREECOUNT_DISPLAY == FALSE_STRING_L) {
             return;
         }
         //	W. Kaiser - Free shipping national/international
         $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_FREECOUNT_TEXT_TITLE);
         if ($MissingAmount > 0) {
             $this->quotes['error'] = MODULE_SHIPPING_FREECOUNT_TEXT_WAY . HTML_B_START . olc_format_price($MissingAmount, 1, 1, 1) . '</b>)';
         } else {
             $this->quotes['methods'] = array(array('id' => $this->code, 'title' => MODULE_SHIPPING_FREECOUNT_TEXT_WAY, 'cost' => 0));
             if (olc_not_null($this->icon)) {
                 $this->quotes['icon'] = olc_image($this->icon, $this->title);
             }
         }
     }
     return $this->quotes;
     //W. Kaiser - Show missing amount for free shippin
 }
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 olc_output_warning($warning, $force_errorBox = false)
{
    if (IS_AJAX_PROCESSING && !$force_errorBox) {
        ajax_error($warning, true);
    } else {
        new errorBox(array(array('text' => HTML_BR . olc_image(DIR_WS_ICONS . 'warning.gif', ICON_WARNING) . BLANK . $warning . '<br/><br/>')));
    }
}
 function quote($method = '')
 {
     $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_VERSANDMAIL_TEXT_TITLE);
     $this->quotes['methods'] = array(array('id' => $this->code, 'title' => MODULE_SHIPPING_VERSANDMAIL_TEXT_WAY, 'cost' => 0));
     if (olc_not_null($this->icon)) {
         $this->quotes['icon'] = olc_image($this->icon, $this->title);
     }
     return $this->quotes;
 }
function build_optional_image_html($i)
{
    global $pic_display_text0, $pic_table_text0, $pic_url_text, $pic_text, $onclick0, $sep, $use_multi_pic_text;
    global $multi_pictures, $pic_table0, $span_start, $thumbs_dir_local, $id_is, $dummy_span, $hidden_text, $end;
    global $original_dir_local, $thumbs_dir_local, $display_visible_text, $display_hidden_text, $pic_table0;
    global $dummy_span, $style_display, $fees, $rab, $div_tex, $onchange, $space;
    $next_i = $i + 1;
    //$index=UNDERSCORE.$i;
    $index = UNDERSCORE . $next_i;
    $my_pic_display_text = $pic_display_text0 . $index;
    $my_pic_table_text = $pic_table_text0 . $next_i;
    $my_pic_url_text = $pic_url_text . $index;
    $my_pic_text = $pic_text . $index;
    $my_use_multi_pic_text = $use_multi_pic_text . $next_i;
    $my_use_multi_pic_div_text = $my_use_multi_pic_text . $div_text;
    $not_last = $i < 12;
    $onclick = $onclick0 . $my_pic_table_text . $sep . $my_pic_url_text . $sep . $my_pic_text;
    if ($not_last) {
        //$onclick.=$sep.$my_use_multi_pic_text.$sep.TRUE_STRING_S;
        $next_i_1 = $next_i + 1;
        $onclick .= $sep . $use_multi_pic_text . $next_i_1 . $div_text . $sep . $next_i;
    }
    $onclick .= $end;
    if ($not_last) {
        $pic_file_name = $multi_pictures[$next_i];
        $use_multi_pic = $pic_file_name != EMPTY_STRING;
        $id = $id_is . $my_pic_text . QUOTE;
        if ($use_multi_pic) {
            $display = $display_visible_text;
            $my_image = olc_image($thumbs_dir_local . $pic_file_name, EMPTY_STRING, EMPTY_STRING, EMPTY_STRING, $id . QUOTE);
            $my_pic_file_name = DIR_WS_ORIGINAL_IMAGES . $pic_file_name;
        } else {
            $display = $display_hidden_text;
            $my_image = SPAN_START . $id . $rab . SPAN_END;
            $my_pic_file_name = EMPTY_STRING;
        }
        $pic_table = str_replace(UNDERSCORE, $display, $pic_table0);
        $pic_table = str_replace(TILDE, $my_pic_table_text, $pic_table);
        $image_html .= HTML_BR . olc_draw_file_field($my_pic_url_text, EMPTY_STRING, str_replace(HASH, $index, $onchange)) . HTML_BR . str_replace(HASH, $my_pic_display_text, $span_start) . $my_pic_file_name . SPAN_END;
        $image_html = str_replace(HASH, $image_html, $pic_table);
        $image_html = str_replace(ATSIGN, $space . $my_image . $dummy_span, $image_html) . olc_draw_hidden_field($my_pic_url_text . $hidden_text, $original_dir_local . $pic_file_name);
        if ($i == 1 || $use_multi_pic) {
            $display = $display_visible_text;
        } else {
            $display = $display_hidden_text;
        }
        $display = $style_display . $display . QUOTE;
        $image_html = '<div nowrap="nowrap"="nowrap" id="' . $my_use_multi_pic_div_text . QUOTE . BLANK . $display . $rab . HTML_BR . olc_draw_checkbox_field($my_use_multi_pic_text, ONE_STRING, $use_multi_pic, $onclick) . HTML_NBSP . sprintf(AUCTIONS_TEXT_AUCTION_USE_MULTI_PIC, $next_i, $fees[$pic_text]) . $image_html . '</div>';
    }
    return $image_html;
}
 function quote($method = '')
 {
     if ($_SESSION['cart']->show_total() < MODULE_SHIPPING_FREECOUNTAUSL_AMOUNT && MODULE_SHIPPING_FREECOUNTAUSL_DISPLAY == FALSE_STRING_L) {
         return;
     }
     $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_FREECOUNTAUSL_TEXT_TITLE);
     if ($_SESSION['cart']->show_total() < MODULE_SHIPPING_FREECOUNTAUSL_AMOUNT) {
         $this->quotes['error'] = MODULE_SHIPPING_FREECOUNTAUSL_TEXT_WAY;
     } else {
         $this->quotes['methods'] = array(array('id' => $this->code, 'title' => MODULE_SHIPPING_FREECOUNTAUSL_TEXT_WAY, 'cost' => 0));
     }
     if (olc_not_null($this->icon)) {
         $this->quotes['icon'] = olc_image($this->icon, $this->title);
     }
     return $this->quotes;
 }
 function add($class, $message, $type = 'error', $use_AJAX_mode = true)
 {
     if ($type == 'warning') {
         $message_type = "Warning";
         $icon_type = ICON_WARNING;
         $message_text = "Hinweis";
     } elseif ($type == 'success') {
         $message_type = "Success";
         $icon_type = ICON_SUCCESS;
         $message_text = "Erfolg";
     } else {
         $message_type = "Error";
         $icon_type = ICON_ERROR;
         $message_text = "Fehler";
     }
     $this->messages[] = array('params' => 'class="messageStack' . $message_type . '"', 'class' => $class, 'text' => olc_image(DIR_WS_ICONS . strtolower($message_type) . '.gif', $icon_type, EMPTY_STRING, EMPTY_STRING, 'align="middle"') . HTML_NBSP . $message);
 }
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 selection()
 {
     if (USE_PAYPAL_IPN) {
         $paypal_image_dir = PAYPAL_IPN_DIR . 'images/';
         $img_visa = olc_image($paypal_image_dir . 'visa.gif', ' Visa ', EMPTY_STRING, EMPTY_STRING, 'align="absmiddle"');
         $img_mc = olc_image($paypal_image_dir . 'mastercard.gif', ' MasterCard ', EMPTY_STRING, EMPTY_STRING, 'align="absmiddle"');
         $img_paypal = olc_image($paypal_image_dir . 'paypal_intl.gif', ' PayPal ', EMPTY_STRING, EMPTY_STRING, 'align="absmiddle"');
         /*
         $img_discover = olc_image($paypal_image_dir.'discover.gif',' Discover ',
         EMPTY_STRING,EMPTY_STRING,'align="absmiddle"');
         
         $img_amex = olc_image($paypal_image_dir.'amex.gif',' American Express ',
         EMPTY_STRING,EMPTY_STRING,'align="absmiddle"');
         */
         $paypal_cc_txt = sprintf(MODULE_PAYMENT_PAYPAL_IPN_CC_TEXT, $img_visa, $img_mc, $img_paypal, $img_amex, $img_discover);
         $fields[] = array('title' => EMPTY_STRING, 'field' => HTML_B_START . $paypal_cc_txt . HTML_B_END . $cc_explain);
         return array('id' => $this->code, 'module' => $this->title, 'fields' => $fields);
     }
 }
Esempio n. 11
0
 function quote($method = '')
 {
     global $order, $total_count;
     if (!$order) {
         $order = new order();
     }
     if (!$shipping_weight) {
         $shipping_weight = $_SESSION['cart']->show_weight();
     }
     $order_delivery_country = $order->delivery['country'];
     $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_ITEM_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => MODULE_SHIPPING_ITEM_TEXT_WAY, 'cost' => MODULE_SHIPPING_ITEM_COST * $total_count + MODULE_SHIPPING_ITEM_HANDLING)));
     if ($this->tax_class > 0) {
         $this->quotes['tax'] = olc_get_tax_rate($this->tax_class, $order_delivery_country['id'], $order->delivery['zone_id']);
     }
     if (olc_not_null($this->icon)) {
         $this->quotes['icon'] = olc_image($this->icon, $this->title);
     }
     return $this->quotes;
 }
 function image($img, $alt = '')
 {
     return olc_image($this->baseURL . 'images/' . $img, $alt);
 }
Esempio n. 13
0
 function quote($method = '')
 {
     global $order, $shipping_weight, $shipping_num_boxes;
     if (!$order) {
         $order = new order();
     }
     if (!$shipping_weight) {
         $shipping_weight = $_SESSION['cart']->show_weight();
     }
     $order_delivery_country = $order->delivery['country'];
     $dest_country = $order_delivery_country['iso_code_2'];
     $dest_zone = 0;
     $error = false;
     for ($j = 1; $j <= $this->num_chp; $j++) {
         $countries_table = constant('MODULE_SHIPPING_CHP_COUNTRIES_' . $j);
         $country_zones = split("[,]", $countries_table);
         if (in_array($dest_country, $country_zones)) {
             $dest_zone = $j;
             break;
         }
     }
     if ($dest_zone == 0) {
         $error = true;
     } else {
         $shipping = -1;
         $chp_cost_eco = @constant('MODULE_SHIPPING_CHP_COST_ECO_' . $j);
         $chp_cost_pri = @constant('MODULE_SHIPPING_CHP_COST_PRI_' . $j);
         $chp_cost_urg = @constant('MODULE_SHIPPING_CHP_COST_URG_' . $j);
         $methods = array();
         if ($chp_cost_eco != '') {
             $chp_table_eco = split("[:,]", $chp_cost_eco);
             for ($i = 0; $i < sizeof($chp_table_eco); $i += 2) {
                 if ($shipping_weight <= $chp_table_eco[$i]) {
                     $shipping_eco = $chp_table_eco[$i + 1];
                     break;
                 }
             }
             if ($shipping_eco == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_CHP_UNDEFINED_RATE;
             } else {
                 $shipping_cost_1 = $shipping_eco + MODULE_SHIPPING_CHP_HANDLING;
             }
             if ($shipping_eco != 0) {
                 $methods[] = array('id' => 'ECO', 'title' => 'Economy', 'cost' => (MODULE_SHIPPING_CHP_HANDLING + $shipping_cost_1) * $shipping_num_boxes);
             }
         }
         if ($chp_cost_pri != '') {
             $chp_table_pri = split("[:,]", $chp_cost_pri);
             for ($i = 0; $i < sizeof($chp_table_pri); $i += 2) {
                 if ($shipping_weight <= $chp_table_pri[$i]) {
                     $shipping_pri = $chp_table_pri[$i + 1];
                     break;
                 }
             }
             if ($shipping_pri == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_CHP_UNDEFINED_RATE;
             } else {
                 $shipping_cost_2 = $shipping_pri + MODULE_SHIPPING_CHP_HANDLING;
             }
             if ($shipping_pri != 0) {
                 $methods[] = array('id' => 'PRI', 'title' => 'Priority', 'cost' => (MODULE_SHIPPING_CHP_HANDLING + $shipping_cost_2) * $shipping_num_boxes);
             }
         }
         if ($chp_cost_urg != '') {
             $chp_table_urg = split("[:,]", $chp_cost_urg);
             for ($i = 0; $i < sizeof($chp_table_urg); $i += 2) {
                 if ($shipping_weight <= $chp_table_urg[$i]) {
                     $shipping_urg = $chp_table_urg[$i + 1];
                     break;
                 }
             }
             if ($shipping_urg == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_CHP_UNDEFINED_RATE;
             } else {
                 $shipping_cost_3 = $shipping_urg + MODULE_SHIPPING_CHP_HANDLING;
             }
             if ($shipping_urg != 0) {
                 $methods[] = array('id' => 'URG', 'title' => 'Urgent', 'cost' => (MODULE_SHIPPING_CHP_HANDLING + $shipping_cost_3) * $shipping_num_boxes);
             }
         }
     }
     $this->quotes = array('id' => $this->code, 'module' => $this->title . LPAREN . $shipping_num_boxes . ' x ' . number_format($shipping_weight, CURRENCY_DECIMAL_PLACES, CURRENCY_DECIMAL_POINT, CURRENCY_THOUSANDS_POINT) . BLANK . MODULE_SHIPPING_CHP_TEXT_UNITS . RPAREN);
     $this->quotes['methods'] = $methods;
     if ($this->tax_class > 0) {
         $this->quotes['tax'] = olc_get_tax_rate($this->tax_class, $order_delivery_country['id'], $order->delivery['zone_id']);
     }
     if (olc_not_null($this->icon)) {
         $this->quotes['icon'] = olc_image($this->icon, $this->title);
     }
     if ($error == true) {
         $this->quotes['error'] = MODULE_SHIPPING_CHP_INVALID_ZONE;
     }
     if (olc_not_null($method) && isset($this->types[$method])) {
         for ($i = 0; $i < sizeof($methods); $i++) {
             if ($method == $methods[$i]['id']) {
                 $methodsc = array();
                 $methodsc[] = array('id' => $methods[$i]['id'], 'title' => $methods[$i]['title'], 'cost' => $methods[$i]['cost']);
                 break;
             }
         }
         $this->quotes['methods'] = $methodsc;
     }
     return $this->quotes;
 }
Esempio n. 14
0
         $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;
     $box = new box();
     echo $box->infoBox($heading, $contents);
     echo '            </td>' . NEW_LINE;
 }
 ?>
       </tr>
     </table></td>
?>
<table border="0" cellpadding="0" cellspacing="0" class="popupmain">
  <tr><td class="ppheading" style="height: 50px;">Make Shopping Easier for Customers with Website Payments</td></tr>
  <tr><td><hr class="solid"></td></tr>
  <tr>
      <td class="pptext"><?php 
echo olc_image($paypal_image_dir . 'hdr_ppGlobev4_160x76.gif', ' PayPal ', '', '', 'align=right valign="top" style="margin: 10px;"');
?>
PayPal has optimized their checkout experience by launching an exciting new improvement to their payment flow.
<br/><br/>For new buyers, signing up for a PayPal account is now optional. This means you can complete your payment first, and then decide whether to save your information for future purchases.
<p>To pay by credit card, look for this button:<br/>
<p align="center"><?php 
echo olc_image($paypal_image_dir . 'PayPal-ContinueCheckout.gif', '', '', '');
?>
</p>
<br/>
Or you may see this:<br/>
<p align="center"><?php 
echo olc_image($paypal_image_dir . 'PayPal-no-account-Click-Here.gif', '', '', '');
?>
</p>
<br/>
One of these options should appear on the first PayPal screen.<br/>
<p>Note: if you are a PayPal member, you can either use your account,
or use a credit card that is not associated with a PayPal account.
In that case you'd also need to use an email address that's not associated with a PayPal account.</p>
    </td>
  </tr>
  <tr><td><br class="h10"></td></tr>
</table>
    }
    if (is_object($tcInfo) && $classes['tax_class_id'] == $tcInfo->tax_class_id) {
        echo '              <tr class="dataTableRowSelected" onmouseover="this.style.cursor=\'hand\'" onclick="javascript:' . olc_onclick_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $tcInfo->tax_class_id . '&action=edit') . '">' . NEW_LINE;
    } else {
        echo '              <tr class="dataTableRow" onmouseover="this.className=\'dataTableRowOver\';this.style.cursor=\'hand\'" onmouseout="this.className=\'dataTableRow\'" onclick="javascript:' . olc_onclick_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $classes['tax_class_id']) . '">' . NEW_LINE;
    }
    ?>
                <td class="dataTableContent"><?php 
    echo $classes['tax_class_title'];
    ?>
</td>
                <td class="dataTableContent" align="right"><?php 
    if (is_object($tcInfo) && $classes['tax_class_id'] == $tcInfo->tax_class_id) {
        echo olc_image(DIR_WS_IMAGES . 'icon_arrow_right.gif', '');
    } else {
        echo HTML_A_START . olc_href_link(FILENAME_TAX_CLASSES, 'page=' . $_GET['page'] . '&tID=' . $classes['tax_class_id']) . '">' . olc_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . HTML_A_END;
    }
    ?>
&nbsp;</td>
              </tr>
<?php 
}
?>
              <tr>
                <td colspan="2"><table border="0" width="100%" cellspacing="0" cellpadding="2">
                  <tr>
                    <td class="smallText" valign="top"><?php 
echo $classes_split->display_count($classes_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_TAX_CLASSES);
?>
</td>
                    <td class="smallText" align="right"><?php 
Esempio n. 17
0
    echo $currencies->format($gv_list['coupon_amount']);
    ?>
</td>
                <td class="dataTableContent" align="center"><?php 
    echo $gv_list['coupon_code'];
    ?>
</td>
                <td class="dataTableContent" align="right"><?php 
    echo olc_date_short($gv_list['date_sent']);
    ?>
</td>
                <td class="dataTableContent" align="right"><?php 
    if (is_object($gInfo) && $gv_list['coupon_id'] == $gInfo->coupon_id) {
        echo olc_image(DIR_WS_IMAGES . 'icon_arrow_right.gif');
    } else {
        echo HTML_A_START . olc_href_link(FILENAME_GV_SENT, 'page=' . $_GET['page'] . '&gid=' . $gv_list['coupon_id']) . '">' . olc_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . HTML_A_END;
    }
    ?>
&nbsp;</td>
              </tr>
<?php 
}
?>
              <tr>
                <td colspan="5"><table border="0" width="100%" cellspacing="0" cellpadding="2">
                  <tr>
                    <td class="smallText" valign="top"><?php 
echo $gv_split->display_count($gv_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_GIFT_VOUCHERS);
?>
</td>
                    <td class="smallText" align="right"><?php 
Esempio n. 18
0
---------------------------------------------------------------------------------------*/
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_tax_text = 'PRODUCTS_TAX';
$products_image_text = 'PRODUCTS_IMAGE';
$box_delete_text = 'BOX_DELETE';
$products_link_text = 'PRODUCTS_LINK';
$products_price_text = 'PRODUCTS_PRICE';
$products_single_price_text = 'PRODUCTS_SINGLE_PRICE';
$products_short_description_text = 'PRODUCTS_SHORT_DESCRIPTION';
$products_attributes_text = 'ATTRIBUTES';
$element_text = 'ELEMENT';
$big_id_text = 'ID';
$big_model_text = 'MODEL';
$big_name_text = 'NAME';
$value_name_text = 'VALUE_NAME';
$price_text = 'PRICE';
if (USE_EBAY) {
    $ebay_image = HTML_NBSP . olc_image(DIR_WS_IMAGES . "ebay.gif", AUCTIONS_TEXT_SHOW_PRODUCT, EMPTY_STRING, EMPTY_STRING, ' align="middle"');
    $ebay_link = olc_href_link(EBAY_SERVER, EBAY_VIEWITEM . HASH) . '" target="_blank';
    $hidden_quantity = olc_draw_hidden_field($cart_quantity_text, HASH);
    $hidden_product_id = olc_draw_hidden_field($products_id_text, HASH);
}
$link = olc_href_link(FILENAME_PRODUCT_INFO, $products_id_equal_text . HASH);
$do_stock_check = STOCK_CHECK == TRUE_STRING_S;
$do_atribute_stock_check = $do_stock_check && ATTRIBUTE_STOCK_CHECK == TRUE_STRING_S;
for ($i = 0; $i < sizeof($products); $i++) {
    $product = $products[$i];
    $product_id = $product[$id_text];
    $products_quantity = $product[$quantity_text];
    $products_min_quantity = $product[$min_quantity_text];
    $products_quantity = max($products_quantity, $products_min_quantity);
    if ($do_stock_check) {
        $mark_stock = olc_check_stock($product_id, $products_quantity);
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];
<?php 
if (function_exists('imagecreate') && $dir_ok && $banner_extension) {
    $banner_id = $_GET['bID'];
    switch ($_GET['type']) {
        case 'yearly':
            include DIR_WS_INCLUDES . 'graphs/banner_yearly.php';
            echo olc_image(DIR_WS_IMAGES . 'graphs/banner_yearly-' . $banner_id . '.' . $banner_extension);
            break;
        case 'monthly':
            include DIR_WS_INCLUDES . 'graphs/banner_monthly.php';
            echo olc_image(DIR_WS_IMAGES . 'graphs/banner_monthly-' . $banner_id . '.' . $banner_extension);
            break;
        default:
        case 'daily':
            include DIR_WS_INCLUDES . 'graphs/banner_daily.php';
            echo olc_image(DIR_WS_IMAGES . 'graphs/banner_daily-' . $banner_id . '.' . $banner_extension);
            break;
    }
    ?>
          <table border="0" width="600" cellspacing="0" cellpadding="2">
            <tr class="dataTableHeadingRow">
             <td class="dataTableHeadingContent"><?php 
    echo TABLE_HEADING_SOURCE;
    ?>
</td>
             <td class="dataTableHeadingContent" align="right"><?php 
    echo TABLE_HEADING_VIEWS;
    ?>
</td>
             <td class="dataTableHeadingContent" align="right"><?php 
    echo TABLE_HEADING_CLICKS;
Esempio n. 22
0
 function quote($method = '')
 {
     global $order, $shipping_weight, $shipping_num_boxes;
     if (!$order) {
         $order = new order();
     }
     if (!$shipping_weight) {
         $shipping_weight = $_SESSION['cart']->show_weight();
     }
     $order_delivery_country = $order->delivery['country'];
     $dest_country = $order_delivery_country['iso_code_2'];
     $dest_zone = 0;
     $error = false;
     for ($j = 1; $j <= $this->num_dhl; $j++) {
         $countries_table = constant('MODULE_SHIPPING_DHL_COUNTRIES_' . $j);
         $country_zones = split("[,]", $countries_table);
         if (in_array($dest_country, $country_zones)) {
             $dest_zone = $j;
             break;
         }
     }
     if ($dest_zone == 0) {
         $error = true;
     } else {
         $shipping = -1;
         $dhl_cost_ecx = @constant('MODULE_SHIPPING_DHL_COST_ECX_' . $j);
         $dhl_cost_dox = @constant('MODULE_SHIPPING_DHL_COST_DOX_' . $j);
         $dhl_cost_wpx = @constant('MODULE_SHIPPING_DHL_COST_WPX_' . $j);
         $dhl_cost_mdx = @constant('MODULE_SHIPPING_DHL_COST_MDX_' . $j);
         $dhl_cost_sdx = @constant('MODULE_SHIPPING_DHL_COST_SDX_' . $j);
         $methods = array();
         $n == 0;
         if ($dhl_cost_ecx != '') {
             $dhl_table_ecx = split("[:,]", $dhl_cost_ecx);
             if ($shipping_weight > 10 and $shipping_weight <= 20) {
                 $shipping_ecx = number_format(($shipping_weight - 10) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_ECX_20_' . $j) + $dhl_table_ecx[count($dhl_table_ecx) - 1];
             } elseif ($shipping_weight > 20 and $shipping_weight <= 30) {
                 $shipping_ecx = number_format(($shipping_weight - 20) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_ECX_30_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_ECX_20_' . $j) + $dhl_table_ecx[count($dhl_table_ecx) - 1];
             } elseif ($shipping_weight > 30 and $shipping_weight <= 50) {
                 $shipping_ecx = number_format(($shipping_weight - 30) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_ECX_50_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_ECX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_ECX_30_' . $j) + $dhl_table_ecx[count($dhl_table_ecx) - 1];
             } elseif ($shipping_weight > 50) {
                 $shipping_ecx = number_format(($shipping_weight - 50) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_ECX_51_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_ECX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_ECX_30_' . $j) + 40 * constant('MODULE_SHIPPING_DHL_STEP_ECX_50_' . $j) + $dhl_table_ecx[count($dhl_table_ecx) - 1];
             } else {
                 for ($i = 0; $i < sizeof($dhl_table_ecx); $i += 2) {
                     if ($shipping_weight <= $dhl_table_ecx[$i]) {
                         $shipping_ecx = $dhl_table_ecx[$i + 1];
                         break;
                     }
                 }
             }
             if ($shipping_ecx == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_DHL_UNDEFINED_RATE;
             } else {
                 $shipping_cost_1 = $shipping_ecx + MODULE_SHIPPING_DHL_HANDLING;
             }
             $methods[] = array('id' => 'ECX', 'title' => 'EU Express Service', 'cost' => (MODULE_SHIPPING_DHL_HANDLING + $shipping_cost_1) * $shipping_num_boxes);
             $n++;
         }
         if ($dhl_cost_dox != '') {
             $dhl_table_dox = split("[:,]", $dhl_cost_dox);
             if ($shipping_weight > 10 and $shipping_weight <= 20) {
                 $shipping_dox = number_format(($shipping_weight - 10) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_DOX_20_' . $j) + $dhl_table_dox[count($dhl_table_dox) - 1];
             } elseif ($shipping_weight > 20 and $shipping_weight <= 30) {
                 $shipping_dox = number_format(($shipping_weight - 20) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_DOX_30_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_DOX_20_' . $j) + $dhl_table_dox[count($dhl_table_dox) - 1];
             } elseif ($shipping_weight > 30 and $shipping_weight <= 50) {
                 $shipping_dox = number_format(($shipping_weight - 30) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_DOX_50_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_DOX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_DOX_30_' . $j) + $dhl_table_dox[count($dhl_table_dox) - 1];
             } elseif ($shipping_weight > 50) {
                 $shipping_dox = number_format(($shipping_weight - 50) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_DOX_51_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_DOX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_DOX_30_' . $j) + 40 * constant('MODULE_SHIPPING_DHL_STEP_DOX_50_' . $j) + $dhl_table_dox[count($dhl_table_dox) - 1];
             } else {
                 for ($i = 0; $i < sizeof($dhl_table_dox); $i += 2) {
                     if ($shipping_weight <= $dhl_table_dox[$i]) {
                         $shipping_dox = $dhl_table_dox[$i + 1];
                         break;
                     }
                 }
             }
             if ($shipping_dox == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_DHL_UNDEFINED_RATE;
             } else {
                 $shipping_cost_2 = $shipping_dox + MODULE_SHIPPING_DHL_HANDLING;
             }
             $methods[] = array('id' => 'DOX', 'title' => 'Document Express Service', 'cost' => (MODULE_SHIPPING_DHL_HANDLING + $shipping_cost_2) * $shipping_num_boxes);
             $n++;
         }
         if ($dhl_cost_wpx != '') {
             $dhl_table_wpx = split("[:,]", $dhl_cost_wpx);
             if ($shipping_weight > 10 and $shipping_weight <= 20) {
                 $shipping_wpx = number_format(($shipping_weight - 10) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_WPX_20_' . $j) + $dhl_table_wpx[count($dhl_table_wpx) - 1];
             } elseif ($shipping_weight > 20 and $shipping_weight <= 30) {
                 $shipping_wpx = number_format(($shipping_weight - 20) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_WPX_30_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_WPX_20_' . $j) + $dhl_table_wpx[count($dhl_table_wpx) - 1];
             } elseif ($shipping_weight > 30 and $shipping_weight <= 50) {
                 $shipping_wpx = number_format(($shipping_weight - 30) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_WPX_50_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_WPX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_WPX_30_' . $j) + $dhl_table_wpx[count($dhl_table_wpx) - 1];
             } elseif ($shipping_weight > 50) {
                 $shipping_wpx = number_format(($shipping_weight - 50) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_WPX_51_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_WPX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_WPX_30_' . $j) + 40 * constant('MODULE_SHIPPING_DHL_STEP_WPX_50_' . $j) + $dhl_table_wpx[count($dhl_table_wpx) - 1];
             } else {
                 for ($i = 0; $i < sizeof($dhl_table_wpx); $i += 2) {
                     if ($shipping_weight <= $dhl_table_wpx[$i]) {
                         $shipping_wpx = $dhl_table_wpx[$i + 1];
                         break;
                     }
                 }
             }
             if ($shipping_wpx == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_DHL_UNDEFINED_RATE;
             } else {
                 $shipping_cost_3 = $shipping_wpx + MODULE_SHIPPING_DHL_HANDLING;
             }
             $methods[] = array('id' => 'WPX', 'title' => 'Waren Express Service', 'cost' => (MODULE_SHIPPING_DHL_HANDLING + $shipping_cost_3) * $shipping_num_boxes);
             $n++;
         }
         if ($dhl_cost_mdx != '') {
             $dhl_table_mdx = split("[:,]", $dhl_cost_mdx);
             if ($shipping_weight > 10 and $shipping_weight <= 20) {
                 $shipping_mdx = number_format(($shipping_weight - 10) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_MDX_20_' . $j) + $dhl_table_mdx[count($dhl_table_mdx) - 1];
             } elseif ($shipping_weight > 20 and $shipping_weight <= 30) {
                 $shipping_mdx = number_format(($shipping_weight - 20) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_MDX_30_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_MDX_20_' . $j) + $dhl_table_mdx[count($dhl_table_mdx) - 1];
             } elseif ($shipping_weight > 30 and $shipping_weight <= 50) {
                 $shipping_mdx = number_format(($shipping_weight - 30) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_MDX_50_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_MDX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_MDX_30_' . $j) + $dhl_table_mdx[count($dhl_table_mdx) - 1];
             } elseif ($shipping_weight > 50) {
                 $shipping_mdx = number_format(($shipping_weight - 50) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_MDX_51_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_MDX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_MDX_30_' . $j) + 40 * constant('MODULE_SHIPPING_DHL_STEP_MDX_50_' . $j) + $dhl_table_mdx[count($dhl_table_mdx) - 1];
             } else {
                 for ($i = 0; $i < sizeof($dhl_table_mdx); $i += 2) {
                     if ($shipping_weight <= $dhl_table_mdx[$i]) {
                         $shipping_mdx = $dhl_table_mdx[$i + 1];
                         break;
                     }
                 }
             }
             if ($shipping_mdx == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_DHL_UNDEFINED_RATE;
             } else {
                 $shipping_cost_4 = $shipping_mdx + MODULE_SHIPPING_DHL_HANDLING;
             }
             $methods[] = array('id' => 'MDX', 'title' => 'Mid Day Express Service', 'cost' => (MODULE_SHIPPING_DHL_HANDLING + $shipping_cost_4) * $shipping_num_boxes);
             $n++;
         }
         if ($dhl_cost_sdx != '') {
             $dhl_table_sdx = split("[:,]", $dhl_cost_sdx);
             if ($shipping_weight > 10 and $shipping_weight <= 20) {
                 $shipping_sdx = number_format(($shipping_weight - 10) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_SDX_20_' . $j) + $dhl_table_sdx[count($dhl_table_sdx) - 1];
             } elseif ($shipping_weight > 20 and $shipping_weight <= 30) {
                 $shipping_sdx = number_format(($shipping_weight - 20) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_SDX_30_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_SDX_20_' . $j) + $dhl_table_sdx[count($dhl_table_sdx) - 1];
             } elseif ($shipping_weight > 30 and $shipping_weight <= 50) {
                 $shipping_sdx = number_format(($shipping_weight - 30) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_SDX_50_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_SDX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_SDX_30_' . $j) + $dhl_table_sdx[count($dhl_table_sdx) - 1];
             } elseif ($shipping_weight > 50) {
                 $shipping_sdx = number_format(($shipping_weight - 50) * 2 + 0.5, 0) * constant('MODULE_SHIPPING_DHL_STEP_SDX_51_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_SDX_20_' . $j) + 20 * constant('MODULE_SHIPPING_DHL_STEP_SDX_30_' . $j) + 40 * constant('MODULE_SHIPPING_DHL_STEP_SDX_50_' . $j) + $dhl_table_sdx[count($dhl_table_sdx) - 1];
             } else {
                 for ($i = 0; $i < sizeof($dhl_table_sdx); $i += 2) {
                     if ($shipping_weight <= $dhl_table_sdx[$i]) {
                         $shipping_sdx = $dhl_table_sdx[$i + 1];
                         break;
                     }
                 }
             }
             if ($shipping_sdx == -1) {
                 $shipping_cost = 0;
                 $shipping_method = MODULE_SHIPPING_DHL_UNDEFINED_RATE;
             } else {
                 $shipping_cost_5 = $shipping_sdx + MODULE_SHIPPING_DHL_HANDLING;
             }
             $methods[] = array('id' => 'SDX', 'title' => 'Start Day Express Service', 'cost' => (MODULE_SHIPPING_DHL_HANDLING + $shipping_cost_5) * $shipping_num_boxes);
             $n++;
         }
     }
     $this->quotes = array('id' => $this->code, 'module' => $this->title . LPAREN . $shipping_num_boxes . ' x ' . $shipping_weight . BLANK . MODULE_SHIPPING_DHL_TEXT_UNITS . RPAREN);
     $this->quotes['methods'] = $methods;
     if ($this->tax_class > 0) {
         $this->quotes['tax'] = olc_get_tax_rate($this->tax_class, $order_delivery_country['id'], $order->delivery['zone_id']);
     }
     if (olc_not_null($this->icon)) {
         $this->quotes['icon'] = olc_image($this->icon, $this->title);
     }
     if ($error == true) {
         $this->quotes['error'] = MODULE_SHIPPING_DHL_INVALID_ZONE;
     }
     if (olc_not_null($method) && isset($this->types[$method])) {
         for ($i = 0; $i < sizeof($methods); $i++) {
             if ($method == $methods[$i]['id']) {
                 $methodsc = array();
                 $methodsc[] = array('id' => $methods[$i]['id'], 'title' => $methods[$i]['title'], 'cost' => $methods[$i]['cost']);
                 break;
             }
         }
         $this->quotes['methods'] = $methodsc;
     }
     return $this->quotes;
 }
    if ($next_id != sizeof($p_data) - 1) {
        $last_link = olc_href_link(FILENAME_PRODUCT_INFO, $products_id_param_text . $p_data[sizeof($p_data) - 1]['pID'], NONSSL, false);
    }
}
$s1 = '">' . HASH . HTML_A_END . HTML_NBSP;
$s2 = '" title="';
$first_link = HTML_A_START . $first_link . $s2 . TEXT_NAVIGATION_FIRST . $s1;
$prev_link = HTML_A_START . $prev_link . $s2 . TEXT_NAVIGATION_PREVIOUS . $s1;
$next_link = HTML_A_START . $next_link . $s2 . TEXT_NAVIGATION_NEXT . $s1;
$last_link = HTML_A_START . $last_link . $s2 . TEXT_NAVIGATION_LAST . $s1;
$s = CURRENT_TEMPLATE_BUTTONS . 'button_product_';
$first_image = $s . 'first.gif';
if (file_exists($first_image)) {
    $first_link = str_replace(HASH, olc_image($first_image), $first_link);
    $prev_link = str_replace(HASH, olc_image($s . 'previous.gif'), $prev_link);
    $next_link = str_replace(HASH, olc_image($s . 'next.gif'), $next_link);
    $last_link = str_replace(HASH, olc_image($s . 'last.gif'), $last_link);
} else {
    $s = 'product_navigator';
    $first_link = str_replace(HASH, olc_get_smarty_config_variable($module_smarty, $s, 'first'), $first_link);
    $prev_link = str_replace(HASH, olc_get_smarty_config_variable($module_smarty, $s, 'back'), $prev_link);
    $next_link = str_replace(HASH, olc_get_smarty_config_variable($module_smarty, $s, 'next'), $next_link);
    $last_link = str_replace(HASH, olc_get_smarty_config_variable($module_smarty, $s, 'last'), $last_link);
}
$module_smarty->assign('FIRST', $first_link);
$module_smarty->assign('PREVIOUS', $prev_link);
$module_smarty->assign('NEXT', $next_link);
$module_smarty->assign('LAST', $last_link);
$module_smarty->assign('PRODUCTS_COUNT', count($p_data));
$product_navigator = $module_smarty->fetch(CURRENT_TEMPLATE_MODULE . 'product_navigator' . HTML_EXT, $cacheid);
$info_smarty->assign('PRODUCT_NAVIGATOR', $product_navigator);
										  <a href="<?php 
                echo olc_href_link(FILENAME_MODULE_NEWSLETTER, 'action=delete&id=' . $current_id);
                ?>
" onclick="javascript:return confirm('<?php 
                echo CONFIRM_DELETE;
                ?>
')">
										  <?php 
                echo olc_image(DIR_WS_ICONS . 'delete.gif', 'Delete', EMPTY_STRING, EMPTY_STRING, 'style="cursor:hand" onclick="javascript:return confirm(\'' . DELETE_ENTRY . '\')"') . '  ' . TEXT_DELETE . '</a>&nbsp;&nbsp;';
                ?>
											<a href="<?php 
                echo olc_href_link(FILENAME_MODULE_NEWSLETTER, 'action=edit&id=' . $current_id);
                ?>
">
										<?php 
                echo olc_image(DIR_WS_ICONS . 'icon_edit.gif', 'Edit', EMPTY_STRING, EMPTY_STRING) . '  ' . TEXT_EDIT . HTML_A_END;
                ?>
					          </td>
					        </tr>
<?php 
            }
        }
        ?>
								</table>
<?php 
        break;
        // end default page
    // end default page
    case 'edit':
        $newsletters_query = olc_db_query("SELECT\n                                   title,body,cc\n                                  FROM " . TABLE_MODULE_NEWSLETTER . "\n                                  WHERE newsletter_id='" . $id_get . APOS);
        $newsletters_data = olc_db_fetch_array($newsletters_query);
    }
    if (is_object($bInfo) && $blacklist['blacklist_id'] == $bInfo->blacklist_id) {
        echo '              <tr class="dataTableRowSelected" onmouseover="this.style.cursor=\'hand\'" onclick="javascript:' . olc_onclick_link(FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $blacklist['blacklist_id'] . '&action=edit') . '">' . NEW_LINE;
    } else {
        echo '              <tr class="dataTableRow" onmouseover="this.className=\'dataTableRowOver\';this.style.cursor=\'hand\'" onmouseout="this.className=\'dataTableRow\'" onclick="javascript:' . olc_onclick_link(FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $blacklist['blacklist_id']) . '">' . NEW_LINE;
    }
    ?>
                <td class="dataTableContent"><?php 
    echo $blacklist['blacklist_card_number'];
    ?>
</td>
                <td class="dataTableContent" align="right"><?php 
    if (is_object($bInfo) && $blacklist['blacklist_id'] == $bInfo->blacklist_id) {
        echo olc_image(DIR_WS_IMAGES . 'icon_arrow_right.gif');
    } else {
        echo HTML_A_START . olc_href_link(FILENAME_BLACKLIST, 'page=' . $_GET['page'] . '&bID=' . $blacklist['blacklist_id']) . '">' . olc_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . HTML_A_END;
    }
    ?>
&nbsp;</td>
              </tr>
<?php 
}
?>
              <tr>
                <td colspan="2"><table border="0" width="100%" cellspacing="0" cellpadding="2">
                  <tr>
                    <td class="smallText" valign="top"><?php 
echo $blacklist_split->display_count($blacklist_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_BLACKLIST_CARDS);
?>
</td>
                    <td class="smallText" align="right"><?php 
    // end of foreach.
    //////////////////////////////////////////////////////////////////////////////////
    // This bit does the 'PRIORITISE' page (previously Sort)
    $query = "select b.language_id, a.products_id, b.products_name, b.products_description, " . "a.products_quantity, a.products_model, a.products_image, " . "b.products_url, a.products_price from " . TABLE_PRODUCTS . " a, " . TABLE_PRODUCTS_DESCRIPTION . " b where b.products_id = a.products_id and b.language_id = '" . $languages_id . "' and a.products_id = '" . $add_related_product_ID . APOS;
    list($language_id, $PRODUCTS_id, $PRODUCTS_name, $PRODUCTS_description, $PRODUCTS_quantity, $PRODUCTS_model, $PRODUCTS_image, $PRODUCTS_url, $PRODUCTS_price) = general_db_conct($query);
    ?>

								  <?php 
    olc_draw_form('xsell_products', FILENAME_XSELL_PRODUCTS, 'sort=1&add_related_product_ID=' . $add_related_product_ID, 'post');
    //<form method="post" action="<?php olc_href_link(FILENAME_XSELL_PRODUCTS, 'sort=1&add_related_product_ID=' . $add_related_product_ID, NONSSL);
    ?>
">
									?>
											<?php 
    define('AJAX_TITLE', 'Cross-Marketing Produkte für: ' . $PRODUCTS_model[0] . ' (Produkt id: ' . $PRODUCTS_id[0] . RPAREN);
    echo '<span class="pageHeading">' . AJAX_TITLE . '<br/><br/>' . ($PRODUCTS_image[0] ? olc_image(DIR_WS_CATALOG_THUMBNAIL_IMAGES . $PRODUCTS_image[0], $PRODUCTS_name[0]) : "") . '</span><br/><br/>';
    ?>

                  <table cellpadding="2" cellspacing="1" bgcolor=999999 border="0">
                    <tr class="dataTableHeadingRow">
                      <td class="dataTableHeadingContent" width="75">Product
                        id</td>
                      <td class="dataTableHeadingContent" width="75">Quickfind
                        code</td>

                      <td class="dataTableHeadingContent">Name</td>
                      <td class="dataTableHeadingContent" width="150">Price</td>
                      <td class="dataTableHeadingContent" width="150">Order (1=Top)</td>
                    </tr>
                    <?php 
    $query = "select * from " . TABLE_PRODUCTS_XSELL . " WHERE products_id = '" . $add_related_product_ID . APOS;
            } elseif ($cc_list['coupon_type'] == 'S') {
                echo TEXT_FREE_SHIPPING;
            } else {
                echo $currencies->format($cc_list['coupon_amount']);
            }
            ?>
            &nbsp;</td>
                <td class="dataTableContent" align="center"><?php 
            echo $cc_list['coupon_code'];
            ?>
</td>
                <td class="dataTableContent" align="right"><?php 
            if (is_object($cInfo) && $cc_list['coupon_id'] == $cInfo->coupon_id) {
                echo olc_image(DIR_WS_IMAGES . 'icon_arrow_right.gif');
            } else {
                echo HTML_A_START . olc_href_link(FILENAME_COUPON_ADMIN, 'page=' . $_GET['page'] . '&cid=' . $cc_list['coupon_id']) . '">' . olc_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . HTML_A_END;
            }
            ?>
&nbsp;</td>
              </tr>
<?php 
        }
        ?>
          <tr>
            <td colspan="5"><table border="0" width="100%" cellspacing="0" cellpadding="2">
              <tr>
                <td class="smallText">&nbsp;<?php 
        echo $cc_split->display_count($cc_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_COUPONS);
        ?>
&nbsp;</td>
                <td align="right" class="smallText">&nbsp;<?php 
        $heading[] = array('text' => HTML_B_START . TEXT_INFO_HEADING_DELETE_CUSTOMERS_STATUS . HTML_B_END);
        $contents = array('form' => olc_draw_form('status', FILENAME_CUSTOMERS_STATUS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->customers_status_id . '&action=deleteconfirm'));
        $contents[] = array('text' => TEXT_INFO_DELETE_INTRO);
        $contents[] = array('text' => '<br/><b>' . $cInfo->customers_status_name . HTML_B_END);
        if ($remove_status) {
            $contents[] = array('align' => 'center', 'text' => HTML_BR . olc_image_submit('button_delete.gif', IMAGE_DELETE) . BLANK . HTML_A_START . olc_href_link(FILENAME_CUSTOMERS_STATUS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->customers_status_id) . '">' . olc_image_button('button_cancel.gif', IMAGE_CANCEL) . HTML_A_END);
        }
        break;
    default:
        if (is_object($cInfo)) {
            $heading[] = array('text' => HTML_B_START . $cInfo->customers_status_name . HTML_B_END);
            $contents[] = array('align' => 'center', 'text' => HTML_A_START . olc_href_link(FILENAME_CUSTOMERS_STATUS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->customers_status_id . '&action=edit') . '">' . olc_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . olc_href_link(FILENAME_CUSTOMERS_STATUS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->customers_status_id . '&action=delete') . '">' . olc_image_button('button_delete.gif', IMAGE_DELETE) . HTML_A_END);
            $customers_status_inputs_string = '';
            $languages = olc_get_languages();
            for ($i = 0; $i < sizeof($languages); $i++) {
                $customers_status_inputs_string .= HTML_BR . olc_image(DIR_WS_CATALOG . 'lang/' . $languages[$i]['directory'] . '/admin/images/' . $languages[$i]['image'], $languages[$i]['name']) . HTML_NBSP . olc_get_customers_status_name($cInfo->customers_status_id, $languages[$i]['id']);
            }
            $contents[] = array('text' => $customers_status_inputs_string);
            $contents[] = array('text' => HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_DISCOUNT_PRICE_INTRO . HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_DISCOUNT_PRICE . BLANK . $cInfo->customers_status_discount . '%');
            $contents[] = array('text' => HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_DISCOUNT_OT_XMEMBER_INTRO . HTML_BR . ENTRY_OT_XMEMBER . BLANK . $customers_status_ot_discount_flag_array[$cInfo->customers_status_ot_discount_flag]['text'] . LPAREN . $cInfo->customers_status_ot_discount_flag . RPAREN . ' - ' . $cInfo->customers_status_ot_discount . '%');
            $contents[] = array('text' => HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_GRADUATED_PRICES_INTRO . HTML_BR . ENTRY_GRADUATED_PRICES . BLANK . $customers_status_graduated_prices_array[$cInfo->customers_status_graduated_prices]['text'] . LPAREN . $cInfo->customers_status_graduated_prices . RPAREN);
            $contents[] = array('text' => HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_DISCOUNT_ATTRIBUTES_INTRO . HTML_BR . ENTRY_CUSTOMERS_STATUS_DISCOUNT_ATTRIBUTES . BLANK . $customers_status_discount_attributes_array[$cInfo->customers_status_discount_attributes]['text'] . LPAREN . $cInfo->customers_status_discount_attributes . RPAREN);
            $contents[] = array('text' => HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_PAYMENT_UNALLOWED_INTRO . HTML_BR . ENTRY_CUSTOMERS_STATUS_PAYMENT_UNALLOWED . ':<b> ' . $cInfo->customers_status_payment_unallowed . HTML_B_END);
            $contents[] = array('text' => HTML_BR . TEXT_INFO_CUSTOMERS_STATUS_SHIPPING_UNALLOWED_INTRO . HTML_BR . ENTRY_CUSTOMERS_STATUS_SHIPPING_UNALLOWED . ':<b> ' . $cInfo->customers_status_shipping_unallowed . HTML_B_END);
        }
        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);
        if ($affiliate_banners['affiliate_products_id'] > 0) {
            echo $affiliate_banners['affiliate_products_id'];
        } else {
            echo HTML_NBSP;
        }
        ?>
</td>
		<td class="dataTableContent" align="right"><?php 
        echo $affiliate_banners_shown . ' / ' . $affiliate_banners_clicked;
        ?>
</td>
		<td class="dataTableContent" align="right"><?php 
        if (is_object($abInfo) && $affiliate_banners['affiliate_banners_id'] == $abInfo->affiliate_banners_id) {
            echo olc_image(DIR_WS_IMAGES . 'icon_arrow_right.gif', '');
        } else {
            echo HTML_A_START . olc_href_link(FILENAME_AFFILIATE_BANNER_MANAGER, 'page=' . $_GET['page'] . '&abID=' . $affiliate_banners['affiliate_banners_id']) . '">' . olc_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . HTML_A_END;
        }
        ?>
&nbsp;</td>
		</tr>
		<?php 
    }
    ?>
	<tr>
	<td colspan="4"><table border="0" width="100%" cellspacing="0" cellpadding="2">
	<tr>
	<td class="smallText" valign="top"><?php 
    echo $affiliate_banners_split->display_count($affiliate_banners_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_BANNERS);
    ?>
</td>
	<td class="smallText" align="right"><?php 
Esempio n. 30
0
 function contentBoxHeading($contents)
 {
     $this->table_width = '100%';
     $this->table_cellpadding = '0';
     $info_box_contents = array();
     $info_box_contents[] = array(array('params' => 'height="14" class="infoBoxHeading"', 'text' => olc_image(DIR_WS_IMAGES . 'infobox/corner_left.gif')), array('params' => 'height="14" class="infoBoxHeading" width="100%"', 'text' => $contents[0]['text']), array('params' => 'height="14" class="infoBoxHeading"', 'text' => olc_image(DIR_WS_IMAGES . 'infobox/corner_right_left.gif')));
     $this->tableBox($info_box_contents, true);
 }