| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | Mark Forums Read | User manuals | Login |
$cat_products and $f_products displaying differently | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
$cat_products and $f_products displaying differently
Hi, I've come across what appears to be a bug (but may just be me doing things I shouldn't!).
I have made a bottom border for the first product box in Featured Products, then a left and bottom border for the next product (which has the class of .highlight). This works fine in Featured Products, but in subcategory products, it displays the first product with the class of .highlight, instead of the second, and it ruins the look. You can view this on the site I am working on: www.mrdtrading.co.uk/home.php?shopkey=martin The home page displays featured products correctly, but on this page you'll see the problem: http://www.mrdtrading.co.uk/Karts-By-Colour-c-31/ /customer/main/featured.tpl uses this code: {include file="customer/main/products.tpl" products=$f_products featured="Y"} whereas /customer/main/subcategories.tpl uses this code: {include file="customer/main/products.tpl" products=$cat_products} (Sorry that everything is now in bold, the forum software won't allow me to change it.) So there appears to be a bug in the way that $cat_products decides whether the first or second product should be the highlighted one - it should be the second, fourth, sixth, etc. but $cat_products is making it the first, third and fifth. I believe that /customer/main/products_list.tpl pulls through the styles using the code at line 23: <div{interline name=products additional_class=item}> as /customer/main/products_list.tpl is used by both the Featured Products page, and the category featured products, and subcategory 'all products in that subcategory' pages.
__________________
X-Cart Gold Version 4.3.2 |
|||||||
#2
|
|||||||||
|
|||||||||
Re: $cat_products and $f_products displaying differently
You need to look at the customer/main/products.tpl a bit closer... the include line simply "throws" a list of products (either $f_products for the list of featured products or $cat_products for the list of products within a specific category) into the next template being called. And if the featured="Y" is set, then the products_t.tpl is called, otherwise the products_list.tpl is called.
You need to look at the diferences between products_t.tpl and products_list.tpl for the cause of your issue...
__________________
Thanks, Rob X-Cart 4.4.5 and 4.5.4 on Linux |
|||||||||
|
#3
|
|||||||
|
|||||||
Re: $cat_products and $f_products displaying differently
Thanks for your reply Rob, but that doesn't seem to fix the problem.
I looked in products.tpl, line 28 Code:
and commented out {include file="customer/main/products_t.tpl"} and none of the pages I have mentioned were affected. (I had looked in Webmaster Mode and seen that only products_list.tpl was being called on all the pages involved.)
__________________
X-Cart Gold Version 4.3.2 |
|||||||
|
Thread Tools | Search this Thread |
|
|
|
|||
X-Cart forums © 2001-2020
|