how to make datepicker disabled on public holiday, disabled on sunday and disabled all dates before today
<p>I'm in creating appointment form with jquery datepicker. I've search around but seems that I can't combine all function i want in the beforeshowday.
What I want from the datepicker is disabled all date before today (yesterday and the rest of it because you can't make appointment at date before today it must be later), then disabled on  every Sunday (its non working day) and public holiday (this one using array). What I saw from others is the jquery are specifically for only one function like public holiday it just an array, but how about disabled previous day and sunday?</p>

<p>I tried to follow this   articles <a href="http://articles.tutorboy.com/2010/09/03/jquery-ui-datepicker-disable-specified-dates/" rel="nofollow">http://articles.tutorboy.com/2010/09/03/jquery-ui-datepicker-disable-specified-dates/</a> but I don't know how to combine it. Can someone show me how? </p>

<p>I have this to disabled on every Sunday</p>

<pre><code> function disabledSunday(date) {
 var day = date.getDay();
 return [(day != 0), ''];
}

 $('#datepicker').datepicker({
   dateFormat: 'mm-dd-yy',
   beforeShowDay: disabledSunday
});
</code></pre>

<p>This one for alldates till today</p>

<pre><code>var date = new Date();
var m = date.getMonth(), d = date.getDate(), y = date.getFullYear();

// Disable all dates till today
$('#datepicker').datepicker({
minDate: new Date(y, m, d),
dateFormat: 'mm-dd-yy',
 });
</code></pre>

<p>This one is for specific dates such as public holiday</p>

<pre><code> // Disable a list of dates
    var disabledDays = ["5-31-2013","6-01-2013"];
    function disableAllTheseDays(date) {
 var m = date.getMonth(), d = date.getDate(), y = date.getFullYear();
 for (i = 0; i &lt; disabledDays.length; i++) {
 if($.inArray((m+1) + '-' + d + '-' + y,disabledDays) != -1) {
 return [false];
 }
    }
return [true];
}
$('#datepicker').datepicker({
dateFormat: 'mm-dd-yy',
beforeShowDay: disableAllTheseDays
});
</code></pre>

<p>How to combine these three function into one, I'm not much into Jquery and javascript</p>
