Results 1 to 7 of 7
  1. #1
    Join Date
    Oct 2004
    Location
    Southport, UK
    Posts
    4,237
    Plugin Contributions
    20

    Default How do I identify row 1 of page 2 of listing?

    Probably best to look at the problem first using IE (6 or 7)

    Using Grid layout, with 3 products per row.

    This is the standard when there are more than 2 items in a category.

    This is correct when there are only 2 products in the category and is therefore the first page of the listing.

    THIS IS MY PROBLEM when there are 2 products for the first row of the second page (and probably on the 3rd, 4th etc).

    How do I identify for the purposes of the IF statement that I use to change the alignment of the product name/price, that we are on a new page with less than 3 products?

    It's probably obvious but I can't see it - perhaps because I can hardly keep my eyes open as it's rather late!
    Development Manager @ JSWeb Ltd
    Over 15 years with Zencart

  2. #2
    Join Date
    Sep 2006
    Posts
    542
    Plugin Contributions
    0

    Default Re: How do I identify row 1 of page 2 of listing?

    I believe all you need to do is log into admin and set the columns to 2.

  3. #3
    Join Date
    Oct 2004
    Location
    Southport, UK
    Posts
    4,237
    Plugin Contributions
    20

    Default Re: How do I identify row 1 of page 2 of listing?

    I don't want the columns at 2 - I want them at 3 (that's why I gave 3 example links), but I want to balance the look when there are only 2 products on a page or "overflowing" onto a page. The positioning can be done by CSS and I've done that in the first case - I just can't figure out how to identify (in includes/modules/product_listing.php) that the "overflow" situation has arisen.

    But thanks for responding anyway.
    Development Manager @ JSWeb Ltd
    Over 15 years with Zencart

  4. #4
    Join Date
    Sep 2006
    Posts
    542
    Plugin Contributions
    0

    Default Re: How do I identify row 1 of page 2 of listing?

    I am assuming you have this contrib

    http://www.zen-cart.com/index.php?ma...products_id=77

    It comes with a style sheet.

  5. #5
    Join Date
    Oct 2004
    Location
    Southport, UK
    Posts
    4,237
    Plugin Contributions
    20

    Default Re: How do I identify row 1 of page 2 of listing?

    Yes I have that contribution installed. No it doesn't come with a stylesheet - and that's irrelevant anyway, as I'm happy with setting styles.

    Perhaps I'm not explaining my needs too well, although I was hoping the links would illustrate the problem perfectly. I suppose that what I really want to know is "If I am displaying 15 products to a page, and have more than 15 to display, which variable(s) in modules/product_listing.php will tell me that I have reached product no 17 or that I am on row 1 of a page number greater than 1?"
    Development Manager @ JSWeb Ltd
    Over 15 years with Zencart

  6. #6
    Join Date
    Oct 2004
    Location
    Southport, UK
    Posts
    4,237
    Plugin Contributions
    20

    Default Re: How do I identify row 1 of page 2 of listing?

    I've temporarily resolved the issue by altering the number of products displayed on a page, so anyone viewing the links in my first post will wonder what the problem is. However, this is a workaround, so if someone can answer the above, that would be greatly appreciated.
    Development Manager @ JSWeb Ltd
    Over 15 years with Zencart

  7. #7
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: How do I identify row 1 of page 2 of listing?

    You might look in the default product listing ... there is a counter for even and odd ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

 

 

Similar Threads

  1. v150 Product Listing Row height how to adjust?
    By oj226 in forum General Questions
    Replies: 2
    Last Post: 5 May 2012, 12:29 AM
  2. defining row height for product listing page
    By bryansummers in forum Templates, Stylesheets, Page Layout
    Replies: 7
    Last Post: 14 Mar 2011, 11:18 AM
  3. How to add a heading between row 1 and 2 on product listing page?
    By RilKen27 in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 12 Nov 2009, 10:04 PM
  4. how can i put more pics each row in the products listing page
    By jason1116 in forum General Questions
    Replies: 2
    Last Post: 19 Jun 2009, 12:24 PM
  5. How to make fixed row height in product listing?
    By chapagain in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 15 Jan 2009, 04:44 AM

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