The “Old” JavaScript Event Calendar

If you're looking for the old calendar support site, including the examples, instructions, and the download files, you can find all of that here. However, I STRONGLY urge you to use the new version. The code is tighter, it offers more control over the “look and feel,” and selecting a different month does not involve a new server request.

Also, any questions that I receive about the old version will be met with the same answer: “You should upgrade to the new version.”

Having said that . . . some people have created processes which produce the DefineEvent( ) function calls which were used in the old version. And although the new version provides a .defineEvent( ) method that is “compatible” with the old function, changing those existing processes might not be practical (or possible). So, here's a quick way to solve that problem, and effectively create a direct “bridge” from the old DefineEvent( ) function to the new .defineEvent( ) method.

All you need to do is define a global JavaScript function in your page like the one below:

  1. <script type="text/javascript">
  2.   function DefineEvent(eDate, eDesc, eLink, img, imgWidth, imgHeight) {
  3.     myCalendar.defineEvent(eDate, eDesc, eLink, img, imgWidth, imgHeight);
  4.   };
  5. </script>

Be sure to use the name of your JEC object in place of “myCalendar” in line 3, and be sure to place this function definition BEFORE any calls to DefineEvent( ) that you place on your page.