PHP - How to show columns with min-max values
<p>I have this simple pricing table. I'd want to insert another 2 columns displaying MIN and MAX values from column <i>$przoff</i>.
Here's a screenshot that shows how columns should look like: </p>

<p><img src="http://i.stack.imgur.com/Hovkf.jpg" alt="enter image description here"></p>

<pre><code>&lt;?php
$i=0;
while ($i &lt; $num) {

    $cod=mysql_result($result,$i,"cod_int");
    $name=mysql_result($result,$i,"nome");
    $conf=mysql_result($result,$i,"conf");
    $type=mysql_result($result,$i,"tipo");
    $cconf=mysql_result($result,$i,"cost");
    $cunit=mysql_result($result,$i,"costo_prod");
    $incqta=mysql_result($result,$i,"incid_qta");

    $inconf=($cconf*$incqta/100)+($cunit*$incqta/100);

    if ($cunit &gt; 0 &amp;&amp; $cunit &lt;= 0.2500) {
        $incprd=$cunit*10/100; }
    elseif ($cunit &gt; 0.2500 &amp;&amp; $cunit &lt;= 0.5000) {
        $incprd=$cunit*5/100; }
    else {
        $incprd=0; }

    $przoff=($cconf+$cunit+$inconf+$incprd);
?&gt;

&lt;tr&gt;
/* TABLE CONTENT */
&lt;/tr&gt;

&lt;?php $i++; } ?&gt;
</code></pre>
