Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

zefeena

Pioneers
  • Posts

    593
  • Joined

  • Last visited

Posts posted by zefeena

  1. <?php

    /*

    $Id$

    osCommerce, Open Source E-Commerce Solutions

    http://www.oscommerce.com

    Copyright © 2003 osCommerce

    Released under the GNU General Public License

    */

    class order {

    var $info, $totals, $products, $customer, $delivery;

    function order($order_id) {

    $this->info = array();

    $this->totals = array();

    $this->products = array();

    $this->customer = array();

    $this->delivery = array();

    $this->query($order_id);

    }

    function query($order_id) {

    $order_query = tep_db_query("select customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, cc_type, cc_owner, cc_number, cc_expires, currency, currency_value, date_purchased, orders_status, last_modified from " . TABLE_ORDERS . " where orders_id = '" . (int)$order_id . "'");

    $order = tep_db_fetch_array($order_query);

    $totals_query = tep_db_query("select title, text from " . TABLE_ORDERS_TOTAL . " where orders_id = '" . (int)$order_id . "' order by sort_order");

    while ($totals = tep_db_fetch_array($totals_query)) {

    $this->totals[] = array('title' => $totals['title'],

    'text' => $totals['text']);

    }

    $this->info = array('currency' => $order['currency'],

    'currency_value' => $order['currency_value'],

    'payment_method' => $order['payment_method'],

    'cc_type' => $order['cc_type'],

    'cc_owner' => $order['cc_owner'],

    'cc_number' => $order['cc_number'],

    'cc_expires' => $order['cc_expires'],

    'date_purchased' => $order['date_purchased'],

    'orders_status' => $order['orders_status'],

    'last_modified' => $order['last_modified']);

    $this->customer = array('name' => $order['customers_name'],

    'company' => $order['customers_company'],

    'street_address' => $order['customers_street_address'],

    'suburb' => $order['customers_suburb'],

    'city' => $order['customers_city'],

    'postcode' => $order['customers_postcode'],

    'state' => $order['customers_state'],

    'country' => $order['customers_country'],

    'format_id' => $order['customers_address_format_id'],

    'telephone' => $order['customers_telephone'],

    'email_address' => $order['customers_email_address']);

    $this->delivery = array('name' => $order['delivery_name'],

    'company' => $order['delivery_company'],

    'street_address' => $order['delivery_street_address'],

    'suburb' => $order['delivery_suburb'],

    'city' => $order['delivery_city'],

    'postcode' => $order['delivery_postcode'],

    'state' => $order['delivery_state'],

    'country' => $order['delivery_country'],

    'format_id' => $order['delivery_address_format_id']);

    $this->billing = array('name' => $order['billing_name'],

    'company' => $order['billing_company'],

    'street_address' => $order['billing_street_address'],

    'suburb' => $order['billing_suburb'],

    'city' => $order['billing_city'],

    'postcode' => $order['billing_postcode'],

    'state' => $order['billing_state'],

    'country' => $order['billing_country'],

    'format_id' => $order['billing_address_format_id']);

    $index = 0;

    $orders_products_query = tep_db_query("select orders_products_id, products_name, products_model, products_price, products_tax, products_quantity, final_price from " . TABLE_ORDERS_PRODUCTS . " where orders_id = '" . (int)$order_id . "'");

     

     

    while ($orders_products = tep_db_fetch_array($orders_products_query)) {

    $this->products[$index] = array('qty' => $orders_products['products_quantity'],

    'name' => $orders_products['products_name'],

    'model' => $orders_products['products_model'],

    'tax' => $orders_products['products_tax'],

    'price' => $orders_products['products_price'],

    'final_price' => $orders_products['final_price']);

    $subindex = 0;

    $attributes_query = tep_db_query("select products_options, products_options_values, options_values_price, price_prefix from " . TABLE_ORDERS_PRODUCTS_ATTRIBUTES . " where orders_id = '" . (int)$order_id . "' and orders_products_id = '" . (int)$orders_products['orders_products_id'] . "'");

    if (tep_db_num_rows($attributes_query)) {

    while ($attributes = tep_db_fetch_array($attributes_query)) {

    $this->products[$index]['attributes'][$subindex] = array('option' => $attributes['products_options'],

    'value' => $attributes['products_options_values'],

    'prefix' => $attributes['price_prefix'],

    'price' => $attributes['options_values_price']);

    $subindex++;

    }

    }

    $index++;

    }

    }

    }

    ?>

     

     

    Thank you so much for looking at this for me. I have a terrible time with the coding as it makes no sense to me. I am kind of dyslexic. I have no problem with the English language - I guess cos I've had 40 years at it, but coding or numbers, because they appear quite random to me, I find it really hard to see the wood amongst the trees. It takes me hours!!! Hopefully I've done the quote thing right!

    [/

  2. Hi, I'm not copying from email. I click the 'invoice' button, and print that, but if I 'select all', then copy and paste into word is a no go! I was trying to find an easier way, as although I installed the sloppy words clean up, that gets bypassed if someone chooses the express check-out, and people rarely set their address out correctly - and often incompletely! Someone had their paypal address simply as - Flat 3 London!

  3. Hi, I used the previous store mode on my old site without problem. I installed this on the v2.3.3.1 and it doesn't seem to work. Everything looks okay, and all the signs show up, but it still allows check-out. I figured i'd dones something wrong, so just gone through the whole install again, but get an error when I run the SQL, maybe because I have done it before. Can anyone help - I need to be able to shut down at Christmas!!

     

    Error

     

    SQL query:

    # NEW RECORDS FOR: STORE MODE ADDON

    # THE CONFIGURATION GROUP SORT ORDER MAY BE CHANGED

    INSERT INTO configuration_group( configuration_group_id, configuration_group_title, configuration_group_description, sort_order, visible )

    VALUES ( 1501, 'Store Mode', 'Open, Closed, or Maintenance Mode', '30', '1' ) ;

     

     

    MySQL said: #1062 - Duplicate entry '1501' for key 'PRIMARY'

  4. Thank you for your comments, I live in a different 'shop' world to most! Its pretty small, stock is in my home and out buildings. I don't tell bar coded items! I sell bra making supplies. someone might order, one metre of one elastic, 2 of another (out of a box of 1000m). I need to keep them separate or when I got back to my packing desk i'd never now what was what - much of it looks similar! Smart phones etc are not so smart here! My location is very rural, internet is very poor, slow and unreliable. I set my invoice as a 'fancier' one, now if I paste it into Word it just goes funny and is essentially useless! The customer may actually benefit from items being sorted in the basket, often items are bought to match', i.e they buy 10mm silver rings, 10mm silver sliders, 16mm gold rings, 16mm gold sliders etc,. I just thought it might be an easy fix, but I guess its more complicated than I envisaged! Thank you anyway

  5. Thank you, but neither option is very suitable, I currently print an order and put it into its own basket and take these to the various locations I keep the stock and add the items I need to add, their location changes - i'm always moving items around, and I have a huge product range with a fast turn-over and ever changing stock, so I don't want to make life more complicated!

  6. Hi, I notice the error says: (/var/log/www/tep/page_parse_time.log) [<a href='function.error-log'>function.error-log</a>]: failed to open stream: No such file or directory in /hermes/bosoraweb119/b2227******/admin/includes/classes/log Surely this last bit is wrong? - should it not read logger.php? I just wonder if you have accidentally omitted a bit of code somewhere, or the ending, which would throw up an error? Just stabbing in the dark here, as I'm pretty hopeless at all things coding!

  7. Hi, hope someone can help. I've skimmed through the pages and can't see an answer. I installed easy populate very recently, so the latest install on a new oscommerce site. I had a couple of mishaps (stupidity) and had to restore previous database back-ups. This sort of thing happened a few times as I was essentially playing with it and installing various add-ons prior to going live and generally checking everything was still working along the way. Now I also added the Quantity Price Break (can't remember if this was before or after adding easy populate!), but my easy populate only downloads one price, not the additional ones. I'm thinking I may have changed the database at some point, but then because I reverted to backups, lost something along the way. I'm not sure if I've done something wrong or quite simply EP doesn't support the Quantity Price Break. If the latter is the case, then so be it, i'll cope (I wouldn't know where to start to fix it), but if I've just made a silly error, will someone please point it out!!! Everything works okay other than the inability to download/upload any additional prices.

  8. Hi, Can anyone point me to an add on to sort the items in the basket upon checkout. Previously I used to paste the order into word and sort on column 2 (the description), but as i'm printing directly from the screen now I'm not able to do this. My customers buy 20-30 items each time and they are located in different places, sometimes I miss an item and have to go back to the same place twice (which may be my outbuilding or upstairs!) its very time consuming. As they checkout I'd like the basket to sort itself in order, so all the 'elastic' for example is together. When I list items I list them in a way they automatically sort on my website: i.e Elastic - Strap - plush backed - 12mm, Black, per metre. and the next items may look exactly the same, but be white, red etc. Anyone know of such an add-on? thank you Kellie

  9. Hi, thank you so much. I had looked at admin/invoice.php, but didn't see any typeface code! That's because it wasn't there! my code was just <td> <?php echo tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br> '); ?></td> I think you must have hardcoded yours at some time, so mine was just using the default. So I added the <FONT FACE="Verdana" SIZE="2" COLOR="#000000"> to match yours and then changed the size to 4. All good. Much happier now!

  10. Hi, thank you for your help. I managed to get the postcode on the second line. as you said by adding in $cr just before the postcode to put it on a new line. Strange thing is that both the shipping address and invoice address use the same format id, that I find puzzling! Still at a loss as to changing the text size of the shipping address. I could not see anywhere in admin/orders.php that related to text size and in the stylesheet nothing that seems to relate to the addresses. I have looked through every file, and looked at my other website files, on which I HAVE managed to increase the text size of just the shipping address, but it was 6 years ago and I really haven't a clue to how I did it! So frustrating!

  11. Just installed this on an almost clean version, and I've broken my site! The price break is there, and I can add to my product, however, if you click on a product (as a customer) you get 1146 - Table 'bramaker_brastock.TABLE_PRODUCTS_PRICE_BREAK' doesn't exist

     

    select products_id, products_price, products_qty from TABLE_PRODUCTS_PRICE_BREAK where products_id in (28) order by products_id, products_qty

     

    [TEP STOP] if the customer clciks on the product already in the cart then I get this: Fatal error: Call to a member function loadProduct() on a non-object in /home/bramaker/public_html/catalog/product_info.php on line 50 sorry about the set out here, the return doesn't respond for some reason! my site - no products yet is at www.bramaker.co.uk/catalog desperately need help, cos only got 1 week to have it up and running!

  12. I've just input this contribution and it works fine, except the 'suburb' does not print on the shipping address (though it is present on the billing side). Can someone tell me where/what to change, so I can ensure that it prints the full shipping address, and also so it can put the postcode on the next line. And less importantly, but while i'm trying to get it right, which bit it is and where to make the font larger for the shipping address only. thank you

  13. 2 - is there a way to get into paypal to complete the order for the customer?

     

    Hi,

    There is never going to be a way to 'get into paypal' - thats like getting into someones bank, but maybe someone (not me!), knows a way that, for example, the administrator can log on as the customer (i.e using a master password, afterall you can easily find there email address, hence login details).

     

    When they fail to return to the site the items are still left in the basket, so if we could simply go in and finish the job and choose say 'cheque' as payment then it would still be logged against the customers account without needing further payment. You could then simply update the comments field and status to show they had paid via paypal.

     

    Previously i had a 'prepaid order' option, and emailed a customer and asked them to 're-check-out' choosing this option (which was just like the cheque option and didn't need an instant payment)- the downside being that many other people (who had paid nothing) also chose this option!

  14. Hi,

     

    My sites running reasonably smoothly, just a long term hiccup with paypal!

     

    When people pay via paypal, they sometimes shut the paypal site as soon as they think they have made the payment, hence i get their money and NOT their order details.

     

    Now i've tried a few ways around this, including sending them an email to re-do the order choosing a pre-paid option (as i've already got their money), but would you believe how many other people choose this option and think i'm going to send an order when they haven't paid!

     

    So.... i think the best way would be to beable to edit the page on paypal itself. When it comes up with 'processing your payment'. I want to beable to write something like...

     

    Do not shut this site down, ENSURE you are redirected back to our website ELSE we will NOT beable to process your order. Ideally in bold red letters! This i feel would eliminate the problem!

     

    But.... I can't find a way of editing the pages on paypal and the stupid electronic help thing keeps saying she doesn't understand my question... hopefully someone here will, and ideally provide the answer.

     

    Thank you

     

    Kellie

  15. I've gone through the installation instructions. Put all the files in place, then it says (How to...) as below. When i paste the code it says syntax error and my website is no more. I've swapped it back to the original, and the sites loading fine again. Surely there can't be an error in the code, else it would happen to everyone. So waht have i done wrong???

     

     

    How to use - adding dynamic header tags to your shop

     

    1. Open index.php (under the catalog folder or your web root) for edit:

     

    Find this code::

     

    } else {

    $category_depth = 'products'; // category has no products, but display the 'no products' message

    }

    }

    }

    Replace with::

     

    } else {

    $category_depth = 'products'; // category has no products, but display the 'no products' message

    }

    }

    //get current category tags when a category is selected

    $cat_tags_query = tep_db_query("SELECT categories_name, title_tag, desc_tag, keywords_tag FROM " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . (int)$current_category_id . "' AND language_id = '" . (int)$languages_id . "'");

    $cat_tags = tep_db_fetch_array($cat_tags_query);

    $categories_name = $cat_tags['categories_name'];

    $title_tag = $cat_tags['title_tag'];

    $desc_tag = $cat_tags['desc_tag'];

    $keywords_tag = $cat_tags['keywords_tag'];

    //set default

    $kws_home_default = $categories_name;

    $desc_home_default = $categories_name;

    $title_home_default = $categories_name;

    } else {

    //no category is selected: randomly select category names as keywords

    $cat_names_query = tep_db_query("SELECT categories_name FROM " . TABLE_CATEGORIES_DESCRIPTION . " WHERE language_id = '" . (int)$languages_id . "'" . " ORDER BY RAND()");

    $kws_home_default = "";

    $num_rows = tep_db_num_rows($cat_names_query);

    if ($num_rows > 20){

    $i = rand(1,$num_rows);

    for ($count = $i; $count < $i + 20; $count++) {

    $cat_names = tep_db_fetch_array($cat_names_query);

    $kws_home_default .= $cat_names['categories_name'] . ', ';

    }

    } else {

    while ($cat_names = tep_db_fetch_array($cat_names_query)){

    $kws_home_default .= $cat_names['categories_name'] . ', ';

    }

    }

    //default title tag for the index (home) page

    $title_home_default = "ENTER YOUR DEFAULT TITLE TEXT HERE";

    //default keywords for the index (home) page

    $kws_home_default .= STORE_NAME;

    //default Description for the index (home) page

    $desc_home_default = "ENTER YOUR DEFAULT DESCRIPTION TAG TEXT HERE FOR THE HOME PAGE";

    }

     

    NB: Replace the above "ENTER YOUR DEFAULT TITLE TEXT HERE" and "ENTER YOUR DEFAULT DESCRIPTION TAG TEXT HERE FOR THE HOME PAGE" with your default Title (in addition to the store name) and Description for the home page.

  16. okay, i m,ay have found the glitch

     

    i input my price changes directly into the code, and i see an error in the string:

     

    $shipping_table = '100:1.21,120:1.31,140:1.45,160:1.57,180:1.70,200:1.82,220:1.95,240:2.06,260:

    2.18,280:2.31,300:2.44,400:2.99,500:2.54,600:4.09,700:4.64:800:5.19900:6.74,1000:

    7.29,1100:7.79,1200:8.29,1400:9.29,1600:10.29,1800:11.29,2000:12.29,2500:36,3000

    :

    42,4000:45,5000:49,6000:51,7000:54,8000:56,9000:59,10000:61,20000:75,99000:999';

     

    i shall see it changing that cures the problem.

  17. Hi, there wasn't anmy answers in the thread - people had just posted - 'great it worked' - without saying how!

     

    this was fine before i reinstalled it, i'm presuming there is something i changed last time and haven't changed this time, but i can't see it.

     

    The code i have is below. The problem is the basket gets exceeded at probably 2kg maybe less. My customer has just checked out a heavy fabrics order for £70 to italy on free post. Need to do something fast!

     

    <?php

    /*

     

    $Id: zones.php,v 1.20 2003/06/15 19:48:09 thomasamoulton Exp $

     

     

    */

     

    class airmailsignedfor {

    var $code, $title, $description, $enabled, $num_zones;

     

    // class constructor

    function airmailsignedfor() {

    global $order;

    $this->code = 'airmailsignedfor';

    $this->title = MODULE_SHIPPING_AIRMAILSIGNEDFOR_TEXT_TITLE;

    $this->description = MODULE_SHIPPING_AIRMAILSIGNEDFOR_TEXT_DESCRIPTION;

    $this->sort_order = MODULE_SHIPPING_AIRMAILSIGNEDFOR_SORT_ORDER;

    $this->icon = DIR_WS_ICONS . 'shipping_airmail.gif'; // upload icon to catalog/images/icon directory

    $this->tax_class = MODULE_SHIPPING_AIRMAILSIGNEDFOR_TAX_CLASS;

    $this->enabled = ((MODULE_SHIPPING_AIRMAILSIGNEDFOR_STATUS == 'True') ? true : false);

    if ($order->delivery['country']['iso_code_2'] == 'GB') {

    $this->enabled = false;

    }

    // CUSTOMIZE THIS SETTING FOR THE NUMBER OF ZONES NEEDED

    $this->num_zones = 2;

    }

     

    // class methods

    function quote($method = '') {

    global $order, $shipping_weight, $shipping_num_boxes;

     

    $dest_country = $order->delivery['country']['iso_code_2'];

    $dest_zone = 0;

    $error = false;

    for ($i=1; $i<=$this->num_zones; $i++) {

    $countries_table = constant('MODULE_SHIPPING_AIRMAILSIGNEDFOR_COUNTRIES_' . $i);

    $country_zones = split("[,]", $countries_table);

    if (in_array($dest_country, $country_zones)) {

    $dest_zone = $i;

    break;

    }

    }

     

    // elari - Added to select default country if not in listing

    if ($dest_zone == 0) {

    $dest_zone = $this->num_zones; // the zone is the lastest zone avalaible

    }

    // elari - Added to select default country if not in listing

    if ($dest_zone == 0) {

    $error = true; // this can no more achieve since by default the value is set to the max number of zones

    } else {

    $shipping = -1;

    $zones_cost = constant('MODULE_SHIPPING_AIRMAILSIGNEDFOR_COST_' . $dest_zone);

     

    $zones_table = split("[:,]" , $zones_cost);

    $size = sizeof($zones_table);

    for ($i=0; $i<$size; $i+=2) {

    if ($shipping_weight <= $zones_table[$i]) {

    $shipping = $zones_table[$i+1];

    if(tep_not_null($method) )

    // Text shown on Checkout_Confirmation

    $shipping_method = ''; // Leaving this entry blank causes only the shipping title to show i.e Royal Mail 1st Class Rec

    else

    // Text shown on Checkout_shipping - Delivery Weight : 0.7 Kg's (Ships normally within 1 to 3 days)

    $shipping_method = MODULE_SHIPPING_AIRMAILSIGNEDFOR_TEXT_WAY . ' : ' . $shipping_weight . ' ' . MODULE_SHIPPING_AIRMAILSIGNEDFOR_TEXT_UNITS . ' ' . MODULE_SHIPPING_AIRMAILSIGNEDFOR_DELIVERY_TIMES;

    if ($shipping_num_boxes > 1) {

    $shipping_method .= $shipping_num_boxes . 'x ';

    }

    break;

    }

    }

     

    if ($shipping == -1) {

    $shipping_cost = 0;

    $shipping_method = MODULE_SHIPPING_AIRMAILSIGNEDFOR_UNDEFINED_RATE;

    } else {

    $shipping_cost = ($shipping * $shipping_num_boxes) + constant('MODULE_SHIPPING_AIRMAILSIGNEDFOR_HANDLING_' . $dest_zone);

    }

    }

     

    $this->quotes = array('id' => $this->code,

    'module' => MODULE_SHIPPING_AIRMAILSIGNEDFOR_TEXT_TITLE,

    'methods' => array(array('id' => $this->code,

    'title' => $shipping_method,

    'cost' => $shipping_cost)));

     

    if ($this->tax_class > 0) {

    $this->quotes['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']);

    }

     

    if (tep_not_null($this->icon)) $this->quotes['icon'] = tep_image($this->icon, $this->title);

     

    if ($error == true) $this->quotes['error'] = MODULE_SHIPPING_AIRMAILSIGNEDFOR_INVALID_ZONE;

     

    return $this->quotes;

    }

     

     

     

    function check() {

    if (!isset($this->_check)) {

    $check_query = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_STATUS'");

    $this->_check = tep_db_num_rows($check_query);

    }

    return $this->_check;

    }

     

    // elari - Added to select default country if not in listing

    function install() {

    tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Enable Zones Method', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_STATUS', 'True', 'Do you want to offer zone rate shipping?', '6', '0', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())");

    tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())");

    tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort Order', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_SORT_ORDER', '9', 'Sort order of display.', '6', '0', now())");

    for ($i = 1; $i <= $this->num_zones; $i++) {

    $default_countries = '';

    if ($i == 1) {

    $default_countries = 'AL,AD,AM,AT,AZ,BY,BE,BA,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GI,GR,GL,HU,IS,IE,I

    T,KZ,KG,LV,LI,LT,LU,MK,MT,MD,MC,NL,NO,PL,PT,RO,RU,SM,SK,SI,ES,SE,CH,TJ,TR,TM,UA,U

    Z,VA';

    $shipping_table = '100:1.21,120:1.31,140:1.45,160:1.57,180:1.70,200:1.82,220:1.95,240:2.06,260:

    2.18,280:2.31,300:2.44,400:2.99,500:2.54,600:4.09,700:4.64:800:5.19900:6.74,1000:

    7.29,1100:7.79,1200:8.29,1400:9.29,1600:10.29,1800:11.29,2000:12.29,2500:36,3000:

    42,4000:45,5000:49,6000:51,7000:54,8000:56,9000:59,10000:61,20000:75,99000:999';

    }

    if ($i == 2) {

    $default_countries = 'All Others'; // this must be the lastest zone

    $shipping_table = '100:1.93,160:2.44,200:2.94,240:3.41,280:3.88,300:4.11,400:5.32,500:6.52,600:

    7.72,700:8.92,800:10.12,900:11.32,1000:12.52,1100:13.72,1200:14.92,1300:16.12,140

    0:17.32,1500:18.52,1600:19.72,1700:20.92,1800:22.12,1900:23.32,2000:24.52,2500:66

    ,3000:70,4000:76,5000:83,6000:90,7000:97,8000:103,9000:110,10000:116,20000:165,99

    000:999';

    }

    tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Zone " . $i ." Countries', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_COUNTRIES_" . $i ."', '" . $default_countries . "', 'Comma separated list of two character ISO country codes that are part of Zone " . $i . ".', '6', '0', now())");

    tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Zone " . $i ." Shipping Table', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_COST_" . $i ."', '" . $shipping_table . "', 'Shipping rates to Zone " . $i . " destinations based on a group of maximum order weights. Example: 3:8.50,7:10.50,... Weights less than or equal to 3 would cost 8.50 for Zone " . $i . " destinations.', '6', '0', now())");

    tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Zone " . $i ." Handling Fee', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_HANDLING_" . $i ."', '5', 'If you want to add extra costs to customers for jiffy bags etc, the cost can be entered below (eg enter 1.50 for a value of £1.50)', '6', '0', now())");

    }

    }

    // elari - Added to select default country if not in listing

     

    function remove() {

    tep_db_query("delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')");

    }

     

    function keys() {

    $keys = array('MODULE_SHIPPING_AIRMAILSIGNEDFOR_STATUS', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_TAX_CLASS', 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_SORT_ORDER');

     

    for ($i=1; $i<=$this->num_zones; $i++) {

    $keys[] = 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_COUNTRIES_' . $i;

    $keys[] = 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_COST_' . $i;

    $keys[] = 'MODULE_SHIPPING_AIRMAILSIGNEDFOR_HANDLING_' . $i;

    }

     

    return $keys;

    }

    }

    ?>

  18. I've been using the above contribution for the past 12 months, made a few adaptations to suit my site. I've just tried to update the prices and it simply won't allow it. Even when i go actually into the coded files and change things it doesn't appear to save.

     

    I added another payment option and cos it won't allow me to change the original numbers whihc were as kilos, when i work in grammes, it contantly tells the customer the cart weight as been exceeded and shows a price of £0, which, they can choose! Any ideas why its not updating

     

    www.sewingchest.co.uk

     

    thanks kellie

  19. Hi,

     

    I'm looking for a simple gallery page. I have a box on my opening page whihc says 'sewing information' and has a blacnk page there just waiting to be my gallery! All i want is to beable to add a pic, whihc shows as a thumbnail and can be enlarged if wished (oh and maybe a little bit of text below), i don't mind having to upload the files through the cpanel and manually editing it, so a bit of code might do. I tried the javascript used for general thumbnails and it came up on my gallery page with the click to enlarge underneath but then had an error pop up when you clicked, and no enlarged pic.

     

    I don't want customers to beable to upload. Needs to be simple else i might botch up my site!!

     

    thank you

×
×
  • Create New...