I've stored values in an array and I want to apply conditional formatting to the output when I access them. I want the text of the values, less than or equal to 10, displayed in red or, greater than 10, displayed in green.
For example, below, I would like the resultant value of 5 to be displayed in red.
I'm a newbie to this but would assume I would need the help of CSS to achieve this.
Any advice would be appreciated.
<?php
$total_sql=array();
$total_sql[]=5;
$total_sql[]=10;
$total_sql[]=15;
$total_sql[]=20;
print($total_sql[0]);
?>