Show list price with slash and then price below it
Ok, so if you'd like to show the list price with a slash, and the price below that - you can use this code in the 3.5.x branch - doesn't work yet in the 4.0.x branch.
Code:
{if $product.price ne 0} You want to put this starting at the first {if} you see above, and ending with the last {/if} after the "enter your price" variable - this one is for product.tpl. Similarly, for the products.tpl - thumbnail page, you can use this: Code:
{if $products[product].price ne 0} Instinctual Colorado X-Cart Versions 3.5.x - 4.0.x |
replacing "Enter your price" with the price
Does this mean I have the choice of putting that code in either product.tpl or products.tpl?
|
Yes - assuming you don't want the list vs. discount price to show on one or the other page - - products.tpl controls the thumbnail view of your site and product.tpl controls the detail view of a product - you can choose to put it on either or both of those templates.
Cheers ;o) Instinctual Colorado X-Cart Versions 3.5.x - 4.0.x |
Quote:
Excellent! Now I only want to just show the listed price (products.tpl, product.tpl), which of the code should I change? Art |
only showing list price...
So you only want to show the list price - not the regular price? In the backend, under modify product there is a spot for each product to have a list price and a price - which of these do you want to show up on these two templates?
And - you want it on both the thumbnail view of the product as well as the detail view of the product - when does the user actually see the price they get? To just show list price you would modify the product.tpl code as such: Code:
{if $product.price ne 0} And for products.tpl as such: Code:
{if $products[product].price ne 0} Instinctual Colorado X-Cart Versions 3.5.x - 4.0.x |
Re: Show list price with slash and then price below it
Quote:
Does this mode work in v4.0.12? |
nope...
to my knowledge no it does not....BUT - double-check the variable names for your version - the only reason it wouldn't work is because they've slightly changed variable names, etc. - - shouldn't be that hard to get it to work on the 4.0.x branch.
Don't copy my whole snippet of code, only take into consideration the parts you need, and use the rest of the stock code in the 4.0.x branch. Take a look at the math equation for price, and the if/thens, and modify accordingly for that branch. |
All times are GMT -8. The time now is 08:55 PM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.