function changeFontSize(size) {
  //43200 minutes is 30 days
  var ckUtil = new CJL_CookieUtil("baston", 43200, '/');

  if (size == null) {
    // Get the size from the cookie if it exists.
    size = ckUtil.getSubValue("font-size");

    if (size == null) {
      size = "a1";
    }
  }

  // Add the new active image 'A'.
  $('aaa').removeClassName('a-1');
  $('aaa').removeClassName('a-2');
  $('aaa').removeClassName('a-3');
  $('aaa').addClassName(size);

  // Add the new font-size css.
  $$("head").first().insert(new Element("link", {id: "tekstgrootte", rel: "stylesheet", href: "/css/baston-font-" + size + ".css", type: "text/css", media: "screen"}));

  // Save new font-size to a cookie.
  ckUtil.setSubValue("font-size", size);

}
function initFontsize() {
  changeFontSize();

  for (i = 1; i <= 3; i++) {
    $("a-" + i).observe("click", function() {changeFontSize(this.id)}, this.eventMouseDown);
  }
}

Event.observe(window, 'load', initFontsize);
