When the selected date is greater than specified date. The field validator will raise an error.
<div class="easyui-panel" style="width:100%;max-width:400px;padding:30px 60px;">
<div style="margin-bottom:20px">
<input class="easyui-datebox" label="Required Date:" labelposition="top" required style="width:100%;">
</div>
<div style="margin-bottom:20px">
<input class="easyui-datebox" label="End Date:" labelposition="top" style="width:100%;" required data-options="
validType:'md[\'10/11/2015\']'
">
</div>
</div>
<script>
$.extend($.fn.validatebox.defaults.rules, {
md: {
validator: function(value, param){
var d1 = $.fn.datebox.defaults.parser(param[0]);
var d2 = $.fn.datebox.defaults.parser(value);
return d2<=d1;
},
message: 'The date must be less than or equals to {0}.'
}
})
</script>