SharePoint 2010 Rolling Three Months Calendar -


hi i'm trying develop 3 month rolling calendar view inserting 3 calendar webparts in page , inserting below code in cewp.

the calendars should roll previous or next respectively clicking on button 'prevmonth' , 'nextmonth'.

it seems working roll wrong. can me ?

< script type = "text/javascript" >    $(document).ready(function() {      window.settimeout(setcal, 1000);      });    var currentdate = new date();      function setcal() {    $("#prevmonth").click(prevmonth);    $("#nextmonth").click(nextmonth);      movetodate((currentdate.getmonth() + 2).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq3');    movetodate((currentdate.getmonth() + 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq2');    movetodate((currentdate.getmonth()).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq1');  }    function prevmonth() {    movetodate((currentdate.getmonth() - 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq3');    movetodate((currentdate.getmonth() - 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq2');    movetodate((currentdate.getmonth() - 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq1');  }    function nextmonth() {    movetodate((currentmonth + 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq3');    movetodate((currentmonth + 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq2');    movetodate((currentmonth + 1).tostring() + '\u002f' + currentdate.getdate().tostring() + '\u002f' + currentdate.getfullyear().tostring(), 'wpq1');  }    <  /script>


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -