[X]

Falling Hearts

page decoration 1999 still works

The snow script with the flake swapped for a heart. Valentine's Day, every year.

In 2026: Works. Change the character on line 3 for stars, shamrocks, pumpkins or bats.

Where it came from: The falling snow script with the glyph swapped, retagged for February. Free script archives, 1999. Wikipedia

<script language="JavaScript">
var GLYPH = "\u2665";      // \u2605 star  \u2618 shamrock  \u{1F383} pumpkin
var COLOR = "#FF3366";
var bits = [];
for (var i = 0; i < 24; i++) {
  var b = document.createElement("div");
  b.innerHTML = GLYPH;
  b.style.cssText = "position:fixed;pointer-events:none;z-index:9998;color:" + COLOR
    + ";font-size:" + (10 + Math.random() * 16) + "px";
  document.body.appendChild(b);
  bits.push({ el: b, x: Math.random() * window.innerWidth,
              y: Math.random() * -600, s: 1 + Math.random() * 2,
              a: Math.random() * 6.28 });
}
setInterval(function () {
  for (var i = 0; i < bits.length; i++) {
    var b = bits[i];
    b.y += b.s; b.a += 0.05;
    if (b.y > window.innerHeight) { b.y = -30; b.x = Math.random() * window.innerWidth; }
    b.el.style.left = (b.x + Math.sin(b.a) * 26) + "px";
    b.el.style.top = b.y + "px";
    b.el.style.transform = "rotate(" + (b.a * 20) + "deg)";
  }
}, 33);
</script>
sandboxed demo · breaks nothing but itselfrestart

More in page decoration

all 8 in page decoration › · the whole library ›