Adding months to timestamp in PHP
<pre><code>        $bought_months = 6;
        $currentDate = date('Y-m-d');
        $expiring = strtotime('+'.$bought_months.' month', $currentDate); 
</code></pre>

<p>This is what i tried. </p>

<p>I am trying to get a unix timestamp value of 6 months ahead from today. </p>

<p>How can i add months to my unix timestamp right? I tried above, since my other thought - calculating by seconds like one month in seconds: 2 629 743.83 * how many months + current timestamp, will not be precise. </p>

<p>(ofcourse because months have different number of days)</p>

<p>I get "A non well formed numeric value encountered" for the code above.</p>

<p>How can i do this?</p>
