unable to modify currencies.php

Open to all! Ask other shopowners for help.
Post Reply
ce7
Member
Posts: 26
Joined: Tue Apr 06, 2021 12:26 am
Phoenix Version:
Has thanked: 18 times

unable to modify currencies.php

Post by ce7 »

Hi,

I have v1087 version, found currecies.php at the location
catalog/includes/system/versioned/1.0.8.6/currencies.php

I like to change if the price is 0 and not show price, but when I try to modify the code, it will show errors, such as Parse error: syntax error, unexpected 'public' (T_PUBLIC) in

Can someone please advise how to modify currencies.php with right file location and right file, thank you!


Join The Code Co-op to get access to your library in the Code Co-op Forum
heatherbell
Senior Contributor
Posts: 2540
Joined: Mon Oct 07, 2019 4:39 am
Phoenix Version:
Has thanked: 35 times
Been thanked: 243 times

Re: unable to modify currencies.php

Post by heatherbell »

ce7 wrote: Mon May 02, 2022 6:56 am I like to change if the price is 0 and not show price
Possibly wrap https://github.com/CE-PhoenixCart/Phoen ... ice.php#L2 (in a copy of the file in your template) with an if e.g.

Code: Select all

<?php if ($product->get('price') > 0) { ?>
  <h2 class="display-4 text-left text-sm-right"><?= $price ?></h2>
  <?php } ?>
which works but similar would also have to be done in product listing


Join The Code Co-op to get access to your library in the Code Co-op Forum
Post Reply