Split the long digit into small in php
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/5402835/how-to-display-number-in-a-certain-format-in-php">how to display number in a certain format in php</a>  </p>
</blockquote>



<p>I have following digit : <code>3234.54554545545</code></p>

<pre><code>I want to split it like 3234.54, means I want to display only 2 char after dot.

Following is something I am trying but its not working

&lt;?php
$v = "3234.54554545";
$pos = strpos($v, '.');
$r = substr($v, count($pos) - 3);
echo $v."".$r;
?&gt;
</code></pre>

<p>Actual result: <code>3234.54554545545</code>
Desired output : <code>3234.54</code></p>

<p>Please help me. Thanks</p>
