Not displaying added two months (PHP)
<p>I have a problem in my codes. Obviously, I'm beginning to program in PHP and know nothing about its advanced concepts. So I'm asking of your help. I'd like to add 2 months to the end date the user input. I tried this code below:</p>

<pre><code>protected function inputEndDate() {
    $value = $this-&gt;endDate;
    $html = "";
    $html .= '&lt;label for="enddate"&gt;End Date:&lt;/label&gt;' . PHP_EOL;
    $html .= '&lt;input type="text" readonly name="enddate" id="enddate" value="'.$value.'"&gt;';
    $html .= '&lt;input type="button" id="enddatebutton" onclick="getEndDate()"&gt;' . PHP_EOL;
    return $html;
}


protected function inputExpiryDate() {
    $value = $this-&gt;endDate;
    $date = date('Y/m/d', strtotime("$value +2 month"));
    $html = "";
    $html .= '&lt;label for="expirydate"&gt;Expiry Date:&lt;/label&gt;';
    $html .= '&lt;input type="text" readonly name="expirydate" id="expirydate" value="'.$date.'"&gt;';
    $html .= '&lt;input type="button" id="expirydatebutton" onclick="getExpiryDate()"&gt;' . PHP_EOL;
    return $html;
}
</code></pre>

<p>But when I run the program, it's not displaying the correct value; however it's displaying the added two months of its start date. Please help. Thanks.</p>
