Page 19 of 22 FirstFirst ... 91718192021 ... LastLast
Results 181 to 190 of 220
  1. #181
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: styling product listing pages with column layout grid

    That is very strange. Your two categories are displaying in very different ways - Airbox & Filters with grid-type elements in a rows table layout, Belts in a completely stock rows layout. Do you know why that is happening? Did it happen before? I remember seeing the group of discount tables above the listing, but don't remember what style the listing elements took then.

    The fact that they are behaving differently in response to the quantity coding, with Airbox & Filters not showing at all while Belts is missing only the price, is understandable because the grid coding accumulates the whole product before adding to $list_box_contents while the rows coding adds each element of the product as it is created. Somehow the fact that the quantity code is executing wipes out everything that is being done then.

    We need some debugging. Add to the quantity code

    echo $qdt . '<br />';

    just before

    $lc_price = $qdt;//gjh42 20121127

    We also need to know why the listings are outputting in different formats. That is puzzling and could be causing any number of unknown problems, and it may not be possible to debug the apparent problem until that is sorted out.

  2. #182
    Join Date
    Jul 2011
    Posts
    138
    Plugin Contributions
    0

    Default Re: styling product listing pages with column layout grid

    sorry about the confusion, I have some custom coding that allows me to hard code based on category id whether I want it to show up in grid format or the stock row format. This actually works well besides the obvious maintenance side of it. It was this way before, but you probably did not notice because of all the discount items grouped at the very top.

    Do you need our would you like to see that bit of coding allowing the 2 layouts?

    The echo $qdt . '<br />'; bit of coding has been added and populated the discounts at the top as before.
    ZC 1.5.5
    Add ons: - Column/Grid 1.3.8 - Dual pricing 1.7 - ImageHandler3

  3. #183
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: styling product listing pages with column layout grid

    At least I can see that the $qdt code in tpl_modules_products_quantity_discounts_list.php is all working correctly. That means that the issue has to be in how the result is being processed in product_listing.php. Can you post the whole case section where you added the quantity code? Use PHP code tags (icon on the right above textbox) to make it more legible.

  4. #184
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: styling product listing pages with column layout grid

    I created a test account so I could see pricing in the discount tables, and see that they don't work correctly when prices display. For some reason,
    PHP Code:
      if ($zc_hidden_discounts_on) {
        
    $qdt .= '  <table border="1" cellspacing="2" cellpadding="2">
        <tr>
          <td colspan="1" align="center">
            ' 
    TEXT_HEADER_DISCOUNTS_OFF 
    works perfectly to start the table, but the same opening code
    PHP Code:
      } else { 
        
    $qdt .= '  <table border="1" cellspacing="2" cellpadding="2">
        <tr>
          <td colspan="' 
    $columnCount+'" align="center">
            '
    ;
      switch (
    $products_discount_type) {
        case 
    '1':
          
    $qdt .= TEXT_HEADER_DISCOUNT_PRICES_PERCENTAGE
    loses all of the
    Code:
    '  <table border="1" cellspacing="2" cellpadding="2">
        <tr>
          <td colspan="'
    when outputting prices. Try changing this line
    PHP Code:
          <td colspan="' . $columnCount+1 . '" align="center"
    to this
    PHP Code:
          <td colspan="' . ($columnCount+1) . '" align="center"

  5. #185
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: styling product listing pages with column layout grid

    (When I think about it, it is obvious that the original code was adding all of the initial string (with integer value 0) to 1 and getting 1 as an arithmetic result, then continuing with the string accumulation onto '1'.)

  6. #186
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: styling product listing pages with column layout grid

    By the way, your alternate category layout code is not working quite right. It is still handling the grid output as if it were rows content. You need to add some code to tpl_modules_product_listing.php to switch the processing there as well as in product_listing.php.

  7. #187
    Join Date
    Jul 2011
    Posts
    138
    Plugin Contributions
    0

    Default Re: styling product listing pages with column layout grid

    Quote Originally Posted by gjh42 View Post
    At least I can see that the $qdt code in tpl_modules_products_quantity_discounts_list.php is all working correctly. That means that the issue has to be in how the result is being processed in product_listing.php. Can you post the whole case section where you added the quantity code? Use PHP code tags (icon on the right above textbox) to make it more legible.
    PHP Code:
            case 'PRODUCT_LIST_PRICE':
            
    $lc_price zen_get_products_display_price($listing->fields['products_id']) . '<br />';
            
    $lc_align 'right';
            
    $lc_text =   $lc_price;
    //        $lc_text =   ' MSRP ' . $lc_price;
    //TM trying ajeh code

    //      $lc_align = 'right';
        
    $lc_price $products_discount_type zen_products_lookup($listing->fields['products_id'], $what_field 'products_discount_type');  
        if (
    $products_discount_type != 0) {
          
    $rows++;
          
    $products_id_current = (int)$listing->fields['products_id'];
          
    $quantityDiscounts = array();
          
    $products_discount_type_from zen_products_lookup($listing->fields['products_id'], $what_field 'products_discount_type_from');
    require(
    DIR_WS_MODULES zen_get_module_directory(FILENAME_PRODUCTS_QUANTITY_DISCOUNTS));
    require(
    $template->get_template_dir('/tpl_modules_products_quantity_discounts.php',DIR_WS_TEMPLATE$current_page_base,'templates'). '/tpl_modules_products_quantity_discounts_list.php'); ///tpl_modules_products_quantity_discounts_list.php contrib by gjh42 20121127
    echo $qdt '<br />';
    $lc_price $qdt;//gjh42 20121127
    }
    else
    $lc_price zen_get_products_display_price($listing->fields['products_id']) . '<br />';

    $lc_align 'right';
    $lc_text $lc_price;}

    //ending ajeh code 
    ZC 1.5.5
    Add ons: - Column/Grid 1.3.8 - Dual pricing 1.7 - ImageHandler3

  8. #188
    Join Date
    Jul 2011
    Posts
    138
    Plugin Contributions
    0

    Default Re: styling product listing pages with column layout grid

    Quote Originally Posted by gjh42 View Post
    PHP Code:
    <td colspan="' . ($columnCount+1) . '" align="center"
    I made this change on line 34 and 75 in the tpl_products_quantity_discounts_list.php
    ZC 1.5.5
    Add ons: - Column/Grid 1.3.8 - Dual pricing 1.7 - ImageHandler3

  9. #189
    Join Date
    Jul 2011
    Posts
    138
    Plugin Contributions
    0

    Default Re: styling product listing pages with column layout grid

    Quote Originally Posted by gjh42 View Post
    By the way, your alternate category layout code is not working quite right. It is still handling the grid output as if it were rows content. You need to add some code to tpl_modules_product_listing.php to switch the processing there as well as in product_listing.php.
    Thank you for catching this. It seems as though I had the override version in the wrong location so it was still using the default file. I have moved it to the correct folder but evidently there is something wrong b/c I have 0 results.

    I'm going to try and find the original post on this and see where I goofed. Probably missing syntax.
    ZC 1.5.5
    Add ons: - Column/Grid 1.3.8 - Dual pricing 1.7 - ImageHandler3

  10. #190
    Join Date
    Jul 2011
    Posts
    138
    Plugin Contributions
    0

    Default Re: styling product listing pages with column layout grid

    Quote Originally Posted by idc1 View Post
    Thank you for catching this. It seems as though I had the override version in the wrong location so it was still using the default file. I have moved it to the correct folder but evidently there is something wrong b/c I have 0 results.

    I'm going to try and find the original post on this and see where I goofed. Probably missing syntax.
    I have the correct file in the correct override location now and am getting NO error logs in my cache folder. I still have the layout issue though.
    ZC 1.5.5
    Add ons: - Column/Grid 1.3.8 - Dual pricing 1.7 - ImageHandler3

 

 
Page 19 of 22 FirstFirst ... 91718192021 ... LastLast

Similar Threads

  1. Problem with column layout grid for product listing 1.3.8
    By ivanc in forum Templates, Stylesheets, Page Layout
    Replies: 19
    Last Post: 22 Jul 2010, 11:00 AM
  2. Replies: 5
    Last Post: 17 Feb 2010, 05:13 PM
  3. Problem with Column Layout Grid for Product Listing
    By maeve100 in forum Templates, Stylesheets, Page Layout
    Replies: 8
    Last Post: 17 Aug 2009, 04:02 PM
  4. Column Grid Layout - trouble with product listing/layout
    By mellonade in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 4 May 2007, 11:18 AM
  5. Problem with Column Layout Grid for Product Listing 1.3.0.2
    By mmmfruit in forum Templates, Stylesheets, Page Layout
    Replies: 15
    Last Post: 12 Aug 2006, 04:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR