i want month and year seperate from this month/year picker. i tried this.
i want to insert month and year to database,for that i want it seperate.i am using codeigniter frame work
var month= $("#ui-datepicker-div .ui-datepicker-month :selected").val();
        window.write(' month');
its not working.
<!--<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css">-->
<script src="../monthyear/jquery-ui.js"></script>
<link rel="stylesheet" href="jquery-ui.css">
<label for="monthYearPicker">Date :</label>
<div class="monthYearPicker" name="myDate" ></div>
<!--<input name="myDate" class="monthYearPicker" />-->
     <script>  
$(document).ready(function () {
    $(function () {
        $('.monthYearPicker').datepicker({
            changeMonth: true,
            changeYear: true,
            showButtonPanel: true,
            dateFormat: 'MM yy'
        }).focus(function () {
            var thisCalendar = $(this);
            $('.ui-datepicker-calendar').detach();
            $('.ui-datepicker-close').click(function () {
                var month = $("#ui-datepicker-div .ui-datepicker-month :selected").val();
                var year = $("#ui-datepicker-div .ui-datepicker-year :selected").val();
                thisCalendar.datepicker('setDate', new Date(year, month, 1));
            });
        });
    });
});
</script>
<style>
    .ui-datepicker-calendar {
   visibility:hidden;
}</style>