I want to build a table with header containing Months and dates without weekends on the top as the following:
.
Using HTML or JavaScript. Anyone please help me on this
I want to build a table with header containing Months and dates without weekends on the top as the following:
.
Using HTML or JavaScript. Anyone please help me on this
I would be creating a table using JavaScript. You could cycle through the dates that you wish to display. Run the check that is detailed in the answer on this SO question. It will check to determine if the date is a weekend or note. Code from question:
var day = yourDateObject.getDay();
var isWeekend = (day == 6) || (day == 0); // 6 = Saturday, 0 = Sunday
Using that as the validating statement in your loop, you can then just call document.createElement('th')
to create your header. It's pretty simple from there.