Welcome to The Coding Zone

Novelty Date Widget

I recently trawled through Wikipedia and collected a bunch of random national holidays, birthdays, and historical events for every day of the year and used javascript to make a dumb novelty calendar. Here it is in action: A few people told me they'd be interested if I packaged it into a widget, so here it is! Linking back to me is appreciated but not necessary.

A few disclaimers (click me)

One Liner Script


Just copy/paste this into the <body> of your page and the widget will appear!
<script src="https://caminus.neocities.org/codezone/nationalday.js"></script>
This creates <div id="natday"></div> where you put the script.
You can style #natday however you'd like.

Pros:

  • You literally just copy and paste one line and you're done
  • I can make changes and corrections

Cons:

  • No special date customizations
  • You rely on my site and bandwidth (it's only like a 20KB file so it should be fine?)
  • I can make changes you might not like

How to customize (optional)

Alternatively, you can host the widget on your own site and customize it to your heart's content. You can add your birthday, an important holiday I forgot, or anything else you want! You'll notice the version on my homepage is slightly different than the one available here.

  1. Download the script here (Right-click, Save As...)
  2. Upload it to your site.
  3. Make whatever changes you want!
  4. You can make it say whatever you want on any given day by changing the code. For example, Squeaky's birthday is on May 17, so by changing the code to
    "05-17": "it's Squeaky's Birthday!",
    on May 17 the widget will read something like:
  5. Add the following line to your <body> where you'd like the widget:
    <script src="nationalday.js"></script>