Hi everyone, I have had this issue for several months. I made lots of research about it to no avail. Actually, I am building a website using ASP.NET MVC. I woud like to have an events calendar on the sidebar of the master page, with formatted dates that
have events. If the day is clicked, it should open a webpage with events details on that day. The calendar retrieves the events from SQL Server and formats the dates. The administrator stores the events, and the user can only check on them from the calendar.
Please, could anyone help me with precise and concise explanation. A sample code would even be more helpful.
you can achieve this with a combination of javascript(jquery + ajax being the obvious choice) However, from your question, I understand you are thinking in WebForms way(events), not in MVC way. Please follow MVC Music Store/NerdDinner tutorials first
Hi, thank you for your quick reply. Actually, I do not have much experience in Ajax/jQuery. Also, I have already taken a look at Dinner/Music Store project but they do not help that much. Thank you, though.
Thank you for your quick reply. I have already done some research on full, and that is exactly NOT what I am looking for. I just want a small month calendar on the sidebar where a user can click on days that have events to open a page with those events'
details. Here is an example of what I want:
riphamilton
Member
4 Points
3 Posts
Events Calendar on ASP.NET MVC
Mar 19, 2011 08:37 AM|LINK
Hi everyone, I have had this issue for several months. I made lots of research about it to no avail. Actually, I am building a website using ASP.NET MVC. I woud like to have an events calendar on the sidebar of the master page, with formatted dates that have events. If the day is clicked, it should open a webpage with events details on that day. The calendar retrieves the events from SQL Server and formats the dates. The administrator stores the events, and the user can only check on them from the calendar. Please, could anyone help me with precise and concise explanation. A sample code would even be more helpful.
Thank you in advance.
ignatandrei
All-Star
134491 Points
21566 Posts
Moderator
MVP
Re: Events Calendar on ASP.NET MVC
Mar 19, 2011 10:00 AM|LINK
raduenuca
All-Star
24675 Points
4250 Posts
Re: Events Calendar on ASP.NET MVC
Mar 19, 2011 10:01 AM|LINK
There are some jQuery plugins for that:
Both of them use JSON as the source of the events they display. Just read their documentation:
Radu Enuca | Blog
riphamilton
Member
4 Points
3 Posts
Re: Events Calendar on ASP.NET MVC
Mar 19, 2011 06:22 PM|LINK
<div style="color: #000000; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; width: 100%; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: #ffffff; margin: 8px;">
Hi, thank you for your quick reply. Actually, I do not have much experience in Ajax/jQuery. Also, I have already taken a look at Dinner/Music Store project but they do not help that much. Thank you, though.
</div>riphamilton
Member
4 Points
3 Posts
Re: Events Calendar on ASP.NET MVC
Mar 19, 2011 06:55 PM|LINK
Thank you for your quick reply. I have already done some research on full, and that is exactly NOT what I am looking for. I just want a small month calendar on the sidebar where a user can click on days that have events to open a page with those events' details. Here is an example of what I want:
http://soccernet.espn.go.com/scores?cc=5901
Thank you, once again, for your response.
Forest Cheng...
Star
8370 Points
819 Posts
Re: Events Calendar on ASP.NET MVC
Mar 21, 2011 04:55 AM|LINK
Hi Riphamilton,
You can try to use the onSelect event of Datepicker Jquery plug-in, something like this:
$('.selector').datepicker({ onSelect: function(dateText, inst) { ... }});In the onSelect function, post the dataText to a action method, which retrurn a partial view to update the result section.
Hope this helpful,
Forest Cheng
If you have any feedback about my replies,please contact msdnmg@microsoft.com.
Microsoft One Code Framework