﻿// master JS client-side script functions.
// copyright Next6Exits

function a(str) { //quick alert
    alert(str);
}

function d(id) { //get DOM element by id independently
    var ie = (document.all);
    var ns4 = document.layers ? true : false;
    var dom = document.getElementById && !document.all ? true : false;

    if (dom) return document.getElementById(id);
    else if (ie) return document.all[id];
    else if (ns4) return document.layers[id];

}

function imgPop(isStage,imgRef,w,h) { //n6e image viewer
    window.open(isStage+"/n6e/imageViewer.aspx?id=" + imgRef, "imgPop", "toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=" + w + ",height=" + h);
    return false
}

function n6e() { //the onload event, leave empty if not required
    //no onload functions used at present.
}

function emailFormValidate() { //called from an email form when validation active.
    alert("N6E Email Form Validation");
    //return false;
}

function n6eTextArea(id) {
    if (d(id).value == 'Please enter...') { d(id).value = ''; }
}