Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Edit out prices

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 03-05-2005, 09:35 AM
 
expressrugs expressrugs is offline
 

Advanced Member
  
Join Date: Feb 2005
Posts: 77
 

Default Edit out prices

Hello
V 4.0.12 What code do you take out of customer/main/products_t.tpl to not show the price. On the product page. I do want it on detail page.
Thank you for your help
__________________
4.1.3
Reply With Quote
  #2  
Old 03-05-2005, 09:53 AM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default Re: Edit out prices

Quote:
Originally Posted by expressrugs
Hello
V 4.0.12 What code do you take out of customer/main/products_t.tpl to not show the price. On the product page. I do want it on detail page.
Thank you for your help

The following is the code to look for in 4.0.12 so it should be close to the same in your version as far as the tpl is concerned. the code may have a slight difference to it, but this is the bit:

Code:
{if $active_modules.Subscriptions ne "" and $products[product].catalogprice} {include file="modules/Subscriptions/subscription_info_inlist.tpl"} {else} {if $products[product].taxed_price ne 0} {if $products[product].list_price gt 0 and $products[product].taxed_price lt $products[product].list_price} {math equation="100-(price/lprice)*100" price=$products[product].taxed_price lprice=$products[product].list_price format="%d" assign=discount} {if $discount gt 0} <FONT class="MarketPrice">{$lng.lbl_market_price}: <S> {include file="currency.tpl" value=$products[product].list_price} </S></FONT> {/if} {/if} <FONT class="ProductPrice">{include file="currency.tpl" value=$products[product].taxed_price}</FONT> <FONT class="MarketPrice">{include file="customer/main/alter_currency_value.tpl" alter_currency_value=$products[product].taxed_price}</FONT>{if $discount gt 0}, {$lng.lbl_save_price} {$discount}%{/if} {if $products[product].taxes} {include file="customer/main/taxed_price.tpl" taxes=$products[product].taxes}{/if} {else} <FONT class="ProductPrice">{$lng.lbl_enter_your_price}</FONT> {/if} {/if}

This is the subscription, enter your price, makrket price and product price codes.

Now if you want it to NOT show, simply add this to the front ==> { * and this to the end of the entire line of code you do not want to show ==> * }

This is called "comment tag" This will make the code non readable to smarty, therefore skipped.

Not sure fo you already knew that or not, so I thought I would throw it in
__________________
vs 4.1.12
Reply With Quote
  #3  
Old 03-05-2005, 10:27 AM
 
expressrugs expressrugs is offline
 

Advanced Member
  
Join Date: Feb 2005
Posts: 77
 

Default

Hello thanks for the reply. I didn't know you could use {**} It however did't work or I did it wrong it changed the detail page. Not the our price on products page. Not sure i'm trying to change right page code. Its the first page after you click Categories.
Thank you
__________________
4.1.3
Reply With Quote
  #4  
Old 03-05-2005, 10:47 AM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default

Quote:
Originally Posted by expressrugs
Hello thanks for the reply. I didn't know you could use {**} It however did't work or I did it wrong it changed the detail page. Not the price on products page. Not sure i'm trying to change right page code. Its the first page after you click Categories.
Thank you

Try this on products.tpl:



Code:
{*{else} {if $active_modules.Subscriptions ne "" and $products[product].catalogprice} {include file="modules/Subscriptions/subscription_info_inlist.tpl"} {else} {if $products[product].taxed_price ne 0} {if $products[product].list_price gt 0 and $products[product].taxed_price lt $products[product].list_price} {math equation="100-(price/lprice)*100" price=$products[product].taxed_price lprice=$products[product].list_price format="%d" assign=discount} {if $discount gt 0} <FONT class="MarketPrice">{$lng.lbl_market_price}: <S> {include file="currency.tpl" value=$products[product].list_price} </S></FONT> {/if} {/if} <FONT class="ProductPrice">{$lng.lbl_our_price}: {include file="currency.tpl" value=$products[product].taxed_price}</FONT><FONT class="MarketPrice">{include file="customer/main/alter_currency_value.tpl" alter_currency_value=$products[product].taxed_price}</FONT>{if $discount gt 0}, {$lng.lbl_save_price} {$discount}%{/if} {if $products[product].taxes} <TABLE border="0"> <TR> <TD>[img]{$ImagesDir}/spacer.gif[/img]</TD> <TD>{include file="customer/main/taxed_price.tpl" taxes=$products[product].taxes} </TR> </TABLE> {/if} {else} <FONT class="ProductPrice">{$lng.lbl_enter_your_price}</FONT> {/if} {/if} *}

Now that takes the info (pricing) from the second page after clicking on the catagory.
__________________
vs 4.1.12
Reply With Quote
  #5  
Old 03-05-2005, 10:48 AM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default

Remember expressrugs, this is in my 4.0.11 code, so yours may vary slightly, but the overall layout and basic code should be the same.
__________________
vs 4.1.12
Reply With Quote
  #6  
Old 03-05-2005, 10:57 AM
 
expressrugs expressrugs is offline
 

Advanced Member
  
Join Date: Feb 2005
Posts: 77
 

Default

Man you are awesome.
Thank you so much
__________________
4.1.3
Reply With Quote
  #7  
Old 03-05-2005, 11:00 AM
 
markwhoo markwhoo is offline
 

X-Adept
  
Join Date: Nov 2003
Posts: 799
 

Default

Quote:
Originally Posted by expressrugs
Man you are awesome.
Thank you so much

Not a problem, happy to help when I can
__________________
vs 4.1.12
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 07:25 PM.

   

 
X-Cart forums © 2001-2020