Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2005
    Posts
    89
    Plugin Contributions
    0

    Default adding space between products

    Hello.
    I am new to Zencart and was wondering how I can go about adding some space between products on the list page below so that it doesn't look like one big run-on mess. Also it might be nice to somehow align the image with the description a little better so that it's easier to tell what image goes where etc.. Jusy trying to make it look a little better overall. Any input is appreciated. Try not to be too harsh ;)


    http://www.sandiegorecordshow.com/so...ndex&cPath=1_4

  2. #2
    Join Date
    Sep 2005
    Posts
    89
    Plugin Contributions
    0

    Default Re: adding space between products

    Actually after clicking around my page a little more I realized that I like the layout for the "new products" page so maybe there is a way to just copy it or something?

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

    Default Re: adding space between products

    There isn't a simple way to copy the new products layout. You would need to be familiar with the code to try it.

    There are a couple of ways to modify the product listing layout.
    This definition added to the end of your stylesheet.css will give some space around each element of your product listing, and put a line under each item in the list:

    .productListing-data {
    padding: 0.5em;
    border-bottom: 1px solid #33CC99;
    }

    Change the numbers as you wish; eliminate the border-bottom if you don't want the line. You can just have padding-bottom if you want.

    For more complete control of spacing, dweingart submitted a nice simple mod which can be seen here. It allows product listing columns to be addressed separately and positioned/styled.

  4. #4
    Join Date
    Sep 2005
    Posts
    89
    Plugin Contributions
    0

    Default Re: adding space between products

    Thanks for your reply.
    I used the code you sent and it helped a little but the text is still too narrow.

    Sadly I don't understand the link you sent me for the modification. I downloaded the "diif.txt" file from that thread but I'm not sure what that is or where it goes etc..

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

    Default Re: adding space between products

    The modifications go in /includes/modules/your_template/product_listing.php.

    (around line 67)
    PHP Code:
      $list_box_contents[0][$col] = array('align' => $lc_align,
                                          
    'params' => 'class="productListing-heading"',
                                          
    'text' => $lc_text );

    add
    col' . ($col + 1) . '
    as shown:
    PHP Code:
      $list_box_contents[0][$col] = array('align' => $lc_align,
                                          
    'params' => 'class="productListing-heading col' . ($col 1) . '"'//  dweingart mod
                                          
    'text' => $lc_text );

    and (around line 170)
    PHP Code:
          $list_box_contents[$rows][$col] = array('align' => $lc_align,
                                                  
    'params' => 'class="productListing-data"',
                                                  
    'text'  => $lc_text);
        } 
    add
    col' . ($col + 1) . '
    as shown:
    PHP Code:
          $list_box_contents[$rows][$col] = array('align' => $lc_align,
                                                  
    'params' => 'class="productListing-data col' . ($col 1) . '"'//  dweingart mod
                                                  
    'text'  => $lc_text);
        } 
    In your stylesheet, you can then declare styling/position for any column number.

 

 

Similar Threads

  1. v139h Featured Products Box - Adding Space in between products
    By g00glethis1 in forum Templates, Stylesheets, Page Layout
    Replies: 10
    Last Post: 29 Sep 2012, 04:41 PM
  2. adding space between containers
    By Nyx1961 in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 13 Oct 2010, 07:41 PM
  3. Adding space between categories
    By Terrill_Taylor in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 7 May 2008, 05:51 AM
  4. Adding space in between items
    By cowgirl32 in forum Templates, Stylesheets, Page Layout
    Replies: 14
    Last Post: 25 Jul 2007, 03:23 AM

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