I have this code in the dynamic price layout, so far so good:
I wish this line:
to be only visible or active for Customer Group 1 AND not-logged-in customers.
I wish this line:
To be ONLY visible or active for customer groups 2 and 4 (there is not a 3 in this site).
php does not like '< >' so how can I show the respective lines for the respective price schedules (customer groups)?
Thank you!
Code:
$rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> = <actinic:variable name="RRP" />; $rawprice<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> = <actinic:variable name="ProductPriceRaw" selectable="false" />; if ( ($rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> != 0) && ($rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> > $rawprice<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" />) ) { $savepercent = round((($rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> - $rawprice<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" />) / $rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" />) * 100); $savehowmuch<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> = round($rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> - $rawprice<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" />); //echo "<h5 class='rrp'>RRP <s>".number_format((float)$rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> , 2, '.', '')."</s> You Save ".$savepercent."%</h5>"; echo "<h5 class='rrp'>RRP <s>".number_format((float)$rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> , 2, '.', '')."</s> You Save £".$savehowmuch<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" />."</h5>";
Code:
echo "<h5 class='rrp'>RRP <s>".number_format((float)$rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> , 2, '.', '')."</s> You Save £".$savehowmuch<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" />."</h5>";
I wish this line:
Code:
echo "<h5 class='rrp'>RRP <s>".number_format((float)$rrp<actinic:variable encoding="perl" name="EncodedProductAnchor" selectable="false" /> , 2, '.', '')."</s> You Save ".$savepercent."%</h5>
php does not like '< >' so how can I show the respective lines for the respective price schedules (customer groups)?
Thank you!
Comment