1. Home
  2. Computing & Technology
  3. JavaScript

Calendar Popups

3. In Page

clr gif
Join the Discussion

Questions? Comments?

More of this Feature

The Script Which Calendar

Exactly the same head script can be used to embed calendars directly into the current web page as we used for creating popup calendars. The only difference is that we no longer need to call the calendar() function that creates the popup window but instead call the dispCal() function directly where we want to put the calendar in the current page. The code to display the calendar for the current month looks like this:

<script type="text/javascript">
document.write(dispCal(0,0));
</script>

You simply add that code into the body of your page where you want the calendar to appear and the result looks like this:

Explore JavaScript
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. JavaScript

©2009 About.com, a part of The New York Times Company.

All rights reserved.