Opencart (ocStore) 1.5 x the output of arbitrary labels instead of prices when a price value of 0.00 (zero)

A small but useful revision allows to display arbitrary text instead of a zero price value in Opencart (ocStore) 1.5 x. For example, when the price of goods is 0.00 (zero), you can print the inscription “contract Price” or “specify the Price” or in General, anything depending on your needs (also, instead of text, you can add the button code to the calling form or html code).
< h2>Opencart (ocStore) 1.5 x output arbitrary text at zero price:

In fact, the method is very simple and comes down to editing only two files. In the file:

system/library/currency.php

pre by string:

add:

and in the main language file (if the store is multilingual, then all the major files used languages):

catalog/language/russian/russian.php

add a line with the desired text:

well or shtml code instead of the example text in single quotes.

Opencart (ocStore) 1.5 x label if price 0 zero

It should also be noted that this edit affects the output of the label instead of the price not only in the catalog but also in all modules and in the shopping cart.

 

Leave a Reply

Your email address will not be published. Required fields are marked *