Jump to content

kozsar

Members
  • Content count

    12
  • Joined

  • Last visited

Posts posted by kozsar


  1. Hi Everybody!

     

    First of all big-big thanks for the feedback for every person who sended especially for Mr. Jan Zonjee and for the GREAT contirb!

     

    After trying lots of hours unsuccessfully manage my problem I am trying to ask some help for my problem.

     

    My problem details:

    Everything works great (minimum order quantity, rounding, volume discounts etc) except one half thing.

     

    I am selling products in different colors and of course I setted up for every product a discount category (if someone orders 5 red and 10 black thing from the same product it would count as it would be 15).

     

    The problem is with the price calculation. It doesn't corrects the price after adding 2-3 colors from the same product (of course after reaching a volume discount category) when product_info.php has is a quantity field. When the customer cicks on the update cart or if the customers logs in-out or the customer updates the quantity (at shopping_cart.php) everything is correct.

     

    I have already went through 2-3 times if it is everything correct or not, and to tell you the truth I am fully disappointed...

    I really really hope that somebody could help me out.


  2. Hi Everybody!

     

    First of all big-big thanks for the feedback for every person who sended especially for Mr. Jan Zonjee and for the GREAT contirb!

     

    After trying lots of hours unsuccessfully manage my problem I am trying to ask some help for my problem.

     

    My problem details:

    Everything works great (minimum order quantity, rounding, volume discounts etc) except one half thing.

     

    I am selling products in different colors and of course I setted up for every product a discount category (if someone orders 5 red and 10 black thing from the same product it would count as it would be 15).

     

    The problem is with the price calculation. It doesn't corrects the price after adding 2-3 colors from the same product (of course after reaching a volume discount category) JUST when the customer cicks on the update cart or if the customers logs in-out.

     

    I have already went through 2-3 times if it is everything correct or not, and to tell you the truth I am fully disappointed...

    I really really hope that somebody could help me out.


  3. 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.

     

    After searching up&down the hole internet and spending days and weeks for find the soulition I did it! Here is! THANK YOU, YOU ARE THE GUY MAN!


  4. I think at the application_top.php could be the clue, but everything seems ok:

     

     

     

    // customer adds a product from the products page

    case 'add_product' : if (isset($HTTP_POST_VARS['products_id']) && is_numeric($HTTP_POST_VARS['products_id'])) {

    //BOF qpbpp

    //$cart->add_cart($HTTP_POST_VARS['products_id'], $cart->get_quantity(tep_get_uprid($HTTP_POST_VARS['products_id'], $HTTP_POST_VARS['id']))+1, $HTTP_POST_VARS['id']);

    $cart->add_cart($HTTP_POST_VARS['products_id'], $cart->get_quantity(tep_get_uprid($HTTP_POST_VARS['products_id'], $HTTP_POST_VARS['id'])) + $HTTP_POST_VARS['cart_quantity'], $HTTP_POST_VARS['id']);

    //EOF qpbpp

     

    // denuz text attr

    tep_db_query("delete from customers_basket_text_attributes where products_id = " . $HTTP_POST_VARS['products_id'] . " and session_id = '" . $osCsid . "'");

    $attr_query = tep_db_query("select * from products_text_attributes_enabled where products_id = " . $HTTP_POST_VARS['products_id']);

    while ($attr = tep_db_fetch_array($attr_query)) {

    tep_db_query("insert into customers_basket_text_attributes values ('$osCsid', " . $HTTP_POST_VARS['products_id'] . ", " . $attr['products_text_attributes_id'] . ", '" . addslashes($HTTP_POST_VARS['products_text_attributes_' . $attr['products_text_attributes_id']]) . "');");

    }

    // eof denuz text attr

    }

    tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters)));

    break;


  5. Hello everyone,

    I have a problem to forcing the blocks granularity.

    If I set the qty block (e.g. 50) and then I change the quantity value in the product_info page (e.g. 1), when I add che article to the shopping cart the quantity is not forced to 50 but remains equal to 1, then if update the cart (by update cart button) the article quantity is update to 50. This only happens the first time that I add the article to the shopping cart, if I repeat the same operation a second time for the same article (e.g. I change the quantity value in the product_info page from 50 to 2) the quantity is forced to the minimum quantity of 50. Someone can Help me?

    In shopping_cart.php and PriceFormatter.php all seems ok.

    Thank you

     

    FMAX

     

    Hello Friends!

    Is there any solution for this? I have the same problem :(

     

    I have checked the installation 4 times, and everything looks good. No errors or anything!

    When adding a product from product_info page the quantity block forcing seems not working, but when the quantity is refreshed at the shopping cart the forcing is OK! Any solution? I am totally down :((

    It is so important for me, please help!


  6. Hi Jim,

    Nice work anyway. I have other problem... I really don't know why, but on product pages the banner isn't showing up... I don't know why... I am trying to solve this problem, but if you would have any idea about it would perfect. Yeah I am using STS 4.6.1...

    You can check out what I'am talking about:

    http://www.topnaramky.sk/catalog/

     

    And the best is that if you click only to categories it is woking good. But if you check the product details it shows only a dot... :(

     

    You could update the contrib details to show up that this banner contrib is STS compatible... (and also the readme) I think it would be nice for thousand of peaople...

    Of course after finding out the solution to my problem :)))


  7. Sorry, the forum stopped notifying me of updates to this topic yet again! That's really annoying.

     

    I would not have been of any help with the STS issues anyway since I've never tried to install this in STS. Glad you figured it out.

     

    The manual does talk about setting up a new banner group. Changing the existing group will mess up other banners. Maybe I should word that a bit more strongly.

     

    Regards

    Jim

     

    Hi Jim,

    Nice work anyway. I have other problem... I really don't know why, but on product pages the banner isn't showing up... I don't know why... I am trying to solve this problem, but if you would have any idea about it would perfect. Yeah I am using STS 4.6.1...

    You can check out what I'am talking about:

    http://www.topnaramky.sk/catalog/

     

    And the best is that if you click only to categories it is woking good. But if you check the product details it shows only a dot... :(


  8. Dear JIM!

     

    Nice contrib! Good work... but...

    PLEASE! help me! I thing i'll go crazy...

     

    The banners working good, however it always showing up at wrong place... You can check this out: http://www.topnaramky.sk/catalog

    I think I must put this code at the right place in index.php, and actually I am trying to find out where it could be, but it doesn't work... I am going insane...

    Here is the code what I'm talking about...

    <?php // Start Banner Rotator; ?>

    <tr>

    <td><?php include( DIR_WS_MODULES . FILENAME_BANNER_ROTATOR ); ?></td>

    </tr>

    <?php // End Banner Rotator; ?>

     

    So if I want to put the banners somewhere at the top of my page, where and which file I have to modify? (sts_template.html? header.php? index.php?) I've tried everything to find out why no showing up elsewhere...

    Thanks for your support!

     

    After days searching the solutions i've managed showing up the banners where I want. The first thing that it is no idea changing the banner group names... Everything is configured to 468x50 as default, so you had better not to change it. It is important to know that the default template in STS (for ex. STS_default.html) doesn't executing php...

    When i changed the banner group name the default banner showed up, but not the rotaoring... (with $banner_only)

     

    Reading the whole STS doc for three times, i've reailized that the $banner function is set up in the sts_user_code.php... So i've changed this:

     

    $sts->start_capture();

    if ($banner = tep_banner_exists('dynamic', '468x50')) {

    ?>

    <br>

    <table border="0" width="100%" cellspacing="0" cellpadding="0">

    <tr>

    <td align="center"><?php echo $sts->template['banner_only']; ?></td>

    </tr>

    </table>

    <?php

    }

    $sts->stop_capture('banner');

     

    to this:

     

    $sts->start_capture();

    if ($banner = tep_banner_exists('dynamic', '468x50')) {

    ?>

    <br>

    <table border="0" width="100%" cellspacing="0" cellpadding="0">

    <tr>

    <td align="center"><?php include( DIR_WS_MODULES . FILENAME_BANNER_ROTATOR ); ?></td>

    </tr>

    </table>

    <?php

    }

    $sts->stop_capture('banner');

     

    And Voilá, the banner-rotator is working perfect also with STS!!! Follow the steps in the readme, but you have to put the <?php include( DIR_WS_MODULES . FILENAME_BANNER_ROTATOR ); ?> thing to the sts_user_code.php!

     

    P.S.: after searching over the internet i can't beileve that only I had this problem! But the best thing, that I find the solution. This contrib is also working perfect with STS!


  9. None of those should interfere with the normal front page. I see no reason why this should not work.

     

    Regards

    Jim

     

    Dear JIM!

     

    Nice contrib! Good work... but...

    PLEASE! help me! I thing i'll go crazy...

     

    The banners working good, however it always showing up at wrong place... You can check this out: http://www.topnaramky.sk/catalog

    I think I must put this code at the right place in index.php, and actually I am trying to find out where it could be, but it doesn't work... I am going insane...

    Here is the code what I'm talking about...

    <?php // Start Banner Rotator; ?>

    <tr>

    <td><?php include( DIR_WS_MODULES . FILENAME_BANNER_ROTATOR ); ?></td>

    </tr>

    <?php // End Banner Rotator; ?>

     

    So if I want to put the banners somewhere at the top of my page, where and which file I have to modify? (sts_template.html? header.php? index.php?) I've tried everything to find out why no showing up elsewhere...

    Thanks for your support!

×