<!--//--><![CDATA[//><!--

/*
 * _____________________________________________________________________________
 *
 *  RSZD library
 *   copyright (c) 2004-2005 Vincent Twigt (for RSZdesign)
 * _____________________________________________________________________________
 *
 *   Licensed under the terms of the GNU Lesser General Public License:
 *        http://www.opensource.org/licenses/lgpl-license.php
 *
 *   Creator website:
 *        http://www.rszdesign.com
 *
 *   File name: custom.js
 *        JavaScript functions (custom)
 *
 *        This file contains custom functions that are specific per website.
 *        Add your own JS functions here if you like.
 *
 *   Version:  1.0 ($Rev: 13 $)
 *   Created:  2005-02-16 17:18:46
 *   Modified: $Date: 2005-10-10 01:05:09 +0200 (ma, 10 okt 2005) $
 *   Id:       $Id: custom.js 13 2005-10-09 23:05:09Z Vincent $
 *
 *   File Authors:
 *        Vincent Twigt (vtwigt@rszdesign.com)
 *
 */


top.status = 'Bevaria Diemen';


// --------------------------------------
// Selects login field on document onLoad
// --------------------------------------
function selectLoginField()
{
    if (document.getElementById) {
        var login_field = document.getElementById( 'username' );
        if (login_field != null) {  login_field.focus();  }
    }
}


// --------------------------------------
// Replace Cancel button onclick event
// --------------------------------------
function cancelButtonsFix()
{
    if (document.getElementsByTagName) {
        var cancel_btns = document.getElementsByTagName('input') ;
        for (i = 0; i < cancel_btns.length; i++) {
            cancel = cancel_btns[i];
            if (cancel != null && cancel.className == 'cancelbtn') {
                cancel.onclick = function() { window.location = window.location ;  return false ; }
            }
        }
    }
}


// --------------------------------------
// Fixes lack of :hover support (IE)
// --------------------------------------
function cssHoverFix()
{
    if (document.all && document.getElementById) {
        navRoot = document.getElementById( 'nav' );
        if (navRoot != null) {
            for (i = 0; i < navRoot.childNodes.length; i++) {
                node = navRoot.childNodes[i];
                if (node.nodeName == 'LI') {
                    node.onmouseover = function() { this.className += ' hover' ; }
                    node.onmouseout = function()  { this.className = this.className.replace(' hover', '') ; }
                }
            }
        }
    }
}


// --------------------------------------
// Attach functions to the onload event
// --------------------------------------
document.attachEvent('onload', selectLoginField);
document.attachEvent('onload', cancelButtonsFix);
if (typeof(flashFix) != 'undefined') { document.attachEvent('onload', flashFix); }
document.attachEvent('onload', cssHoverFix);


//--><!]]>
