Can you please take a look at this demo and let me know how I can select /set the next closest Wednesday if today is (Sunday, Monday, Tuesday, and Wednesday OR Saturday (if today is Thursday or Friday and Saturday)
$(function(){ $("#datepicker").datepicker({ beforeShowDay:function(dt){var day = dt.getDay();return dt;}});});