PHP form and java script date picker
<p>I'm trying to fix a code that was programmed by someone else and as I know bit of PHP and JS, I can't figure this one out.</p>

<p>It's a form with date picker but the date is not being saved to the correct form (I think). Any help appreciated or link to learn more (I already googled fair bit but couldn't find what I was looking for)</p>

<p>So my question is - why the $course_manual2 is empty after I choose my date?</p>

<pre><code>&lt;td class="border2"&gt;&lt;p&gt;&lt;strong&gt;Course Selection &lt;img src="enrolmentrequired.png" alt="" width="15" height="16" align="absmiddle" /&gt;&lt;br /&gt;
          &lt;/strong&gt;&lt;span&gt;
          &lt;?php 
if (isset ($course)) {
echo $course_information;
}
end;
 ?&gt;&lt;br/&gt;
          &lt;/span&gt;
       &lt;?php if ($course=="L25" || $course=="L15" || $course == "IELTS1" || $course=="IELTS2" || $course=="FLEXI")
       echo "&lt;input id=\"course_manual2\" name=\"course_manual2\" type=\"text\" size=\"25\" /&gt;&lt;br /&gt;
          &lt;span class=\"small\"&gt;&lt;a href=\"http://www.langports.com/enrolment_form/holidaydates.html\" target=\"_blank\" onclick=\"window.open('http://langports.com/enrolment_form/holidaydates.html','Queensland Public Holidays','width=350,height=450,top=350,left=150');return false;\"&gt;View Queensland Public Holiday Dates&lt;/a&gt;&lt;/span&gt;";
          ?&gt;
        &lt;/p&gt;&lt;/td&gt;
</code></pre>

<p>Here's the java script</p>

<pre><code>&lt;script type="text/javascript"&gt;
var my_cal;
ng.ready(function(){
        // creating the calendar
        my_cal = new ng.Calendar({
            input: 'course_manual2',            // the input field id
            date_format: 'j-M-Y',
            days_off:[
                      '0',
                      '6',
                      ],
            days_text: 'mid',
            dates_off:[
                       {date:2, month:0},
                       {date:26, month:0},
                       {date:6, month:3},
                       {date:7, month:3},
                       {date:9, month:3},
                       {date:25, month:3},
                       {date:7, month:4},
                       {date:11, month:5},
                       {date:15, month:7},
                       {date:31, month:7},
                       {date:1, month:9},
                       {date:25, month:11},
                       {date:26, month:11},
                       ],
            start_day: '1',
            start_date: 'year - 1',    // the start date (default is today)
            display_date: new Date(),   // the display date (default is start_date),
            num_months: '2'
        });

    });
</code></pre>

<p>So my question is - why the $course_manual2 is empty after I choose my date?</p>

<p>Thanks for your help</p>
