X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Removing Price Brackets for Second Currency on Product Page (https://forum.x-cart.com/showthread.php?t=59358)

hlorenzo 05-16-2011 08:44 AM

Removing Price Brackets for Second Currency on Product Page
 
Hi All,

I've been struggling with this for a few days and cannot figure out the solution.

I found this thread - Price Brackets - and I did the steps mentioned there, and went into the file

skin/common_files/customer/main/alter_currency_value.tpl

i also, did it in this file too

common_files_client/customer/main/alter_currency_value.tpl

and then i edited it so the ( and ) were like <!-- ( --> and <!-- ) -->

but the price is still showing up with brackets.

any ideas?

thanks,
matt

cflsystems 05-16-2011 09:28 AM

Re: Removing Price Brackets for Second Currency on Product Page
 
First - comment it out by using smarty comments {* *}, not html comments
Second - you may need to run yourdomain/cleanup.php to see the changes

hlorenzo 05-16-2011 10:00 AM

Re: Removing Price Brackets for Second Currency on Product Page
 
Hey Steve,

Thanks for the reply. I did what you suggested but it's still not working.

Do i have to edit the file in common_files_client as well?

I ran the cleanup and refreshed the product page, but I am still seeing the ( ) around the secondary price.

thanks!
matt

cflsystems 05-16-2011 06:09 PM

Re: Removing Price Brackets for Second Currency on Product Page
 
You need to make the change in the file under the skin you are using

hlorenzo 05-16-2011 08:32 PM

Re: Removing Price Brackets for Second Currency on Product Page
 
Hm. Okay, I copied the file

cp skin/common_files/customer/main/alter_currency_value.tpl skin/MYTHEME/customer/main/

and then ran cleanup.php

but still see the brackets.

complete file is;

Code:

{*
$Id: alter_currency_value.tpl,v 1.1.2.1 2010/12/15 11:57:05 aim Exp $
vim: set ts=2 sw=2 sts=2 et:
*}
{*
Use {alter_currency value=..} smarty function for maximal performance
*}
{strip}

{if $alter_currency_value eq ""}
  {assign var="alter_currency_value" value="0"}
{/if}

{if $config.General.alter_currency_symbol ne ""}

{* (  *}

  {if $plain_text_message eq ""}
    <span class="nowrap">
  {/if}

  {alt_currency value=$alter_currency_value rate=$config.General.alter_currency_rate assign="cf_value" display_sign=$display_sign}

  {assign var="cf_value" value=$cf_value|abs_value|formatprice}

  {if $tag_id ne "" and $plain_text_message eq ""}
    {assign var="cf_value" value="<span id=\"`$tag_id`\">`$cf_value`</span>"}
  {/if}

  {$config.General.alter_currency_format|replace:"x":$cf_value|replace:"$":$config.General.alter_currency_symbol}

  {if $plain_text_message eq ""}
    </span>
  {/if}

 {* ) *}

{/if}

{/strip}


cflsystems 05-17-2011 03:11 AM

Re: Removing Price Brackets for Second Currency on Product Page
 
Then maybe you are not modifying the correct file. Use the webmaster to find out which file exactly to modify

hlorenzo 05-17-2011 08:26 PM

Re: Removing Price Brackets for Second Currency on Product Page
 
Thanks, I had already tried that but didn't help.

I did however find it with hours and hours of sleuthing.

It's in this file.

include/templater/plugins/function.alter_currency.php

I just changed the $result = "("; to blank, and same for the end $result too. and done. !!

thanks for the help! hope this helps someone else on 4.4.x

cflsystems 05-18-2011 04:27 AM

Re: Removing Price Brackets for Second Currency on Product Page
 
This has to be new in 4.4.x, it was the template file before. They started hard coding in php files so much code lately... Not good

ADDISON 05-18-2011 05:03 AM

Re: Removing Price Brackets for Second Currency on Product Page
 
Maybe they have a strong reason putting the brackets inside of a php file. In the past, I did not see the brackets inside the tpl file too. This could be a reason. Anyway, the script can be changed, and the brackets can be replaced easy directly in Admin. If empty no brackets, just a text input box.


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

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.