Homes J3 & Homes J4

  • ricott
    Active member
  • Topic Author
  • New Member
  • New Member
More
2 years 11 months ago - 2 years 11 months ago #48627 by ricott
Homes J3 & Homes J4 was created by ricott
Problem I cannot change the currency symbol or area unit in FEATURES of the homes template joomla version 4 (it does not exist)
It is available in version 3 features - home specifics of the homes template

Please advise
Last edit: 2 years 11 months ago by ricott.

Please Log in to join the conversation.

  • milos
    Support Staff
  • Moderator
  • Moderator
More
2 years 11 months ago - 2 years 11 months ago #48630 by milos
Replied by milos on topic Homes J3 & Homes J4
Hello,

In the Joomla 4 version of the template, this can't be changed in the template options. But, you can edit some files to change the currency. To change the currency symbol in Joomla 4 version edit files:

/templates/sparky_framework/html/com_content/featured/default_item.php
/templates/sparky_framework/html/com_content/category/blog_item.php

For example, to change from $ to EUR, change this
Code:
if( $field->label == "Price") { echo '<div class="price">' . $template->params->get('currencySymbol', '$') . number_format($field->value) . '</div>'; }

to this:
Code:
if( $field->label == "Price") { echo '<div class="price">' . number_format($field->value) . ' EUR' . '</div>'; }

Also, in this file: /templates/sparky_framework/html/com_content/article/default.php change this:

Code:
if( $field->name == "price" && $field->value) { echo '<div class="price">' . $template->params->get('currencySymbol', '$') . number_format($field->value) . '</div>'; }


to this:

Code:
if( $field->name == "price" && $field->value) { echo '<div class="price">' . number_format($field->value) . ' EUR' . '</div>'; }


Regards,
Milos
Last edit: 2 years 11 months ago by milos.

Please Log in to join the conversation.

Time to create page: 0.150 seconds
Powered by Kunena Forum