Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Kennith

Pioneers
  • Posts

    49
  • Joined

  • Last visited

Posts posted by Kennith

  1. Well. Finally figured it out. For some reason the $qty was not calculated to the nearest products_qty_blocks in the adding to cart. Therefore I rewrote the script slightly. I already know it wasnt working because of another contribution because the contribution worked like a charm on a fresh installation but I have no idea which contribution caused this error.

     

    Anyone with the same problems try in includes/classes/shopping_cart.php to change:

     

    // BOF qpbpp
    if ($this->in_cart($products_id_string)) {
    $this->update_quantity($products_id_string, $qty, $attributes, $discount_category);
    } else {
    $this->contents[$products_id_string] = array('qty' => (int)$qty, 'discount_categories_id' => $discount_category);
    // EOF qpbpp

     

    into:

     

    // BOF qpbpp
    if ($this->in_cart($products_id_string)) {
    $this->update_quantity($products_id_string, $qty, $attributes, $product_info['discount_categories_id']);
    } else {
    // Berekening van aantal producten gaat niet goed zonder onderstaande code. Deze berekend de dichstbijzijnde minimale bundel afname bij het toevoegen van een product. Er word naar beneden afgerond.
    $min_order_query = tep_db_query("select p.products_qty_blocks as min_quant FROM " . TABLE_PRODUCTS . " p where p.products_id = '".$products_id_string."'");
    while ($min_order = tep_db_fetch_array($min_order_query))
    {
     if ($qty < $min_order['min_quant'])
     {
    	 $qty = $min_order['min_quant'];
     }
     if ($qty > $min_order['min_quant'])
     {	
    	 $qty = ($qty - ($qty % $min_order['min_quant']));
     }
    }
    
    $this->contents[$products_id_string] = array('qty' => (int)$qty, 'discount_categories_id' => $product_info['discount_categories_id']);
    // EOF qpbpp

     

    It will however round the final $qty down to the nearest products_qty_blocks rather then up. Math was not my best subject and I couldnt figure out how to do that.

    Thank you very much for your solution. In order to make it round up instead of Down replace this

    $qty = ($qty - ($qty % $min_order['min_quant']));

    with

    $qty = (ceil($qty / $min_order['min_quant'])*$min_order['min_quant']);

  2. I'm having a bit of a problem I use linked products in my shop. When i click view all products i shows the linked product and all it's duplicates. Is there any way I can make i show one only one of each products?

  3. I've developed a danish version of osCommerce including lots of contributions among others this one. There are several hundred users of this danish package but a small handfull are having troubles uploading images does anyone have an idea about why?

  4. WOW this i just what I was looking for unfortunately i'm one of those strange people who like IE and when trying to edit or create a new product I just get af blank page in IE7 it wors fine in firefox and Google Chrome. It's because of a script error when checking the details it says something about not beeing able to set focus on af hidden or invisible object?

     

    Does any one know how to fix this?

  5. Hi I've installed the latest version 2.05 and after som work I got it up and running smoothly. But now I found a new problem when using nested pages it works fine teh subpages unfold nicely but when I click the first subpage and only the first the tree colapces and only shows the top page this i not a problem with the following pages. If i take subpage 1 offline so it dosn't show then the problem will occour when clicking subpage 2.

     

    I hope some one has a solution for this.

  6. Hi I've been usint EP for some time now and it's been perfect but my need has changed a little. I would really like to include some custom fieds from categories and categories_description. Is that somehow possible at pressent time?

     

    I can't do any "real" coding myself but i can follow an instruction, would be really great if someone could help me. Here are my "systeminfo"

    EP vers: 2.76g-MS2

    osCommerce Online Merchant v2.2 RC1

    OS:

    HTTP: Apache/1.3.37 (Unix) Sun-ONE-ASP/4.0.2 PHP/4.4.7 mod_throttle/3.1.2 FrontPage/5.0.2.2635 mod_psoft_traffic/0.2 mod_ssl/2.8.28 OpenSSL/0.9.6b

    DB: MySQL 4.1.21-log

    PHP: 4.4.7 (Zend: 1.3.0)

     

    What would be really great was if one of the developers would consider implementing a solution like the arrays for products and products_description that works just perfect.

  7. hi

     

    I'm not sure what contribution you have installed but it should be fairly easy to do what you want to do.

     

    what page is it that you want to get rid of the price?

     

    something like

     

    Oh I'm sorry thought I posted ind the support thread for the contribution. But I have MultiGeoZone MultiTable Shippong ver. 1.2 installaled The code that I need to alter I beilieve is this

     

       function quote($method = '') {
     global $order, $shipping_weight, $shipping_num_boxes;
     	  $combined_quote_weight = ($shipping_num_boxes * $shipping_weight);
      $this->quotes = array('id' => $this->code,
    						'module' => constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_TEXT_TITLE') . ' (' . $combined_quote_weight . ' lbs)',
    						'methods' => array());
    
      $this->determineTableMethod(constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_MODE'));  
    
      if ($method) {
    	$j = substr($method, 5);
    
    	$shipping = $this->determineShipping(split("[:,]" , constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_TABLE_' . $j)));
    
    	$this->quotes['methods'][] = array('id' => 'table' . $j,
    									   'title' => constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_TABLE_' . $j . '_TEXT_WAY'),
    									   'cost' => $shipping + constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_HANDLING'));
      } else {
    	for ($j=1; $j<=$this->num_tables; $j++) {
    	  if (!tep_not_null(constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_TABLE_' . $j))) continue;
    
    	  $shipping = $this->determineShipping(split("[:,]" , constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_TABLE_' . $j)));
    
    	  $this->quotes['methods'][] = array('id' => 'table' . $j,
    										 'title' => constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_TABLE_' . $j . '_TEXT_WAY'),
    										 'cost' => $shipping + constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_HANDLING'));
    	}
      }
    
      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(constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_ICON'))) $this->quotes['icon'] = tep_image(DIR_WS_ICONS . constant('MODULE_SHIPPING_MZMT_GEOZONE_' . $this->delivery_geozone . '_ICON'), $this->title);
    
      return $this->quotes;
    }

     

    Thank you fo your replay Hope you got time to look at it again and can give memore specific help

  8. Hi this i a great contribution I've been playing around for af couple of days and it's all most perfect. I would really like it to do a check to see if the amount is zero and if that is the case I would like that "table" to be hidden.

     

    The reason is that I would like to show one option if the weight is below 20 kg and another if its above.

     

    I hope someone can help.

  9. Hi, i've been using this fine contribution for some time. I'm using ver 0.910 now I'm building a new store and I'm having a problem that I hop some one can help with.

     

    In short the problem is that the (!tep_session_is_registered('noaccount')) always return 1 and as a result I get the logof and my account links in the header navigation.

     

    I've tried overwriting my files with the once included with the contribution and I've tried replacing with the files from the old shop And as you might have figured out that didn't help.

     

    Does any one have an idea about what i should look for?

  10. Hi,

     

    I've previously used the PWA contribution without any problems but on my new project there is something wrong. I'm useing version 910 together with loginpage ala amazone ver. 1.4 I've redone the code entierly twice and I've gone through the files many times but haven't found an answer.

     

    The problem is that the tep_session_is_registered('noaccount') always return 1 I've tried to "prit" it on serval diffent pages. This is a problem because I can't hide the logof and the account pages.

     

    Does any one have any idea about whats wrong?

  11. I've just installed this great contribution and it is really great. I did a manual install and haven't had any problems what so ever. I used the version 1.2 just followed the instructions.

     

    So thank you Mark Samios for your time, effort and "sharing spirit" it's really appreciated.

     

    Best regards

    Kennith

  12. Is there any way to use "PRODUCTS_MODEL" instead of "PRODUCTS_ID" in the "SEO_TO_PRODUCTS" table?

     

    Basically, have the SEO-G contribution redirect to products using "products model #" rather than "products id #"?

     

    I'll be searching through the code but it would be great if someone could point me in the right direction.

     

    Thanks in advance for your help.

     

    I can't tell you exatly what to do, I've just installed it and I'm not really a programmer but it would seem that the file you are looking for is admin/includes/classes/seo_products

  13. Hi I just installed the shop seems to work fine but when I try to check out there is a problem, I can't choose continue the link i simply not there and I try to redeem af giftvoucher I get the following error: Parse error: syntax error, unexpected $end in xxxxxxxxxx/catalog/checkout_confirmation.php on line 399 But when I just can't see any sign og the problem since the $end dosn't exist any where in the document and the content og that line is

    <!-- footer //-->
    <?php require(DIR_WS_INCLUDES . 'footer.php'); ?>
    <!-- footer_eof //-->
    <br>
    </body>
    </html>
    <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

     

    The last line here is line 399 in the file så I also tried looking ind the application bottom file and there's no $end anywhere in that either

     

    Can someone help me solve this? I have 5 or 6 contributions installed the only one that involved the checkout_confirmation is PWA does anyone know if that is a problem?

     

     

    Kennith

  14. Let my start by saying that this is a must have for anyone and it.s really easy to install Thank you for the work that has been done here.

     

    When i Installed it i did however have one problem. When I visited my shop after all it showed was a lot of error messages but looking through them I found one thing in the beginning that was something like Warning: fopen(): Unable to access includes/GeoIP.dat this file wasnt part of the package downloded but i found it elsewhere and uploaded it and then every thing worked perfect. I tried to remove it again to provoke the error, so I could post it here to help otheres but even with out that file the problem did not come back...

     

    But anyway if you get errors like Warning: fopen(): Unable to access includes/GeoIP.dat then download it from here http://www.maxmind.com/download/geoip/database/GeoIP.dat.gz unzip it and upload it to catalog/includes/ and that shoud take care of it...

     

    Thanks again for a great contribution

    Kennith

  15. When you click on the Click to enlarge in the product page, the pop-up window opens in a sort of 2 stages. The first stage the pop-up window is small and loads the background. Then it increases in size and shows the enlarged image.

     

    Is there a way to prevet this or at least write "Loading..." the 'first' stage of the pop-up

     

    Thanks a lot.

     

     

    It is possible I've done it but I've made lots of changes and can't really explain it propperly but this contribution might help you http://www.oscommerce.com/community/contributions,3651 in a simpel way

×
×
  • Create New...