为什么在使用for循环时不会填充我的选项列表

When trying to dynamically create a select box with values using php my data will not populate. All of the research I've done shows I've done this right. Can anyone point me to the right direction please.

<select name="month">
<?php
    $months = array("Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec");

    for ($x=0; $x<=11; $x++) {
        echo '<option value="' . $x+1 . '">' . $months[$x] . '</option>';
    }
?>
</select>

you should add parentheses around the $x+1

like so:

<select name="month">
<?php
    $months = array("Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec");

    for ($x=0; $x<=11; $x++) {

        echo '<option value="' . ($x+1) . '">' . $months[$x] . '</option>';
    }
?>
</select>