| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
How to display the price of a specific productid? | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
How to display the price of a specific productid?
hi Б─⌠ i've got an easy one:
How do i simply display the price of a specified item in the catalog? I've tried Code:
I am trying to display the price of the item with the xcart-given productid of 393. This is in a customized products.tpl template that is loaded with the following command: Code:
Y'all can see what I'm talking about: http://www.kitkraft.biz/customer/home.php?cat=35 *** Update (removed first one Б─⌠ no longer relevant) *** So I found how to get the prices, and how to get the array in the right order (It was because of mod_sort, as I suspected). But... I have a new problem: The $products array only contains the price info on the first 12 products, because thats what I have set my "maximum products per page" option to in the admin section. I have tried modifying the products.php to put a different value into $objects_per_page, but that variable apparently doesn't have to do with what goes in the $products array. I think I'm right in assuming that somewhere in products.php, $config["Appearance"]["products_per_page"] is used to determine how much info gets put into $products. Based on that, though, I can't seem to figure this one out. My goal is to make it so that $products contains all of the pricing info for the whole category, not just one page at a time. I'll have to work this into an if statement that only does this for those categories which need it. Any of you experts out there been through this already? |
|||||||
#2
|
|||||||
|
|||||||
Re: How to display the price of a specific productid?
Well damn! I resolved this one immediately after I posted the last message. For anyone else out there in the same boat, heres what I found:
In products.php, the $first_page in the code below restricts what goes into $products to whatever is on the first page (duh right?) Code:
So to solve my problem, I just made an if statement that removes when I need all of the prices for the whole category: Code:
I wonder if this will ever help anyone... |
|||||||
|
|||
X-Cart forums © 2001-2020
|