How to convert dot to comma in smarty - prestashop

Good morning,
Prestashop 1.6 in tpl file I have something like this
{assign var=groupPrice value=$psoft[0]['price']|number_format:2:",":"."}
<span class="price groupPrice">{$groupPrice*0.23+$groupPrice|number_format:2:".":","}</span>
The results is 456.34 (for example). How to convert this dot to comma?
Thanks for help.
Kind regards

you can use that :
math|replace:".":","

In code:
number_format:2:".":","
Replace the first dot to comma. You'll get the result:
number_format:2:",":","

Related

Liquid: Converting comma separated currency to dot separated

the price-decimals on my store are by default separated by comma (e.g. 6,99 €).
Now I need to convert them into dot separated version without the currency icon (e.g. 6.99).
Does anyone know how to do this with liquid filters? I'm stuck! I don't want to change the base-formatting settings in the store.
Thank you!
Something like this should do the trick:
{{ 145 | money_without_currency | replace:',','.' }}
https://shopify.dev/api/liquid/filters/money-filters

how to remove special characters from string in volt templates

Please can anyone help me on this issue? how to remove special characters from string
Thanks in advance
You can use the filters available for Volt
https://docs.phalconphp.com/4.0/en/volt.html#filters
So your code becomes
{{ title | escape }}

Special Characters in Apache Velocity

How do I get Special Characters to show up in Apache Velocity as a string?
something like:
#include(" <Bundle>")
#include(" <Description>$!{bundle.description}</Description>")
#include(" </Bundle>")
you can use velocity escape tool.
https://velocity.apache.org/tools/devel/generic/EscapeTool.html
I took out the includes and it wrote it all as I needed it.

smarty math returns comma instead of point

doing this opperation in Smarty
{math equation=1.1+0.7 format="%.2f"}
I get a result with a comma separated decimal of 1,80
No idea of how to get a 1.80 value.
Thnx so much.
The only solution i have found is to replace the comma with a poin.
math|replace:",":"."
Hope it helps someone.

What is the Escape character for SQL snippet file

I am writing a SQL Snippet in VS2010 and I want to have "$" as a character inside the SQL Snippet, but the way the snippet recognize a variable is by bounding a word with "$". EX: $var1$
Anybody know what the escape character is for SQL Snippet in VS2010, so it won't think of it as a variable by mistake?
Thank You.
You should be able to escape it by doubling it - try $$.
Use $$ (from here: http://conceptdev.blogspot.com/2006/08/visual-studio-2005-snippets-literal.html).