Wrong Conversion ? String => Int
<p>I'm having trouble converting string to int.
The array $input holds following values:</p>

<pre><code>array(3) { [0]=&gt; string(6) "30" [1]=&gt; string(2) "01" [2]=&gt; string(9) "2013" } 
</code></pre>

<p>First I remove the leading zeros, because of the octa trap. So this is my code:</p>

<pre><code>foreach ($input as $key =&gt; $var) {
        $input[$key] = trim($var,"0");
        $input[$key] = (int)$var;
    }
</code></pre>

<p>But unfortunately the result is not statisfying.</p>

<pre><code>array(3) { [0]=&gt; int(0) [1]=&gt; int(1) [2]=&gt; int(2013) }
</code></pre>

<p>30 is now zero? How is this possible?</p>
