Search code examples
daypilot

How to display weekdays in DayPilot Event calendar


Does anybody know how to display week-days (monday, tuesday, ...) in DayPilot event calendar? I can only show date. http://www.daypilot.org/calendar-lite/ http://code.daypilot.org/17910/html5-event-calendar-open-source


Solution

  • You can use headerDateFormat to set the date format used in the column headers.

    The "dddd" format string will display the day of week:

    <div id="dp"></div>
    
    <script>
    
      var dp = new DayPilot.Calendar("dp");
      // ...
      dp.headerDateFormat = "dddd"; // day of week, long format (e.g. "Monday")
      dp.init();
    
    </script>
    

    See also the Header Date Format topic in the docs.