How to add html-code inside price
12 years 3 weeks ago #170808
by Omoot
How to add html-code inside price was created by Omoot
-- url of the page with the problem -- :
ferrometiz.ru/dbg1
-- HikaShop version -- : HikaShop Essential 2.3.2
-- Joomla version -- : 3.3.3 Stable
-- PHP version -- : 5.4.31
Hello! I'm building my site according schema.org - product descriptions, addesses, etc.
So i need to add some html insertions before and after price and currency separately.
For each product there is only one price - no taxes, discounts, variants.
But i cann't find view where to make changes...
Please help!
Beforehand thank you!
-- HikaShop version -- : HikaShop Essential 2.3.2
-- Joomla version -- : 3.3.3 Stable
-- PHP version -- : 5.4.31
Hello! I'm building my site according schema.org - product descriptions, addesses, etc.
So i need to add some html insertions before and after price and currency separately.
For each product there is only one price - no taxes, discounts, variants.
But i cann't find view where to make changes...
Please help!
Beforehand thank you!
Please Log in or Create an account to join the conversation.
12 years 3 weeks ago #170813
by Xavier
Replied by Xavier on topic How to add html-code inside price
Hi,
To edit the price part you have to edit the view "product / listing_price".
To edit the price part you have to edit the view "product / listing_price".
The following user(s) said Thank You: Omoot
Please Log in or Create an account to join the conversation.
12 years 3 weeks ago #170882
by Omoot
Replied by Omoot on topic How to add html-code inside price
Xavier, thank you!
As I understand, in this file i can add something before and after price and currency. But i need to insert some code between price value and price currency.
I think i have to edit this function (which i cann't find):
The html-output of this function have to be the following:
As I understand, in this file i can add something before and after price and currency. But i need to insert some code between price value and price currency.
I think i have to edit this function (which i cann't find):
Code:
echo $this->currencyHelper->format($price->price_orig_value,$price->price_orig_currency_id);
The html-output of this function have to be the following:
Code:
<span itemprop="price">60,00</span><span itemprop="priceCurrency" content="RUB"> RUB</span>
Please Log in or Create an account to join the conversation.
12 years 3 weeks ago #170883
by Xavier
Replied by Xavier on topic How to add html-code inside price
Hi,
This function is in "administrator/components/com_hikashop/classes/currency.php".
Then you will see that there is an format_override variable, you can potentially add desired code before calling that function, add a format override, and add code after this function to have what you are looking for.
Or just edit the content of this function to what you need
This function is in "administrator/components/com_hikashop/classes/currency.php".
Then you will see that there is an format_override variable, you can potentially add desired code before calling that function, add a format override, and add code after this function to have what you are looking for.
Or just edit the content of this function to what you need
Please Log in or Create an account to join the conversation.
Time to create page: 0.200 seconds