Currency symbol size

  • Posts: 11
  • Thank you received: 0
11 years 5 months ago #107322

Hello,

I want to change the relative size of a currency symbol
(for example, I want to make it "font-size: 50%")

What is the easiest way to do it?

Thanx in advance

Please Log in or Create an account to join the conversation.

  • Posts: 82759
  • Thank you received: 13346
  • MODERATOR
11 years 5 months ago #107334

Hi,

You can edit your currency via the menu System>Currency and change the symbol to for example:

<span class="font-size:50%">€</span>

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
11 years 5 months ago #107677

It seems that it doesn't work.

I've tried to replace both "Code" and "Symbol" fields with string you provided above
Following strings don't work as well:

<span class=\"font-size:50%\">€</span>
<span class='font-size:50%'>€</span>
<span style=\"font-size:50%\">€</span>
<span style='font-size:50%'>€</span>

Please Log in or Create an account to join the conversation.

  • Posts: 82759
  • Thank you received: 13346
  • MODERATOR
11 years 5 months ago #107695

You should not change the code field. Please revert it or it won't work properly.

What result do you get when you put it in the symbol field ?

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
11 years 5 months ago #107752

Ok the code field is left unchanged

When I try to replace default value in the symbol field with this string:

<span style='font-size: 9px;'>руб.</span>
The result is the symbol appearance doesn't change, and something appears below the symbol field, as you can see on the .png attached

Probably, I should insert the tags somewhere in /components/com_hikashop/views/product/tmpl/listing_price.php ?
If yes, could you point me where to put it?

Attachments:
Last edit: 11 years 5 months ago by destination_sirius.

Please Log in or Create an account to join the conversation.

  • Posts: 82759
  • Thank you received: 13346
  • MODERATOR
11 years 5 months ago #107771

I can see that the code field is not left unchanged. There is no currency code руб. in HikaShop by default. Please revert back to the default value our it won't work properly.

Regarding the display of the HTML in the form, you can change the line:

<input type="text" name="data[currency][currency_symbol]" value="<?php echo @$this->element->currency_symbol; ?>" />
to:
<input type="text" name="data[currency][currency_symbol]" value="<?php echo $this->escape(@$this->element->currency_symbol); ?>" />

in the file "form" of the view "currency" of your backend template via the menu Display->Views to fix the problem.

The following user(s) said Thank You: destination_sirius

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
11 years 5 months ago #107777

Solved

The reason to change a code was %i instead of %n by default in "format" field of "locale information"

Thank you for fast and detailed response!

Please Log in or Create an account to join the conversation.

Time to create page: 0.080 seconds
Powered by Kunena Forum