hakkatil
VP-CART New User
109 Posts |
Posted - August 30 2002 : 18:17:47
|
Someone asked for this code but i cant find it. Anyway here it is.
This piece of code displays "You Save: $12.55" and puts strikes on retail price.Ex:
$24.55 Retail Price: $69.55 You save: $45.00
Open shopproductformat.asp then find these lines around 243 under Sub FormatPrice
if strRetailPrice> 0 then response.write ProdRetailPriceStart & LangProductRetailPrice & shopformatcurrency(strRetailPrice,decimalpoint) end if
replace it with this one
if strRetailPrice> 0 then response.write ProdRetailPriceStart & LangProductRetailPrice & "<strike>" & shopformatcurrency(strRetailPrice,decimalpoint) & "</strike>" yousave=strRetailPrice-strPrice response.write "<BR>" &"<font color=red>You save: </font>" & shopformatcurrency(yousave,decimalpoint) & ProdRetailPriceEnd end if
lastly, define yousave inside the sub
Ex: dim yousave
Note: Make sure that Retail Price is bigger than discounted price.
HAKAN
Edited by - hakkatil on August 30 2002 18:21:31 |
|
greatphoto
VP-CART Super User
USA
304 Posts |
Posted - June 26 2005 : 21:22:20
|
Nice post. Just wanted to give an update on this. I just tried this out, and once I was in the code, I found there is something similar already there in version 5.50! Its based on the xproductdisplaysaving config. If this is set to yes, then a discount amount will be shown.
Only problem for me is that I'm using product templates, and my templates don't call this subroutine. For doing this with templates, this topic is useful reading: http://www.vpasp.com/virtprog/vpaspforum/topic.asp?TOPIC_ID=2301
Edited by - greatphoto on June 26 2005 22:48:52 |
|
|