views:

95

answers:

2
$('#passport_expiry').datepicker({dateFormat: 'mm/y'});

I have the above code works. I select a date using the datepicker and it updates the textfield. The problem is that when I try to select another date, it doesn't update the textfield. It seems that when the textfield already has a value, it doesn't update it.

EDIT:

What I can add is the actual form input:

<dd>
    <label for="passport_expiry">Passport Expiry:</label>
    <input type="text" id="passport_expiry" name="passport_expiry" maxlength="150" size="65" value=""/>
</dd>
A: 

This appears to be a bug within jQuery UI. I would suggest reporting it. I tested it a few times and found that if I included a date it worked, but if I only had the month and year like you do it, it does not work.

bryall
A: 

i also get this behavior, it seems like some weird event issue, if i select a date using the keyboard then i can't change the value using the mouse and vice versa.

alan