Generate Randomy birth date
<p>This is my code:</p>

<pre><code>$curr_year = date('Y');
$dob_year  = rand($curr_year-18,$curr_year-47);
$dob_month = rand(01,12);
$dob_day   = rand(01,30);

echo $dob = $dob_month.'/'.$dob_day.'/'.$dob_year;
</code></pre>

<p>And I am getting result as <code>1/2/1988</code>, but my requirement is result should be <code>01/02/1988</code></p>
