Krishna Kumar

Krishna Kumar

  • NA
  • 135
  • 36.7k

Event calendar not rendering with Javascript

Apr 21 2017 2:18 AM
I have an event calendar to diplay all the days. But i wnat ot hide the Weekends so i have written a javascript function to that. But it is not rendering with the calendar.
 
JavaScript
<script type="text/javascript">
$(document).ready(function () {
$('._title').parent().attr('colspan', '5'); // title row initially has a colspan of seven
$('._dayheader:first, ._dayheader:last', $('#<%= Calendar1.ClientID %>')).hide(); // remove first and last cells from day header row
$('._weekendday').hide(); // remove all the cells marked weekends
});
</script>
 
 
 
 
 
Calendar function
 
 
<ECalendar:EventCalendar ID="Calendar1" runat="server"
<TitleStyle CssClass="_title" />
<DayHeaderStyle CssClass="_dayheader" />
<WeekendDayStyle CssClass="_weekendday" />
</ECalendar:EventCalendar> 
 
 
Can Anyone help me why the javascript function is not rendering with the calendar. 
 
 
 
 

Answers (1)