Round php's number and and covert the rounded number?
<p>Round php's number and and covert the rounded number?</p>

<pre><code>$n = -5665.36;

-&gt;$new_n = round($n);

&gt;&gt;&gt; $new_n =  -5665;
</code></pre>

<p>My Approach:</p>

<pre><code>if($m=1)
  $p= $n;
if($m=10)
   $p = 5660
if($m=100)
   $p = 5600
if($m=1000)
   $p = 5000
</code></pre>

<p>Anybody know which php<code>math function</code> OR the <code>good ways</code> to do it use to get value of $p as expected here</p>
