How do I call the onBeforeShow event with mobiscroll?
$('#starttime').mobiscroll('setValue', value).time({
theme: 'jqm',
display: 'modal',
mode: 'clickpick',
stepMinute: 10,
onBeforeShow:
});
I need to set the time right before it shows. If I try to do it on document ready the input field isn't ready yet with the value...
Edit
I tried:
$('#starttime').mobiscroll('setValue', value).time({
theme: 'jqm',
display: 'modal',
mode: 'clickpick',
stepMinute: 10,
onBeforeShow: function(html, inst) {
start = $('#starttime').val();
var a = moment();
var value = a.format('h:mm A');
}
});
but then I'm getting the error: 'value is not defined'...