$('#calendar').fullCalendar
(
{
editable: true,
events:
$.ajax
(
{
type: "POST",
url: "Calender.aspx/GetCDCatalog",
contentType: "application/json; charset=utf-8",
data: "{}",
dataType: "json"
}
)
}
)
calender.aspx is page and getcddialog is function which return type is array which doest not bind calender.
public CD[] GetCDCatalog()
{
XDocument docXML =
XDocument.Load(Server.MapPath("mydata.xml"));
var CDs =
from cd in docXML.Descendants("Table")
select new CD
{
title = cd.Element("title").Value,
star = cd.Element("star").Value,
endTime = cd.Element("endTime").Value,
};
return CDs.ToArray<CD>();
}