var eCWState = { Normal:1, Minimized:2, Collapsed:4, Docked:8, Maximized:16 };
var eCWStyle = { Normal:1, Tool:2, Popout:4, Menu:8 };
//  eCWSide and eCDPosition values (Top, Right, Bottom, Left) must match
var eCWSide = { Top:1, Right:2, Bottom:4, Left:8 };
var eCDPosition = { Float:0, Top:1, Right:2, Bottom:4, Left:8, All:15 };
////////////////////////////////////////////
var eCCDirection = { None:0, Up:1, Right:2, Down:4, Left:8 };
var eCDCType = { Unknown:0, Multiple:1, String:2, Number:4, Currency:8, DateTime:16, Color:32, Font:64, Enumeration:128, Selection:256 };
var eCCOrientation = { Float:0, Horizontal:1, Vertical:2 };
var eCCAlign = { Default:0, Left:1, Center:2, Right:4, Stretch:8, Float:16 };
var eCCVAlign = { Default:0, Top:1, Middle:2, Bottom:4, Stretch:8, Float:16 };
var eCBState = { Normal:1, Hover:2, Down:4 };
var eCMIType = { Header:1, Normal:2, Separator:4, Radio:8, Check:16 };
var eCCBorderStyle = { Solid:0, Raised:1, Lowered:2, LoweredBevel:6, RaisedBevel: 5, LoweredOutline:10, RaisedOutline:9, Inset:16, Sizeable:32 };
var bufferChars = new Array('#', '|', '~', '[', ']', '(', ')', ';', ':', '!', '@', '$', '^', '*', '(', ')', '-', '_');//, '/', '?', '+');
var eCObjectType = { None:0, Browser:1, Session:2, Window:4, Control:8 };
var eCDataObjectType = { Undefined:0, Database:1, Index:2, Hashfile:4, Table:8, Transformation:16, Pattern:32, MetaPattern:64, Object:128 };
var eCColorShade = { Unknown:0, White:1, Grey:2, Blue:4, Green:8, Purple:16, Yellow:32, Orange:64, Pink:128, Red:256, Brown:512 };

    //         number, number
function cWCord(x, y) {
    if(isNaN(x)) { if((x.indexOf('%') >= 0) || (x.toLowerCase() == 'auto')) { this.X = x; } else { this.X = 0; } } else { this.X = x - 0; }
    if(isNaN(y)) { if((y.indexOf('%') >= 0) || (y.toLowerCase() == 'auto')) { this.Y = y; } else { this.Y = 0; } } else { this.Y = y - 0; }
}
function BufferAsArray(data, level) {
    if(data.indexOf(BufferChar(level)) >= 0) { return(true); }
    if(level >= bufferChars.length - 2) {
        if(data.indexOf(bufferChars[bufferChars.length - 2]) >= 0) { return(true); }
        if(data.indexOf(bufferChars[bufferChars.length - 1]) >= 0) { return(true); }
    } else {
        for(var i = level; i < bufferChars.length; i++) {
            if(data.indexOf(bufferChars[i]) >= 0) { return(true); }
        }
    }
    return(false);
}
function BufferChar(level) {
	if(level >= (this.bufferChars.length - 2)) {
		return(bufferChars[bufferChars.length - 2] + (level - (bufferChars.length - 2)) + bufferChars[bufferChars.length - 1]);
	} else {
		return(bufferChars[level]);
	}
}
function BufferIn(data) {
    return(RealBufferIn(data, 1));
}
function BufferOut(data) {
    return(RealBufferOut(data, 1));
}
function RealBufferIn(data, level) {
	var ret;
	if(BufferAsArray(data, level)) {
		ret = data.split(BufferChar(level));
		if(ret.length > 0) {
			for(var i = 0; i < ret.length; i++) {
				ret[i] = RealBufferIn(ret[i], level + 1);
			}
		}
	} else {
	    data = data+'';
		for(var i = (bufferChars.length - 1); i >= 0; i--) {
			data.replace(bufferChars[0] + i, bufferChars[i]);
		}
		ret = base64_decode(data)+'';
	}
	return(ret);
}
function RealBufferOut(data, level) {
	var ret = '';
	if((typeof(data) == 'object') && (data instanceof Array)) {
		if(data.length > 0) {
			for(var i = 0; i < data.length; i++) {
				data[i] = RealBufferOut(data[i], level + 1);
			}
		}
		ret = data.join(BufferChar(level));
	} else {
		ret = base64_encode(data+'');
		for(var i = 0; i < bufferChars.length; i++) {
			ret.replace(bufferChars[i], bufferChars[0] + i);
		}
	}
	return(ret);
}
function ControlsAreEqual(control1, control2) {
    if((control1 == null) && (control2 == null)) { return(true); }
    if((control1 == null) || (control2 == null)) { return(false); }
    if(control1.TypeOf != control2.TypeOf) { return(false); }
    if(control1.BaseType != control2.BaseType) { return(false); }
    switch(control1.BaseType) {
        case "Browser":
            return(true);
            break;
        case "Session":
            if(control1.ID == control2.ID) { return(true); }
            break;
        case "Window":
            if((control1.Parent.ID == control2.Parent.ID) && (control1.ID == control2.ID)) { return(true); }
            break;
        case "Control":
            if((control1.ParentWindow.Parent.ID == control2.ParentWindow.Parent.ID) && (control1.ParentWindow.ID == control2.ParentWindow.ID) && (control1.ID == control2.ID)) { return(true); }
            break;
    }
    return(false);
}
function ObjectReference(obj) {
    var a = new Array();
    switch(obj.BaseType) {
        case "Browser":
            return(new cReference(obj.BaseType, a));
            break;
        case "Session":
            a.push(obj.ID);
            return(new cReference(obj.BaseType, a));
            break;
        case "Window":
            a.push(obj.Parent.ID);
            a.push(obj.ID);
            return(new cReference(obj.BaseType, a));
            break;
        case "Control":
            a.push(obj.ParentWindow.Parent.ID);
            a.push(obj.ParentWindow.ID);
            a.push(obj.ID);
            return(new cReference(obj.BaseType, a));
            break;
    }
}
function ReverseObjectType(type) {
    switch(type) {
        case "Browser":
            return(eCObjectType.Browser);
        case "Session":
            return(eCObjectType.Session);
        case "Window":
            return(eCObjectType.Window);
        case "Control":
            return(eCObjectType.Control);
        case eCObjectType.Browser:
            return("Browser");
        case eCObjectType.Session:
            return("Session");
        case eCObjectType.Window:
            return("Window");
        case eCObjectType.Control:
            return("Control");
    }
}
function EventObj(e) {
    if(!e) { e = event; }
    return e.target || e.srcElement;
}
function GetAlignmentCords(align, defaultalign, fixed, x, width, prefwidth, minwidth, allowx, allowwidth) {
    var ret = new Object();
    var pw = prefwidth; var w = width; var mw = minwidth; var aw = allowwidth;
    if((pw+'').toLowerCase() == 'auto') { pw = aw; }
    if((w+'').toLowerCase() == 'auto') { w = pw; }
    if((mw+'').toLowerCase() == 'auto') { mw = pw; }
    if((aw+'').toLowerCase() == 'auto') { aw = pw; }
    if(align == eCCAlign.Default) { align = defaultalign; }
    if((w+'').indexOf('%') >= 0) { w = (parseInt(w.replace('%', '')) / 100) * aw; }
    if((mw+'').indexOf('%') >= 0) { mw = (parseInt(mw.replace('%', '')) / 100) * aw; }
    if(isNaN(pw)) { pw = aw; }
    if((!isNaN(pw)) && (pw < 0)) { if(!isNaN(w)) { pw = w; } else { pw = aw; } }
    if(fixed == true) { mw = w; }
    if(isNaN(mw)) {
        if(w < prefwidth) {
            if(w < aw) {
                mw = w;
            } else {
                mw = aw;
            }
        } else {
            if(pw < aw) {
                mw = pw;
            } else {
                mw = aw;
            }
        }
    }
    if(width < mw) { width = mw; }
    ret.X = allowx; ret.Width = aw; ret.MinWidth = mw; ret.FixedWidth = 0; ret.StretchWidth = 0; ret.StretchPreCalcWidth = 0;
    if(align == eCCAlign.Float) {
        if((x + w) <= aw) {
            ret.X = allowx + x;
            ret.Width = w;
        } else {
            if(w <= aw) {
                ret.X = (allowx + aw) - w;
                ret.Width = w;
            }
        }
    } else {
        if(w <= aw) {
            switch(align) {
                case eCCAlign.Left:
                    if((x + w) > aw) {
                        ret.X = (allowx + aw) - w;
                    } else if(x < 0) {
                        ret.X = allowx;
                    } else {
                        ret.X = allowx + x;
                    }
                    break;
                case eCCAlign.Center:
                    if((x + ((aw / 2) + (w / 2))) > aw) {
                        ret.X = (allowx + aw) - w;
                    } else if((x + ((aw / 2) - (w / 2))) < 0) {
                        ret.X = allowx;
                    } else {
                        ret.X = allowx + x + ((aw / 2) - (w / 2));
                    }
                    break;
                case eCCAlign.Right:
                    if((aw - x) > aw) {
                        ret.X = (allowx + aw) - w;
                    } else if((aw - (x + w)) < 0) {
                        ret.X = allowx;
                    } else {
                        ret.X = allowx + (aw - (x + w));
                    }
                    break;
            }
            ret.Width = w;
        }
    }
    if(fixed == true) { ret.MinWidth = ret.Width; ret.FixedWidth = ret.Width; } else { ret.StretchWidth = ret.Width; ret.StretchPreCalcWidth = pw; }
    return(ret);
}
function GetAlignmentFromString(align) {
    var ret = eCCAlign.Default;
    if(align.length > 0) {
        switch(align.substring(0, 1).toLowerCase()) {
            case 'l':
                ret = eCCAlign.Left;
                break;
            case 'c':
                ret = eCCAlign.Center;
                break;
            case 'r':
                ret = eCCAlign.Right;
                break;
            case 's':
                ret = eCCAlign.Stretch;
                break;
            case 'f':
                ret = eCCAlign.Float;
                break;
        }
    }
    return(ret);
}
function GetBorderStyleFromString(borderstyle) {
    var ret = new Object();
    ret.Style = eCCBorderStyle.None;
    ret.Size = 0;
    ret.Color = '#000000';
    if(borderstyle.length > 1) {
        var tA = borderstyle.split(' ');
        switch(borderstyle.substring(0, 2).toLowerCase()) {
            case 'so':
                ret.Style = eCCBorderStyle.Solid;
                if(tA.length > 1) {
                    ret.Size = parseInt(tA[1]);
                    if(tA.length > 2) { ret.Color = tA[2]; }
                }
                break;
            case 'rn':
                ret.Style = eCCBorderStyle.Raised;
                break;
            case 'ln':
                ret.Style = eCCBorderStyle.Lowered;
                break;
            case 'lb':
                ret.Style = eCCBorderStyle.LoweredBevel;
                break;
            case 'rb':
                ret.Style = eCCBorderStyle.RaisedBevel;
                break;
            case 'lo':
                ret.Style = eCCBorderStyle.LoweredOutline;
                break;
            case 'ro':
                ret.Style = eCCBorderStyle.RaisedOutline;
                break;
            case 'in':
                ret.Style = eCCBorderStyle.Inset;
                break;
            case 'sz':
                ret.Style = eCCBorderStyle.Sizeable;
                break;
        }
    }
    return(ret);
}
function GetDockPositionFromString(position) {
    var ret = eCDPosition.Float;
    position = position.toLowerCase();
    if(position.indexOf('all') >= 0) {
        ret = eCDPosition.All;
    } else {
        if(position.indexOf('top') >= 0) { ret = ret + eCDPosition.Top; }
        if(position.indexOf('right') >= 0) { ret = ret + eCDPosition.Right; }
        if(position.indexOf('bottom') >= 0) { ret = ret + eCDPosition.Bottom; }
        if(position.indexOf('left') >= 0) { ret = ret + eCDPosition.Left; }
    }
    return(ret);
}
function GetFirstDefined(num1, num2) {
    if(typeof(num1) != "undefined") {
        return(num1);
    } else {
        return(num2);
    }
}
function GetOrientationFromString(orientation) {
    var ret = eCCOrientation.Float;
    if(orientation.length > 0) {
        switch(orientation.substring(0, 1).toLowerCase()) {
            case 'h':
                ret = eCCOrientation.Horizontal;
                break;
            case 'v':
                ret = eCCOrientation.Vertical;
                break;
        }
    }
    return(ret);
}
function GetSizeOfMax(size, max) {
    if(size == 'auto') {
        return(max);
    } else {
        if((size+'').indexOf('%') >= 0) {
            return((parseInt(size.replace('%', '')) / 100) * max);
        } else {
            return(size);
        }
    }
}
function GetSizeOfPrefMax(size, pref, max) {
    if(size == 'auto') {
        return(pref);
    } else {
        if((size+'').indexOf('%') >= 0) {
            return((parseInt(size.replace('%', '')) / 100) * max);
        } else {
            return(size);
        }
    }
}
function GetVerticalAlignmentCords(valign, defaultvalign, fixed, y, height, prefheight, minheight, allowy, allowheight) {
    var ret = new Object();
    var ph = prefheight; var h = height; var mh = minheight; var ah = allowheight;
    if((ph+'').toLowerCase() == 'auto') { ph = ah; }
    if((h+'').toLowerCase() == 'auto') { h = ph; }
    if((mh+'').toLowerCase() == 'auto') { mh = ph; }
    if((ah+'').toLowerCase() == 'auto') { ah = ph; }
    if(valign == eCCVAlign.Default) { valign = defaultvalign; }
    if((h+'').indexOf('%') >= 0) { h = (parseInt(h.replace('%', '')) / 100) * ah; }
    if((mh+'').indexOf('%') >= 0) { mh = (parseInt(mh.replace('%', '')) / 100) * ah; }
    if(isNaN(ph)) { ph = ah; }
    if((!isNaN(ph)) && (ph < 0)) { if(!isNaN(h)) { ph = h; } else { ph = ah; } }
    if(fixed == true) { mh = h; }
    if(isNaN(mh)) {
        if(h < ph) {
            if(h < ah) {
                mh = h;
            } else {
                mh = ah;
            }
        } else {
            if(ph < ah) {
                mh = ph;
            } else {
                mh = ah;
            }
        }
    }
    if(h < mh) { h = mh; }
    ret.Y = allowy; ret.Height = ah; ret.MinHeight = mh; ret.FixedHeight = 0; ret.StretchHeight = 0; ret.StretchPreCalcHeight = 0;
    if(valign == eCCVAlign.Float) {
        if((y + h) <= ah) {
            ret.Y = allowy + y;
            ret.Height = h;
        } else {
            if(h <= ah) {
                ret.Y = (allowy + ah) - h;
                ret.Height = h;
            }
        }
    } else {
        if(h <= ah) {
            switch(valign) {
                case eCCVAlign.Top:
                    if((y + h) > ah) {
                        ret.Y = (allowy + ah) - h;
                    } else if(y < 0) {
                        ret.Y = allowy;
                    } else {
                        ret.Y = allowy + y;
                    }
                    break;
                case eCCVAlign.Middle:
                    if((y + ((ah / 2) + (h / 2))) > ah) {
                        ret.Y = (allowy + ah) - h;
                    } else if((y + ((ah / 2) - (h / 2))) < 0) {
                        ret.Y = allowy;
                    } else {
                        ret.Y = allowy + y + ((ah / 2) - (h / 2));
                    }
                    break;
                case eCCVAlign.Bottom:
                    if((ah - y) > ah) {
                        ret.Y = (allowy + ah) - h;
                    } else if((ah - (y + h)) < 0) {
                        ret.Y = allowy;
                    } else {
                        ret.Y = allowy + (ah - (y + h));
                    }
                    break;
            }
            ret.Height = h;
        }
    }
    if(fixed == true) { ret.MinHeight = ret.Height; ret.FixedHeight = ret.Height; } else { ret.StretchHeight = ret.Height; ret.StretchPreCalcHeight = ph; }
    return(ret);
}
function GetVerticalAlignmentFromString(valign) {
    var ret = eCCVAlign.Default;
    if(valign.length > 0) {
        switch(valign.substring(0, 1).toLowerCase()) {
            case 't':
                ret = eCCVAlign.Top;
                break;
            case 'm':
                ret = eCCVAlign.Middle;
                break;
            case 'b':
                ret = eCCVAlign.Bottom;
                break;
            case 's':
                ret = eCCVAlign.Stretch;
                break;
            case 'f':
                ret = eCCVAlign.Float;
                break;
        }
    }
    return(ret);
}
function GetWindowStateFromString(state) {
    var ret = eCWState.Normal;
    if(state.length > 0) {
        switch(state.substring(1, 1).toLowerCase()) {
            case 'm':
                if(state.length > 1) {
                    switch(state.substring(0, 1).toLowerCase()) {
                        case 'i':
                            ret = eCWState.Minimized;
                            break;
                        case 'a':
                            ret = eCWState.Maximized;
                            break;
                    }
                }
                break;
            case 'c':
                ret = eCWState.Collapsed;
                break;
            case 'd':
                ret = eCWState.Docked;
                break;
        }
    }
    return(ret);
}
function GetWindowStyleFromString(style) {
    var ret = eCWStyle.Normal;
    if(style.length > 0) {
        switch(style.substring(0, 1).toLowerCase()) {
            case 't':
                ret = eCWStyle.Tool;
                break;
            case 'p':
                ret = eCWStyle.Popout;
                break;
            case 'm':
                ret = eCWStyle.Menu;
                break;
        }
    }
    return(ret);
}

function InArray(arr, val) {
	if((typeof(arr) == 'object') && (arr instanceof Array)) {
        if(arr.length > 0) {
            for(var i = arr.length - 1; i >= 0; i--) {
                if(arr[i] == val) { return(true); }
            }
        }
    } else { if(arr == val) { return(true); } }
    return(false);
}
function LastInArray(arr, val, arrall) {
	if((typeof(arr) == 'object') && (arr instanceof Array)) {
        if(arr.length > 0) {
            for(var i = arr.length - 1; i >= 0; i--) {
                if(arr[i] == val) { return(true); }
                if(InArray(arrall, arr[i]) == true) { return(false); }
            }
        }
    } else { if(arr == val) { return(true); } }
    return(false);
}
function WithInArray(arr, val) {
	if((typeof(arr) == 'object') && (arr instanceof Array)) {
        if(arr.length > 0) {
            for(var i = arr.length - 1; i >= 0; i--) {
                if(arr[i] == val) { return(i + 1); }
            }
        }
    } else { if(arr == val) { return(0); } }
    return(-1);
}

var base64Chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';

function base64_encode(data) {
   var ret = ""; var c1, c2, c3; var e1, e2, e3, e4;
   var i = 0;
   do {
      c1 = data.charCodeAt(i++); c2 = data.charCodeAt(i++); c3 = data.charCodeAt(i++);
 
      e1 = c1 >> 2; e2 = ((c1 & 3) << 4) | (c2 >> 4); e3 = ((c2 & 15) << 2) | (c3 >> 6); e4 = c3 & 63;
 
      if (isNaN(c2)) {
         e3 = e4 = 64;
      } else if (isNaN(c3)) {
         e4 = 64;
      }
      ret = ret + base64Chars.charAt(e1) + base64Chars.charAt(e2) + base64Chars.charAt(e3) + base64Chars.charAt(e4);
   } while (i < data.length);
   return ret;
}
 
function base64_decode(data) {
   var ret = ""; var c1, c2, c3; var e1, e2, e3, e4;
   var i = 0;
   data = data.replace(/[^A-Za-z0-9\+\/\=]/g, "");
   do {
      e1 = base64Chars.indexOf(data.charAt(i++)); e2 = base64Chars.indexOf(data.charAt(i++));
      e3 = base64Chars.indexOf(data.charAt(i++)); e4 = base64Chars.indexOf(data.charAt(i++));
 
      c1 = (e1 << 2) | (e2 >> 4); c2 = ((e2 & 15) << 4) | (e3 >> 2); c3 = ((e3 & 3) << 6) | e4;
 
      ret = ret + String.fromCharCode(c1);
 
      if (e3 != 64) { ret = ret + String.fromCharCode(c2); }
      if (e4 != 64) { ret = ret + String.fromCharCode(c3); }
   } while (i < data.length);
   return ret;
}

function eventPop(obj, e, handler) {
  if (obj.addEventListener && (!window.opera)) {
    obj.removeEventListener(e, function(ev) { handler(ev); }, false);
  } else if (obj.attachEvent && (!window.opera)) {
    obj.detachEvent('on'+e, function(ev) { handler(ev); });
  } else {
    switch(e) {
        case 'blur':
            obj.onblur = null;
            break;
        case 'click':
            obj.onclick = null;
            break;
        case 'dblclick':
            obj.ondblclick = null;
            break;
        case 'focus':
            obj.onfocus = null;
            break;
        case 'load':
            obj.onload = null;
            break;
        case 'mousedown':
            obj.onmousedown = null;
            break;
        case 'mousemove':
            obj.onmousemove = null;
            break;
        case 'mouseout':
            obj.onmouseout = null;
            break;
        case 'mouseover':
            obj.onmouseover = null;
            break;
        case 'mouseup':
            obj.onmouseup = null;
            break;
    }
  }
}
function eventPush(obj, e, handler) {
  if (obj.addEventListener && (!window.opera)) {
    obj.addEventListener(e, function(ev) { handler(ev); }, false);
  } else if (obj.attachEvent && (!window.opera)) {
    obj.attachEvent('on'+e, function(ev) { handler(ev); });
  } else {
    switch(e) {
        case 'blur':
            obj.onblur = handler;
            break;
        case 'click':
            obj.onclick = handler;
            break;
        case 'dblclick':
            obj.ondblclick = handler;
            break;
        case 'focus':
            obj.onfocus = handler;
            break;
        case 'load':
            obj.onload = handler;
            break;
        case 'mousedown':
            obj.onmousedown = handler;
            break;
        case 'mousemove':
            obj.onmousemove = handler;
            break;
        case 'mouseout':
            obj.onmouseout = handler;
            break;
        case 'mouseover':
            obj.onmouseover = handler;
            break;
        case 'mouseup':
            obj.onmouseup = handler;
            break;
    }
  }
}
    //        cBrowser, int, string
function cAjax(parent, id, targeturl) {
    this.Parent = parent;
    this.ID = id;
    this.TargetURL = targeturl;
    this.Loaded = false;
    this.LoadChange = false;
    this.SendQueue = new cQueue();      //  cAjaxMessage
    this.Message = 0;
    this.ActiveMode = 0;
    this.SentMessages = new Array();    //  cAjaxMessage
    this.SyncRate = 10;
    this.Busy = 0;
    this.CommandLimit = 10;
    this.IF = null;
    this.FORM = null;
    this.Load();
}
function cAjax_Dispose() {
    this.UnLoad();
}
function cAjax_GetFreeSendMessageID() {
    var Msg = this.Message;
    this.Message++;
    return(Msg);
}
function cAjax_GetSentMessage(id) {
    if(id < 0) { return(null); }
    if(this.SentMessages.length > 0) {
        for(var i = this.SentMessages.length - 1; i >= 0; i--) {
            if(this.SentMessages[i].ID == id) {
                return(this.SentMessages[i]);
            }
        }
    }
    return(null);
}
function cAjax_Load() {
    if((this.Loading == false) && (this.LoadChange == false)) {
        this.LoadChange = true;
        /*
        this.IF = document.createElement('iframe');
        this.IF.setAttribute('id', 'ifAJAX_' + this.ID);
        document.getElementById('divIFHolder').appendChild(this.IF);
        this.FORM = document.createElement('form');
        this.FORM.method = "POST";
        document.getElementById('divFormHolder').appendChild(this.FORM);
        this.IF.onload = function(id) {
            var a = Browser.GetAjax(parseInt(this.id.substr(7)));
            a.ParseInput(frames[this.id].document.body.innerHTML);
            a.Busy = 0;
            a.SendNext();
        };
        */
        this.Loaded = true;
        this.LoadChange = false;
    }
}
function cAjax_ParseInput(sInput) {
    if(sInput.length > 0) {//alert(sInput.replace(/\=/g, "\n="));
        var alerts = "";
        var tA = sInput.split("=");
        
        //alert(alerts);
    }
}
function cAjax_RemoveSentMessage(id) {
    if(id < 0) { return(null); }
    var bHit = false;
    if(this.SentMessages.length > 0) {
        for(var i = this.SentMessages.length - 1; i > 0; i--) {
            if(bHit == true) {
                this.SentMessages[i] = this.SentMessages[i - 1];
            } else {
                if(this.SentMessages[i].ID == id) {
                    this.SentMessages[i].Dispose();
                    delete this.SentMessages[i];
                    this.SentMessages[i] = this.SentMessages[i - 1];
                    bHit = true;
                }
            }
        }
        if(bHit == false) {
            if(this.SentMessages[0].ID == id) {
                this.SentMessages[0].Dispose();
                bHit = true;
            }
        }
        if(bHit == true) {
            this.SentMessages.shift();
        }
    }
}
function cAjax_Send(persist, sessionid, windowid, controlid, message) {
    var mid = this.GetFreeSendMessageID();
    this.SendQueue.push(new cAjaxMessage(this, mid, persist, sessionid, windowid, controlid, this.TargetURL, message));
    this.SendNext();
}
function cAjax_SendNext() {
    if(this.Busy < this.CommandLimit) {
        if(!this.SendQueue.empty()) {
            this.Busy++;
            var q = this.SendQueue.pop();
            var mid = q.ID;
            if(q.Message.length > 0) {
                this.SentMessages.push(q);
                this.GetSentMessage(mid).Send();
            }
        }
    }
}
function cAjax_UnLoad() {
    if((this.Loading == false) && (this.LoadChange == false)) {
        this.LoadChange = true;
        /*
        var p = document.getElementById('divIFHolder');
        p.removeChild(this.IF);
        p = document.getElementById('divFormHolder');
        p.removeChild(this.FORM);
        */
        this.Loaded = false;
        this.LoadChange = false;
    }
}
cAjax.prototype.Dispose = cAjax_Dispose;
cAjax.prototype.GetFreeSendMessageID = cAjax_GetFreeSendMessageID;
cAjax.prototype.GetSentMessage = cAjax_GetSentMessage;
cAjax.prototype.Load = cAjax_Load;
cAjax.prototype.ParseInput = cAjax_ParseInput;
cAjax.prototype.RemoveSentMessage = cAjax_RemoveSentMessage;
cAjax.prototype.Send = cAjax_Send;
cAjax.prototype.SendNext = cAjax_SendNext;
cAjax.prototype.UnLoad = cAjax_UnLoad;
    //               cAjax, int, bool, int, int, int, string, string[]
function cAjaxMessage(parent, id, persist, sessionid, windowid, controlid, targeturl, message) {
    this.Parent = parent;
    this.ID = id;
    this.Persist = persist;
    this.SessionID = sessionid;
    this.WindowID = windowid;
    this.ControlID = controlid;
    this.TargetURL = targeturl;
    this.Message = message;
    this.Loaded = false;
    this.LoadChange = false;
    this.Parsed = false;
    this.IF = null;
    this.FORM = null;
    //alert('SEND'+dump(message));
}
function cAjaxMessage_Dispose() {
    this.UnLoad();
}
function cAjaxMessage_IFLoad(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        var tA = obj.id.substr(7);
        tA = tA.split('_');
        var message = Browser.GetAjax(parseInt(tA[0])).GetSentMessage(parseInt(tA[1]));
        message.ParseInput(frames[obj.id].document.body.innerHTML);
        message.Kill();
    }
    return(void(0));
}
function cAjaxMessage_IFLoadLocal() {
    //alert(window.frames['ifAJAX_' + this.Parent.ID + '_' + this.ID].document.getElementById('b').innerHTML);
    this.ParseInput(window.frames['ifAJAX_' + this.Parent.ID + '_' + this.ID].document.getElementById('b').innerHTML);//.body.innerHTML);
    this.Kill();
}
function cAjaxMessage_Kill() {
    this.Parent.Busy--;
    this.IF.setAttribute('src', '');
    this.Parent.SendNext(); 
    this.Parent.RemoveSentMessage(this.ID);
}
function dump(arr,level) {
var dumped_text = "";
if(!level) level = 0;

//The padding given at the beginning of the line.
var level_padding = "";
for(var j=0;j<level+1;j++) level_padding += "    ";

if(typeof(arr) == 'object') { //Array/Hashes/Objects
 for(var item in arr) {
  var value = arr[item];
 
  if(typeof(value) == 'object') { //If it is an array,
   dumped_text += level_padding + "'" + item + "' ...\n";
   dumped_text += dump(value,level+1);
  } else {
   dumped_text += level_padding + "'" + item + "' => \"" + value + "\"\n";
  }
 }
} else { //Stings/Chars/Numbers etc.
 dumped_text = "===>"+arr+"<===("+typeof(arr)+")";
}
return dumped_text;
}
function cAjaxMessage_ParseInput(data) {
//alert(data);
    if(this.Parsed == false) {
        this.Parsed = true;
        var tA = BufferIn(data);
        //alert('RECV'+dump(tA));
        if(this.SessionID >= 0) {
            var Ses = Browser.GetSession(this.SessionID);
            if(Ses) {
                if(this.WindowID >= 0) {
                    var Win = Ses.GetWindow(this.WindowID);
                    if(Win) {
                        if(this.ControlID >= 0) {
                            var Ctl = Win.GetControl(this.ControlID);
                            if(Ctl) {
                                Ctl.AjaxProcess(tA);
                            }
                        } else {
                            Win.AjaxProcess(tA);
                        }
                    }
                } else {
                    Ses.AjaxProcess(tA);
                }
            }
        } else {
            Browser.AjaxProcess(tA);
        }
        tA = [];
    }
}
function cAjaxMessage_Send() {
    if((this.Loaded == false) && (this.LoadChange == false)) {
        this.LoadChange = true;
        var p;
        var dt = ((new Date()).getTimezoneOffset()) / 60;
        
        if(this.Persist) { p = '1'; } else { p = '0'; }
        this.IF = document.createElement('iframe');
        this.IF.setAttribute('id', 'ifAJAX_' + this.Parent.ID + '_' + this.ID);
        this.IF.setAttribute('name', 'ifAJAX_' + this.Parent.ID + '_' + this.ID);
        document.getElementById('divIFHolder').appendChild(this.IF);
        if((Browser.browser.isIE == true) || (window.opera)) { self.frames['ifAJAX_' + this.Parent.ID + '_' + this.ID].name = 'ifAJAX_' + this.Parent.ID + '_' + this.ID; }
        //alert('inc/ajax.php?txtAJAXHeader_' + this.Parent.ID + '_' + this.ID+'='+BufferOut(new Array(Browser.BrowserKey, dt, this.Parent.ID, this.ID, p, this.SessionID, this.WindowID))+'&txtAJAXMessage_' + this.Parent.ID + '_' + this.ID+'='+BufferOut(this.Message));
        this.FORM = document.createElement('form');
        this.FORM.setAttribute('method', 'POST');
        this.FORM.setAttribute('target', 'ifAJAX_' + this.Parent.ID + '_' + this.ID);
        this.FORM.target = 'ifAJAX_' + this.Parent.ID + '_' + this.ID;
        this.FORM.setAttribute('action', this.TargetURL);
        
        this.TXTHeader = document.createElement('input');
        this.TXTHeader.setAttribute('id', 'txtAJAXHeader_' + this.Parent.ID + '_' + this.ID);
        this.TXTHeader.setAttribute('name', 'txtAJAXHeader_' + this.Parent.ID + '_' + this.ID);
        this.TXTHeader.setAttribute('type', 'text');
        this.TXTHeader.setAttribute('value', BufferOut(new Array(Browser.BrowserKey, dt, this.Parent.ID, this.ID, p, this.SessionID, this.WindowID)));
        this.TXTMessage = document.createElement('input');
        this.TXTMessage.setAttribute('id', 'txtAJAXMessage_' + this.Parent.ID + '_' + this.ID);
        this.TXTMessage.setAttribute('name', 'txtAJAXMessage_' + this.Parent.ID + '_' + this.ID);
        this.TXTMessage.setAttribute('type', 'text');
        this.TXTMessage.setAttribute('value', BufferOut(this.Message));
        
            this.FORM.appendChild(this.TXTHeader);
            this.FORM.appendChild(this.TXTMessage);
        document.getElementById('divFormHolder').appendChild(this.FORM);
        
        //if (typeof this.IF.nodeType == "undefined") {
        //    this.IF = document.getElementById('ifAJAX_' + this.Parent.ID + '_' + this.ID);
        //}
        //eventPush(this.IF, 'load', this.IFLoad);
        this.FORM.submit();
        this.Loaded = true;
        this.LoadChange = false;
    }
}
function cAjaxMessage_UnLoad() {
    if((this.Loaded == true) && (this.LoadChange == false)) {
        this.LoadChange = true;
        
        //eventPop(this.IF, 'load', cAjaxMessage_IFLoad);
        
        var p = document.getElementById('divIFHolder');
        //p.removeChild(this.IF);
        p = document.getElementById('divFormHolder');
            this.FORM.removeChild(this.TXTMessage);
            this.FORM.removeChild(this.TXTHeader);
        p.removeChild(this.FORM);
        
        this.Loaded = false;
        this.LoadChange = false;
    }
}
cAjaxMessage.prototype.Dispose = cAjaxMessage_Dispose;
cAjaxMessage.prototype.IFLoad = cAjaxMessage_IFLoad;
cAjaxMessage.prototype.IFLoadLocal = cAjaxMessage_IFLoadLocal;
cAjaxMessage.prototype.Kill = cAjaxMessage_Kill;
cAjaxMessage.prototype.ParseInput = cAjaxMessage_ParseInput;
cAjaxMessage.prototype.Send = cAjaxMessage_Send;
cAjaxMessage.prototype.UnLoad = cAjaxMessage_UnLoad;
function GetBrowserType() {
    var ua, s, i;
    this.isIE    = false;
    this.isNS    = false;
    this.version = null;
    ua = navigator.userAgent;
    s = "MSIE";
    if ((i = ua.indexOf(s)) >= 0) {
        this.isIE = true;
        this.version = parseFloat(ua.substr(i + s.length));
        return;
    }
    s = "Netscape6/";
    if ((i = ua.indexOf(s)) >= 0) {
        this.isNS = true;
        this.version = parseFloat(ua.substr(i + s.length));
        return;
    }
    s = "Gecko";
    if ((i = ua.indexOf(s)) >= 0) {
        this.isNS = true;
        this.version = 6.1;
        return;
    }
}

function cClassification(id, sciname, comname, comnames) {
    this.ID = id;
    this.ScientificName = sciname;
    this.CommonName = comname;
    this.CommonNamePlural = comnames;
    this.DisplayName = comname + ' (' + sciname + ')';
    this.DisplayNamePlural = comnames + ' (' + sciname + ')';
}
function cClassifier(depth) {
    this.OnLevel = new Array();
    if(depth > 0) {
        this.SubLevel = new cClassifier(depth - 1);
    } else {
        this.SubLevel = null;
    }
    this.SelectedID = 0;
}
function cClassifier_GetOnClassification(id) {
    if(id < 0) { return(null); }
    if(this.OnLevel.length > 0) {
        for(var i = this.OnLevel.length - 1; i >= 0; i--) {
            if(this.OnLevel[i].ID == id) {
                return(this.OnLevel[i]);
            }
        }
    }
    return(null);
}
cClassifier.prototype.GetOnClassification = cClassifier_GetOnClassification;

function cBrowser() {
    this.BaseType = 'Browser';
    this.TypeOf = 'Browser';
    this.browser = new GetBrowserType();
    this.ScreenMetrics = new Object();
    this.ScreenMetrics.X = 0; this.ScreenMetrics.Y = 0; this.ScreenMetrics.Width = 0; this.ScreenMetrics.Height = 0;
    this.Sizing = false;
    this.ClassifierObj = null;
    
    this.SysDirectMessage = false;
    this.SysClassifier = false;
    this.SysLogin = false;
    this.SysLostPassword = false;
    this.SysLostUsername = false;
    this.SysPasswordReset = false;
    this.SysRegistration = false;
    
    this.FocusObj = null;
    this.FocusControl = null;
    this.DownControl = null;
    this.Ajax = new Array();        //  cAjax;
    this.CooldownOverlays = new Array();    //  cCooldownOverlay
    this.SysFail = '';
    this.AjaxID = 0;
    this.ParamID1 = -1;
    this.ParamID2 = -1;
    this.ParamID3 = -1;
    this.ValidatorField = '';
    this.ValidatorValue = '';
    this.BrowserKey = '';
    this.UserID = -1;
    this.Username = '';
    this.IsAdmin = false;
    this.TXTUsername = null;
    this.TXTPassword = null;
    this.CAPTCHAReloadIcon = null;
    this.CAPTCHAImage = null;
    this.CAPTCHATimeout = '';
    this.CAPTCHACode = 0;
    this.CAPTCHARefreshDelay = 30000;
    this.PreCached = false;
    
    this.FetchClassificationCB = null;
    
    this.Classifier = new cClassifier(4);
    this.Classifier.OnLevel.push(new cClassification(1, 'Reptilia', 'Reptile', 'Reptiles'));
    this.Classifier.OnLevel.push(new cClassification(2, 'Amphibia', 'Amphibian', 'Amphibians'));
    
    if (typeof document.body.onselectstart!="undefined")
	    document.body.onselectstart=function(){return false}
    else if (typeof document.body.style.MozUserSelect!="undefined")
	    document.body.style.MozUserSelect="none"
    //else
	    //document.body.onmousedown=function(){return false}
    document.body.style.cursor = "default"
}
function cBrowser_Activate(browserkey, userid, username, isadmin) {
    this.BrowserKey = browserkey;
    this.UserID = userid;
    this.Username = username;
    this.IsAdmin = isadmin;
    var o = document.getElementById('divMain');
    if(o) {
        o.style.display = 'block';
        o.style.visibility = 'visible';
    }
}
function cBrowser_AjaxArrival(AjaxID, AjaxMessageID) {
    var a = this.GetAjax(AjaxID);
    if(a) {
        a = a.GetSentMessage(AjaxMessageID);
        if(a) {
            a.IFLoadLocal();
        }
    }
}
function cBrowser_AjaxProcess(data) {
    if((typeof(data) == 'object') && (data instanceof Array) && (data.length > 0)) {
        switch(data[0]) {
            case 'animalmanager':
                AnimalManager.AjaxProcess(data);
                break;
            case 'auth':
                this.AjaxProcessAuth(data);
                break;
            case 'photomanager':
                PhotoManager.AjaxProcess(data);
                break;
            case 'validator':
                this.AjaxProcessValidator(data);
                break;
        }
    }
}
function cBrowser_AjaxProcessAuth(data) {
    if(data.length > 1) {
        switch(data[1]) {
            case 'blockregemail':
                this.AjaxProcessAuthBlockRegEmail(data);
                break;
            case 'confirmregistration':
                this.AjaxProcessAuthConfirmRegistration(data);
                break;
            case 'classify':
                this.AjaxProcessAuthClassify(data);
                break;
            case 'login':
                this.AjaxProcessAuthLogin(data);
                break;
            case 'lostpassword':
                this.AjaxProcessAuthLostPassword(data);
                break;
            case 'lostusername':
                this.AjaxProcessAuthLostUsername(data);
                break;
            case 'passwordreset':
                this.AjaxProcessAuthPasswordReset(data);
                break;
            case 'pwaudit':
                this.AjaxProcessAuthPWAudit(data);
                break;
            case 'pwreset':
                this.AjaxProcessAuthPWReset(data);
                break;
            case 'registration':
                this.AjaxProcessAuthRegistration(data);
                break;
            case 'stat':
                this.AjaxProcessAuthStat(data);
                break;
        }
    }
}
function cBrowser_AjaxProcessAuthBlockRegEmail(data) {
    var blocked = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0]+'' == '1')) {
            if(data[2].length > 1) {
                this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Email Blocked', 'Welcome, '+data[2][1], 'Your email address has been blocked.', 'We apologize for any spam you may have received due to an abuse of our<br />system, this issue has been logged and we will look into it.', 'Please note, if you would like to register in the future or if<br />you accidently clicked the block link in your registration email you<br />will have to <a href="mailto: webmaster@reptilelineage.com?subject=Accidental Registration Block">contact us</a> with the email address that has been blocked<br />in order to register in our system.');
                blocked = true;
            }
        }
    }
    if(blocked == false) {
        this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Invalid Registration Code', 'Hello', 'This registration code is not valid.', 'If you believe you have received this message in error you may <a href="mailto: webmaster@reptilelineage.com?subject=Invalid Registration Block">contact us</a><br />and we will work to resolve your issue as soon as possible.', '');
    }
    this.HideLoading();
}
function cBrowser_AjaxProcessAuthClassify(data) {
    var classified = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array)) {
            if(data[2][0]+'' == '1') {
                if(data[2].length > 1) {
                    if(this.ClassifierObj != null) {
                        var bHit = false;
                        if(this.ClassifierObj.length > 0) {
                            for(var i = 0; i < this.ClassifierObj.length; i++) {
                                if(parseInt(this.ClassifierObj.options[i].value) == data[2][1]) { bHit = true; this.ClassifierObj.selectedIndex = i; }
                            }
                        }
                        if(bHit == false) {
                            this.OPTSpecies = document.createElement('option');
                            this.OPTSpecies.text = data[2][2];
                            this.OPTSpecies.value = data[2][1];
                            this.OPTSpecies.selected = true;
                            this.ClassifierObj.add(this.OPTSpecies, 0);
                        }
                    }
                    this.ClassifierObj = null;
                    this.HideLoading();
                    classified = true;
                }
            } else {
                var o = this.ClassifierObj;
                this.ClassifierObj = null;
                this.ShowClassifier(o);
                this.Classifier.SelectedID = parseInt(data[2][1]);
                this.Classifier.SubLevel.SelectedID = parseInt(data[2][2]);
                this.Classifier.SubLevel.SubLevel.SelectedID = parseInt(data[2][3]);
                this.Classifier.SubLevel.SubLevel.SubLevel.SelectedID = parseInt(data[2][4]);
                this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.SelectedID = parseInt(data[2][5]);
                o = document.getElementById('form_classifier_family_scientificname');
                if(o) { o.value = data[2][6] }
                o = document.getElementById('form_classifier_family_commonname');
                if(o) { o.value = data[2][7] }
                o = document.getElementById('form_classifier_family_commonpluralname');
                if(o) { o.value = data[2][8] }
                o = document.getElementById('form_classifier_genus_scientificname');
                if(o) { o.value = data[2][9] }
                o = document.getElementById('form_classifier_genus_commonname');
                if(o) { o.value = data[2][10] }
                o = document.getElementById('form_classifier_genus_commonpluralname');
                if(o) { o.value = data[2][11] }
                o = document.getElementById('form_classifier_species_scientificname');
                if(o) { o.value = data[2][12] }
                o = document.getElementById('form_classifier_species_commonname');
                if(o) { o.value = data[2][13] }
                o = document.getElementById('form_classifier_species_commonpluralname');
                if(o) { o.value = data[2][14] }
                
                var o = document.getElementById('form_classifier_domain_tag');
                if(o) { o.innerHTML = data[2][15] }
                o = document.getElementById('form_classifier_kingdom_tag');
                if(o) { o.innerHTML = data[2][16] }
                o = document.getElementById('form_classifier_phylum_tag');
                if(o) { o.innerHTML = data[2][17] }
                o = document.getElementById('form_classifier_subphylum_tag');
                if(o) { o.innerHTML = data[2][18] }
                o = document.getElementById('form_classifier_class_tag');
                if(o) { o.innerHTML = data[2][19] }
                o = document.getElementById('form_classifier_order_tag');
                if(o) { o.innerHTML = data[2][20] }
                o = document.getElementById('form_classifier_family_tag');
                if(o) { o.innerHTML = data[2][21] }
                o = document.getElementById('form_classifier_genus_tag');
                if(o) { o.innerHTML = data[2][22] }
                o = document.getElementById('form_classifier_species_tag');
                if(o) { o.innerHTML = data[2][23] }
                this.HideLoading();
                classified = true;
            }
        }
    }
    if(classified == false) {
        this.ShowDirectMessage('novorum', 'Reptile Lineage Classification', 'Invalid Classification Sequence', 'Hello', 'This classification sequence is not valid.', 'If you believe you have received this message in error you may <a href="mailto: webmaster@reptilelineage.com?subject=Invalid Classification Sequence">contact us</a><br />and we will work to resolve your issue as soon as possible.', '');
        this.HideLoading();
    }
}
function cBrowser_AjaxProcessAuthConfirmRegistration(data) {
    var displayed = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2].length > 1)) {
            switch(data[2][0]+'') {
                case '0':
                    if(data[2].length > 1) {
                        this.ShowDirectMessage('novorum', 'Reptile Lineage Registration', 'Registration Unknown', 'Welcome, '+data[2][1], 'Your email address has been blocked.', 'We apologize for any spam you may have received due to an abuse of our<br />system, this issue has been logged and we will look into it.', 'Please note, if you would like to register in the future or if<br />you accidently clicked the block link in your registration email you<br />will have to <a href="mailto: webmaster@reptilelineage.com?subject=Accidental Registration Block">contact us</a> with the email address that has been blocked<br />in order to register in our system.');
                        displayed = true;
                    }
                    break;
                case '1':
                    if(data[2].length > 3) {
                        this.Activate(data[3], data[2][2], data[2][1], (data[2][3]+'' == '1'));
                        this.ShowDirectMessage('novorum', 'Reptile Lineage Registration', 'Registration Complete', 'Welcome, '+data[2][1], 'You have been registered.', 'Please wait while your session is authenticated...', 'If this page does not reload within 10 seconds you may <a href="JavaScript: Browser.HideDirectMessage(); if(Browser.BrowserKey == \'\') { Browser.ShowLogin(); }">click here</a><br />to see if your login was properly authenticated.');
                        setTimeout('Browser.HideDirectMessage(); if(Browser.BrowserKey == \'\') { Browser.ShowLogin(); }', 10000);
                        displayed = true;
                    }
                    break;
                case '2':
                    if(data[2].length > 1) {
                        this.ShowDirectMessage('novorum', 'Reptile Lineage Registration', 'Registration Expired', 'We\'re Sorry', 'Your registration has expired.', 'The 24 hour limit to confirm your email address has expired,<br />You may <a href="JavaScript: Browser.ShowRegistration();">resubmit your registration</a> if you like. <br />If you have registered less than 24 hours ago please <a href="mailto: webmaster@reptilelineage.com?subject=Registration Expired">contact us</a><br />regaurding this issue.', '');
                        displayed = true;
                    }
                    break;
                case '3':
                    if(data[2].length > 1) {
                        this.ShowDirectMessage('novorum', 'Reptile Lineage Registration', 'Registration Complete', 'Welcome, '+data[2][1], 'You are pending verification.', 'We have been alerted to your registration and it is pending manual<br />validation to ensure authenticity.  You will receive an email once<br />your account has been verified, at which time you will be able to<br />post to our system.  In the meantime you may still browse the site.', '');
                        displayed = true;
                    }
                    break;
            }
        }
    }
    if(displayed == false) {
        this.ShowDirectMessage('novorum', 'Reptile Lineage Registration', 'Invalid Registration Code', 'Hello', 'This registration code is not valid.', 'This registration code may have already been confirmed, in which case you<br />may <a href="JavaScript: Browser.HideDirectMessage(); Browser.ShowLogin();">login here</a>.', 'If you believe you have received this message in error you may <a href="mailto: webmaster@reptilelineage.com?subject=Invalid Registration">contact us</a><br />and we will work to resolve your issue as soon as possible.');
    }
    this.HideLoading();
}
function cBrowser_AjaxProcessAuthLogin(data) {
    if(data.length > 2) {
        var loaded = false;
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0]+'' == '1')) {
            if(data[2].length > 3) {
                location.reload(true);/*
                this.Activate(data[3], data[2][2], data[2][1], (data[2][3]+'' == '1'));
                this.HideLoading();*/
                loaded = true;
            }
        }
        if(loaded == false) {
            this.BrowserKey = '';
            this.ShowLogin();
            var o = document.getElementById('form_login_username');
            if(o) { o.value = data[2][1] }
            o = document.getElementById('form_login_username_tag');
            if(o) { o.innerHTML = data[2][2] }
            o = document.getElementById('form_login_password_tag');
            if(o) { o.innerHTML = data[2][3] }
            this.HideLoading();
        }
    }
}
function cBrowser_AjaxProcessAuthLostPassword(data) {
    if(data.length > 2) {
        var displayed = false;
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array)) {
            switch(data[2][0]+'') {
                case '1':
                    this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Please Check Your Email', 'Hello, '+data[2][1], 'Please check your email to reset your password...', '', 'If you do not receive your password reset instructions via email, please <a href="mailto: webmaster@reptilelineage.com?subject=Password Retrieval Email Trouble">contact us</a><br />from the email associated with your account in order to reset your password.');
                    this.HideLoading();
                    displayed = true;
                    break;
                case '2':
                    this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Email Failure', 'Hello, '+data[2][1], 'Email Retrieval Failed', '', 'Your password reset instructions could not be sent via email, please <a href="mailto: webmaster@reptilelineage.com?subject=Password Retrieval Email Failed">contact us</a><br />from the email associated with your account in order to reset your password.');
                    this.HideLoading();
                    displayed = true;
                    break;
            }
        }
        if(displayed == false) {
            this.ShowLostPassword();
            var o = document.getElementById('form_lostpassword_username');
            if(o) { o.value = data[2][1] }
            o = document.getElementById('form_lostpassword_email');
            if(o) { o.value = data[2][2] }
            o = document.getElementById('form_lostpassword_username_tag');
            if(o) { o.innerHTML = data[2][3] }
            o = document.getElementById('form_lostpassword_email_tag');
            if(o) { o.innerHTML = data[2][4] }
            o = document.getElementById('form_lostpassword_captcha_tag');
            if(o) { o.innerHTML = data[2][5] }
            this.HideLoading();
        }
    }
}
function cBrowser_AjaxProcessAuthLostUsername(data) {
    if(data.length > 2) {
        var displayed = false;
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array)) {
            switch(data[2][0]+'') {
                case '1':
                    this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Please Check Your Email', 'Hello', 'Please check your email to retrieve your username...', '', 'If you do not receive your username via email, please <a href="mailto: webmaster@reptilelineage.com?subject=Username Email Retrieval Trouble">contact us</a><br />from the email associated with your account in order to<br />attain your username.');
                    this.HideLoading();
                    displayed = true;
                    break;
                case '2':
                    this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Email Failure', 'Hello', 'Email Retrieval Failed', '', 'Your username could not be retrieved via email, please <a href="mailto: webmaster@reptilelineage.com?subject=Username Email Retrieval Failed">contact us</a><br />from the email associated with your account in order to<br />attain your username.');
                    this.HideLoading();
                    displayed = true;
                    break;
            }
        }
        if(displayed == false) {
            this.ShowLostUsername();
            var o = document.getElementById('form_lostusername_email');
            if(o) { o.value = data[2][1] }
            o = document.getElementById('form_lostusername_email_tag');
            if(o) { o.innerHTML = data[2][2] }
            o = document.getElementById('form_lostusername_captcha_tag');
            if(o) { o.innerHTML = data[2][3] }
            this.HideLoading();
        }
    }
}
function cBrowser_AjaxProcessAuthPasswordReset(data) {
    var blocked = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0]+'' == '1')) {
            if(data[2].length > 1) {
                this.Activate(data[3], data[2][2], data[2][1], (data[2][3]+'' == '1'));
                this.HideLoading();
                blocked = true;
            }
        }
    }
    if(blocked == false) {
        this.BrowserKey = '';
        this.ShowPasswordReset();
        var o = document.getElementById('form_passwordreset_username');
        if(o) { o.value = data[2][1] }
        o = document.getElementById('form_passwordreset_username_tag');
        if(o) { o.innerHTML = data[2][2] }
        o = document.getElementById('form_passwordreset_password_tag');
        if(o) { o.innerHTML = data[2][3] }
        o = document.getElementById('form_passwordreset_passwordconfirm_tag');
        if(o) { o.innerHTML = data[2][4] }
        o = document.getElementById('form_passwordreset_captcha_tag');
        if(o) { o.innerHTML = data[2][5] }
        this.HideLoading();
    }
    this.HideLoading();
}
function cBrowser_AjaxProcessAuthPWAudit(data) {
    var blocked = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0]+'' == '1')) {
            if(data[2].length > 1) {
                this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Audit Queued', 'Hello, '+data[2][1], 'Security audit has been queued.', 'By visiting this page you have queued a security audit on your account<br />and closed any pending account changes triggered by the associated key<br />of this page.  No further action is needed on your part unless you<br />receive further emails.', 'Thank you for taking the time to ensure our site and your account are secure.');
                blocked = true;
            }
        }
    }
    if(blocked == false) {
        this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Cannot Initiate Security Audit', 'Hello', 'The reset code you sent is invalid.', 'This could be caused by an expired password reset link or one that has<br />already been used. This attempt has been logged and will be looked into<br /><br />by someone at Reptile Lineage.', '');
    }
    this.HideLoading();
}
function cBrowser_AjaxProcessAuthPWReset(data) {
    var blocked = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0]+'' == '1')) {
            if(data[2].length > 1) {
                this.ShowPasswordReset(data[2][1]);
                blocked = true;
            }
        }
    }
    if(blocked == false) {
        this.ShowDirectMessage('novorum', 'Reptile Lineage Authentication', 'Invalid Reset Code', 'Hello', 'The reset code you sent is invalid.', 'This could be caused by an expired password reset link or one that has<br />already been used. This attempt has been logged and will be looked into<br />by someone at Reptile Lineage.', '');
    }
    this.HideLoading();
}
function cBrowser_AjaxProcessAuthRegistration(data) {
    if(data.length > 2) {
        var loaded = false;
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0]+'' == '1')) {
            if(data[2].length > 1) {
                this.ShowDirectMessage('novorum', 'Reptile Lineage Registration', 'Please Check Your Email', 'Welcome, '+data[2][1], 'Please check your email to complete registration with our system...', '', 'If you do not receive a confirmation email, please <a href="mailto: webmaster@reptilelineage.com?subject=Registration Trouble">contact us</a><br />from the email you want associated with your account in order to<br />complete your registration.');
                this.HideLoading();
                loaded = true;
            }
        }
        if(loaded == false) {
            this.ShowRegistration();
            var o = document.getElementById('form_registration_name_tag');
            if(o) { o.innerHTML = data[2][10]; }
            o = document.getElementById('form_registration_email_tag');
            if(o) { o.innerHTML = data[2][11]; }
            o = document.getElementById('form_registration_emailconfirm_tag');
            if(o) { o.innerHTML = data[2][12]; }
            o = document.getElementById('form_registration_username_tag');
            if(o) { o.innerHTML = data[2][13]; }
            o = document.getElementById('form_registration_password_tag');
            if(o) { o.innerHTML = data[2][14]; }
            o = document.getElementById('form_registration_passwordconfirm_tag');
            if(o) { o.innerHTML = data[2][15]; }
            o = document.getElementById('form_registration_captcha_tag');
            if(o) { o.innerHTML = data[2][16]; }
            o = document.getElementById('form_registration_system_tag');
            if(o) {
                o.innerHTML = data[2][9];
                o = document.getElementById('td_registration_system');
                if(o) {
                    if(data[2][9].length > 0) { o.style.display = 'block'; o.style.visibility = 'visible'; }
                    else { o.style.display = 'none'; o.style.visibility = 'hidden'; }
                    document.getElementById('td_registration_system_left').style.display = o.style.display;
                    document.getElementById('td_registration_system_right').style.display = o.style.display;
                    document.getElementById('td_registration_system_left').style.visibility = o.style.visibility;
                    document.getElementById('td_registration_system_right').style.visibility = o.style.visibility;
                }
            }
            
            this.TXTNameFirst.value = data[2][1];
            this.TXTNameMiddle.value = data[2][2];
            this.TXTNameLast.value = data[2][3];
            this.TXTEmail.value = data[2][4];
            this.TXTEmailConfirm.value = data[2][5];
            this.TXTUsername.value = data[2][6];
            this.TXTPassword.value = data[2][7];
            this.TXTPasswordConfirm.value = data[2][8];
            this.HideLoading();
        }
    }
}
function cBrowser_AjaxProcessAuthStat(data) {
    var bH = false;
    if(data.length > 2) {
        if((typeof(data[2]) == 'object') && (data[2] instanceof Array) && (data[2][0].length > 0)) {
            this.BrowserKey = data[2][0];
            this.UserID = data[2][1];
            this.Username = data[2][2];
            this.IsAdmin = (data[2][3] == '1');
            bH = true;
        }
    }
    if(bH == false) {
        this.BrowserKey = '';
        this.UserID = -1;
        this.Username = '';
        this.IsAdmin = false;
        location.reload(true);
    }
}
function cBrowser_AjaxProcessValidator(data) {
    if(data.length > 1) {
        if(data[1].length > 0) {
            this.FValidateEnd(data[2], data[3]);
        }
    }
}
function cBrowser_Classify(idomain, ikingdom, iphylum, isubphylum, iclass, iorder, ifamily, igenus, ispecies, familysci, familycom, familyplu, genussci, genuscom, genusplu, speciessci, speciescom, speciesplu) {
    this.ShowLoading();
    this.HideClassifier();
    if((idomain < 1) || (ikingdom < 1) || (iphylum < 1) || (isubphylum < 1) || (iclass < 1) || (iorder < 1) || (ifamily < 1) || (igenus < 1) || (ispecies < 1)) {
        var msg = new Array('auth', 'classify', idomain, ikingdom, iphylum, isubphylum, iclass, iorder, ifamily, igenus, ispecies, familysci, familycom, familyplu, genussci, genuscom, genusplu, speciessci, speciescom, speciesplu);
        this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    } else {
        if(this.ClassifierObj != null) {
            var bHit = false;
            if(this.ClassifierObj.length > 0) {
                for(var i = 0; i < this.ClassifierObj.length; i++) {
                    if(parseInt(this.ClassifierObj.options[i].value) == ispecies) { bHit = true; this.ClassifierObj.selectedIndex = i; }
                }
            }
            if(bHit == false) {
                var c = this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.GetOnClassification(ispecies);
                this.OPTSpecies = document.createElement('option');
                this.OPTSpecies.text = c.DisplayName;
                this.OPTSpecies.value = c.ID;
                this.OPTSpecies.selected = true;
                this.ClassifierObj.add(this.OPTSpecies, 0);
            }
        }
        this.ClassifierObj = null;
        this.HideLoading();
    }
    return(false);
}
function cBrowser_ClearFocusControl() {
    if(this.FocusControl != null) { this.FocusControl.FireEvent('blur', false, false, null); }
    this.FocusControl = null;
}
function cBrowser_CreateAjax() {
    var a = this.GetFreeAjaxID();
    this.Ajax.push(new cAjax(this, a, 'inc/ajax.php'));
    return(a);
}
function cBrowser_DisplayPhoto(photofile) {
    var c = document.getElementById('divPhoto');
    var i = document.getElementById('imgPhoto');
    if((c) && (i)) {
        if(photofile.toLowerCase().indexOf('photo.php') >= 0) {
            i.src = photofile;
        } else {
            i.src = 'img/photo/'+photofile;
        }
        c.style.visibility = 'visible';
        c.style.display = 'block';
    }
}
function cBrowser_HidePhoto() {
    var c = document.getElementById('divPhoto');
    if(c) {
        c.style.display = 'none';
        c.style.visibility = 'hidden';
    }
}
function cBrowser_FadeIn(id) {
    this.RealFadeIn(id, 0);
}
function cBrowser_FadeOut(id) {
    this.RealFadeOut(id, 10);
}
function cBrowser_FCaptchaClear() {
    this.CAPTCHACode = -1;
    this.CAPTCHAReloadIcon = null;
    this.CAPTCHAImage = null;
    this.CAPTCHATimeout = 0;
}
function cBrowser_FCaptchaRefresh(captchacode) {
    if(captchacode == this.CAPTCHACode) {
        if(this.CAPTCHAImage != null) {
            if(this.CAPTCHAReloadIcon != null) {
                //this.CAPTCHAReloadIcon.style.cursor = 'default';
                //this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
                //this.CAPTCHAReloadIcon.style.visibility = 'hidden';
                this.GetCooldownOverlay(18).Show(this.CAPTCHAReloadIcon, this.CAPTCHARefreshDelay);
                this.CAPTCHAImage.src = 'img/captchaT.png';
                this.CAPTCHAImage.src = 'inc/captcha.php?d=' + (new Date()).getTime();
                //setTimeout('document.getElementById(\''+this.CAPTCHAReloadIcon.id+'\').style.cursor = \'pointer\'; document.getElementById(\''+this.CAPTCHAReloadIcon.id+'\').style.visibility = \'visible\';', this.CAPTCHARefreshDelay);
            } else {
                this.CAPTCHAImage.src = 'img/captchaT.png';
                this.CAPTCHAImage.src = 'inc/captcha.php?d=' + (new Date()).getTime();
            }
            setTimeout('Browser.FCaptchaRefresh('+captchacode+')', this.CAPTCHATimeout);
        } else {
            this.FCaptchaClear();
        }
    }
}
function cBrowser_FetchClassificationDisplayName(id, cb) {
    
}
function cBrowser_FReloadCaptcha() {
    if(this.CAPTCHAReloadIcon.style.cursor == 'pointer') {
        //this.CAPTCHAReloadIcon.style.cursor = 'default';
        //this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
        //this.CAPTCHAReloadIcon.style.visibility = 'hidden';
        this.GetCooldownOverlay(18).Show(this.CAPTCHAReloadIcon, this.CAPTCHARefreshDelay);
        this.CAPTCHAImage.src = 'img/captchaT.png';
        this.CAPTCHAImage.src = 'inc/captcha.php?d=' + (new Date()).getTime();
        //setTimeout('document.getElementById(\''+this.CAPTCHAReloadIcon.id+'\').style.cursor = \'pointer\'; document.getElementById(\''+this.CAPTCHAReloadIcon.id+'\').style.visibility = \'visible\';', this.CAPTCHARefreshDelay);
    }
}
function cBrowser_FSetCaptcha(timeout) {
    this.CAPTCHATimeout = timeout * 1000;
    this.CAPTCHACode++;
    this.CAPTCHAImage.src = 'img/captchaT.png';
    this.CAPTCHAImage.src = 'inc/captcha.php?d=' + (new Date()).getTime();
    setTimeout('Browser.FCaptchaRefresh('+this.CAPTCHACode+')', this.CAPTCHATimeout);
}
function cBrowser_FStartValidate(field, value) {
    this.FocusObj = document.getElementById(field);
    validatorField = field;
    validatorValue = value;
    var a = this.FocusObj.id.toLowerCase().split('_'); a = a[a.length - 1];
    if(a != 'select') { this.FocusObj.select(); }
    //return(void(0));
}
function cBrowser_FValidate(tag, field, value, validator, defaultvalue) {
    if((validator.length > 0) && (validator.toLowerCase() != 'password')) {
        switch(validator.toLowerCase()) {
            case 'class_select':
                var c = this.Classifier.GetOnClassification(parseInt(value));
                if(c != null) {
                    var o = document.getElementById('form_classifier_class_scientificname');
                    if(o) { o.disabled = true; o.value = c.ScientificName; }
                    o = document.getElementById('form_classifier_class_commonname');
                    if(o) { o.disabled = true; o.value = c.CommonName; }
                    o = document.getElementById('form_classifier_class_commonpluralname');
                    if(o) { o.disabled = true; o.value = c.CommonNamePlural; }
                }
                break;
            case 'order_select':
                var c = this.Classifier.SubLevel.GetOnClassification(parseInt(value));
                if(c != null) {
                    var o = document.getElementById('form_classifier_order_scientificname');
                    if(o) { o.disabled = true; o.value = c.ScientificName; }
                    o = document.getElementById('form_classifier_order_commonname');
                    if(o) { o.disabled = true; o.value = c.CommonName; }
                    o = document.getElementById('form_classifier_order_commonpluralname');
                    if(o) { o.disabled = true; o.value = c.CommonNamePlural; }
                }
                break;
            case 'family_select':
                var c = this.Classifier.SubLevel.SubLevel.GetOnClassification(parseInt(value));
                if(c != null) {
                    var o = document.getElementById('form_classifier_family_scientificname');
                    if(o) { o.disabled = true; o.value = c.ScientificName; }
                    o = document.getElementById('form_classifier_family_commonname');
                    if(o) { o.disabled = true; o.value = c.CommonName; }
                    o = document.getElementById('form_classifier_family_commonpluralname');
                    if(o) { o.disabled = true; o.value = c.CommonNamePlural; }
                } else {
                    var o = document.getElementById('form_classifier_family_scientificname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_family_commonname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_family_commonpluralname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_family_tag');
                    if(o) { o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>'; }
                    var o = document.getElementById('form_classifier_genus_scientificname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_genus_commonname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_genus_commonpluralname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_genus_tag');
                    if(o) { o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>'; }
                    var o = document.getElementById('form_classifier_species_scientificname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_commonname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_commonpluralname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_tag');
                    if(o) { o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>'; }
                }
                break;
            case 'genus_select':
                var c = this.Classifier.SubLevel.SubLevel.SubLevel.GetOnClassification(parseInt(value));
                if(c != null) {
                    var o = document.getElementById('form_classifier_genus_scientificname');
                    if(o) { o.disabled = true; o.value = c.ScientificName; }
                    o = document.getElementById('form_classifier_genus_commonname');
                    if(o) { o.disabled = true; o.value = c.CommonName; }
                    o = document.getElementById('form_classifier_genus_commonpluralname');
                    if(o) { o.disabled = true; o.value = c.CommonNamePlural; }
                } else {
                    var o = document.getElementById('form_classifier_genus_scientificname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_genus_commonname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_genus_commonpluralname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_genus_tag');
                    if(o) { o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>'; }
                    var o = document.getElementById('form_classifier_species_scientificname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_commonname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_commonpluralname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_tag');
                    if(o) { o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>'; }
                }
                break;
            case 'species_select':
                var c = this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.GetOnClassification(parseInt(value));
                if(c != null) {
                    var o = document.getElementById('form_classifier_species_scientificname');
                    if(o) { o.disabled = true; o.value = c.ScientificName; }
                    o = document.getElementById('form_classifier_species_commonname');
                    if(o) { o.disabled = true; o.value = c.CommonName; }
                    o = document.getElementById('form_classifier_species_commonpluralname');
                    if(o) { o.disabled = true; o.value = c.CommonNamePlural; }
                } else {
                    var o = document.getElementById('form_classifier_species_scientificname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_commonname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_commonpluralname');
                    if(o) { o.disabled = false; o.value = ''; }
                    o = document.getElementById('form_classifier_species_tag');
                    if(o) { o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>'; }
                }
                break;
        }
        var msg = new Array('validator', validator, value, new Array(tag, field, defaultvalue));
        this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    } else {
        this.FValidatePassword(tag, '<span class="form_tag_error_user">Invalid Password&nbsp;[<a href="JavaScript: ShowTip(\'2\');">?</a>]</span>', defaultvalue, field);
    }
    //return(void(0));
}
function cBrowser_FValidateCompare(target, tag, field1, field2) {
    if(document.getElementById(field1).value != document.getElementById(field2).value) {
        document.getElementById(target).innerHTML = tag;
    } else {
        document.getElementById(target).innerHTML = '&nbsp;';
    }
}
function cBrowser_FValidateEnd(arrRet, arrState) {
    if(arrState.length > 1) {
        var a = arrState[1].toLowerCase().split('_');
        if(a.length > 3) {
            if(a[3] == 'select') {
                switch(a[2]) {
                    case 'class':
                        if(this.Classifier.SubLevel.OnLevel.length > 0) {
                            for(var i = this.Classifier.SubLevel.OnLevel.length - 1; i >= 0; i--) {
                                delete this.Classifier.SubLevel.OnLevel[i];
                            }
                        }
                        this.Classifier.SubLevel.OnLevel = [];
                        this.Classifier.SubLevel.OnLevel = new Array();
                        
                        if(this.SELOrder) {
                            eventPop(this.SELOrder, 'focus', Browser.RawInputFocus);
                            eventPop(this.SELOrder, 'change', Browser.RawInputBlur);
                            eventPop(this.SELOrder, 'mousedown', Browser.RawInputMouseDown);
                            eventPop(this.SELOrder, 'mouseover', Browser.RawInputMouseOver);
                            eventPop(this.SELOrder, 'mouseout', Browser.RawInputMouseOut);
                            var p = this.SELOrder.parentNode;
                            if(p) {
                                var o = this.SELOrder.cloneNode(false);
                                p.replaceChild(o, this.SELOrder);
                                this.SELOrder = o;
                            }
                            eventPush(this.SELOrder, 'focus', Browser.RawInputFocus);
                            eventPush(this.SELOrder, 'change', Browser.RawInputBlur);
                            eventPush(this.SELOrder, 'mousedown', Browser.RawInputMouseDown);
                            eventPush(this.SELOrder, 'mouseover', Browser.RawInputMouseOver);
                            eventPush(this.SELOrder, 'mouseout', Browser.RawInputMouseOut);
                        }
                        this.TXTOrderSciName.value = '';
                        this.TXTOrderCommonName.value = '';
                        this.TXTOrderCommonNames.value = '';
                        
                        this.SELOrder.disabled = true;
                        if((typeof(arrRet) == 'object') && (arrRet instanceof Array)) {
                            if(arrRet.length > 0) {
                                var c;
                                for(var i = 0; i < arrRet.length; i++) {
                                    c = new cClassification(arrRet[i][0], arrRet[i][1], arrRet[i][2], arrRet[i][3]);
                                    this.Classifier.SubLevel.OnLevel.push(c);
                                    
                                    this.OPTOrder = document.createElement('option');
                                    this.OPTOrder.text = c.DisplayName;
                                    this.OPTOrder.value = c.ID;
                                    this.OPTOrder.selected = (this.Classifier.SubLevel.SelectedID == c.ID);
                                    this.SELOrder.add(this.OPTOrder, -1);
                                }
                            }
                        }
                        this.SELOrder.disabled = false;
                        
                        var obj = this.SELOrder;
                        obj.focused = false;
                        obj.className='form_raw_input';
                        if(obj.value != obj.lastValue) {
                            var a = obj.id.split('_');
                            Browser.FValidate(a[0]+'_'+a[1]+'_'+a[2]+'_tag', obj.id, obj.value, ((a.length > 3) ? a[2]+'_'+a[3] : a[2]), '&nbsp;');
                            if(a.length > 3) { if(a[3].toLowerCase() == 'select') { obj.lastValue = obj.value; } }
                        }
                        return;
                        break;
                    case 'order':
                        if(this.Classifier.SubLevel.SubLevel.OnLevel.length > 0) {
                            for(var i = this.Classifier.SubLevel.SubLevel.OnLevel.length - 1; i >= 0; i--) {
                                delete this.Classifier.SubLevel.SubLevel.OnLevel[i];
                            }
                        }
                        this.Classifier.SubLevel.SubLevel.OnLevel = [];
                        this.Classifier.SubLevel.SubLevel.OnLevel = new Array();
                        
                        if(this.SELFamily) {
                            eventPop(this.SELFamily, 'focus', Browser.RawInputFocus);
                            eventPop(this.SELFamily, 'change', Browser.RawInputBlur);
                            eventPop(this.SELFamily, 'mousedown', Browser.RawInputMouseDown);
                            eventPop(this.SELFamily, 'mouseover', Browser.RawInputMouseOver);
                            eventPop(this.SELFamily, 'mouseout', Browser.RawInputMouseOut);
                            var p = this.SELFamily.parentNode;
                            if(p) {
                                var o = this.SELFamily.cloneNode(false);
                                p.replaceChild(o, this.SELFamily);
                                this.SELFamily = o;
                            }
                            eventPush(this.SELFamily, 'focus', Browser.RawInputFocus);
                            eventPush(this.SELFamily, 'change', Browser.RawInputBlur);
                            eventPush(this.SELFamily, 'mousedown', Browser.RawInputMouseDown);
                            eventPush(this.SELFamily, 'mouseover', Browser.RawInputMouseOver);
                            eventPush(this.SELFamily, 'mouseout', Browser.RawInputMouseOut);
                        }
                        
                        this.TXTFamilySciName.value = '';
                        this.TXTFamilyCommonName.value = '';
                        this.TXTFamilyCommonNames.value = '';
                        
                        this.SELFamily.disabled = true;
                        this.OPTFamily = document.createElement('option');
                        this.OPTFamily.text = 'Input New Family...';
                        this.OPTFamily.value = '0';
                        this.OPTFamily.selected = true;
                        this.SELFamily.add(this.OPTFamily, 0);
                        
                        if((typeof(arrRet) == 'object') && (arrRet instanceof Array)) {
                            if(arrRet.length > 0) {
                                var c;
                                for(var i = 0; i < arrRet.length; i++) {
                                    c = new cClassification(arrRet[i][0], arrRet[i][1], arrRet[i][2], arrRet[i][3]);
                                    this.Classifier.SubLevel.SubLevel.OnLevel.push(c);
                                    
                                    this.OPTFamily = document.createElement('option');
                                    this.OPTFamily.text = c.DisplayName;
                                    this.OPTFamily.value = c.ID;
                                    this.OPTFamily.selected = (this.Classifier.SubLevel.SubLevel.SelectedID == c.ID);
                                    this.SELFamily.add(this.OPTFamily, -1);
                                }
                            }
                            var o = document.getElementById('form_classifier_order_tag');
                            o.innerHTML = '&nbsp;';
                            var o = document.getElementById('form_classifier_order_scientificname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            var o = document.getElementById('form_classifier_order_commonname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            var o = document.getElementById('form_classifier_order_commonpluralname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                        } else {
                            var o = document.getElementById('form_classifier_family_tag');
                            o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
                        }
                        this.SELFamily.disabled = false;
                        
                        var obj = this.SELFamily;
                        obj.focused = false;
                        obj.className='form_raw_input';
                        if(obj.value != obj.lastValue) {
                            var a = obj.id.split('_');
                            Browser.FValidate(a[0]+'_'+a[1]+'_'+a[2]+'_tag', obj.id, obj.value, ((a.length > 3) ? a[2]+'_'+a[3] : a[2]), '&nbsp;');
                            if(a.length > 3) { if(a[3].toLowerCase() == 'select') { obj.lastValue = obj.value; } }
                        }
                        return;
                        break;
                    case 'family':
                        if(this.Classifier.SubLevel.SubLevel.SubLevel.OnLevel.length > 0) {
                            for(var i = this.Classifier.SubLevel.SubLevel.SubLevel.OnLevel.length - 1; i >= 0; i--) {
                                delete this.Classifier.SubLevel.SubLevel.SubLevel.OnLevel[i];
                            }
                        }
                        this.Classifier.SubLevel.SubLevel.SubLevel.OnLevel = [];
                        this.Classifier.SubLevel.SubLevel.SubLevel.OnLevel = new Array();
                        
                        if(this.SELGenus) {
                            eventPop(this.SELGenus, 'focus', Browser.RawInputFocus);
                            eventPop(this.SELGenus, 'change', Browser.RawInputBlur);
                            eventPop(this.SELGenus, 'mousedown', Browser.RawInputMouseDown);
                            eventPop(this.SELGenus, 'mouseover', Browser.RawInputMouseOver);
                            eventPop(this.SELGenus, 'mouseout', Browser.RawInputMouseOut);
                            var p = this.SELGenus.parentNode;
                            if(p) {
                                var o = this.SELGenus.cloneNode(false);
                                p.replaceChild(o, this.SELGenus);
                                this.SELGenus = o;
                            }
                            eventPush(this.SELGenus, 'focus', Browser.RawInputFocus);
                            eventPush(this.SELGenus, 'change', Browser.RawInputBlur);
                            eventPush(this.SELGenus, 'mousedown', Browser.RawInputMouseDown);
                            eventPush(this.SELGenus, 'mouseover', Browser.RawInputMouseOver);
                            eventPush(this.SELGenus, 'mouseout', Browser.RawInputMouseOut);
                        }
                        
                        this.TXTGenusSciName.value = '';
                        this.TXTGenusCommonName.value = '';
                        this.TXTGenusCommonNames.value = '';
                        
                        this.SELGenus.disabled = true;
                        this.OPTGenus = document.createElement('option');
                        this.OPTGenus.text = 'Input New Genus...';
                        this.OPTGenus.value = '0';
                        this.OPTGenus.selected = true;
                        this.SELGenus.add(this.OPTGenus, 0);
                        
                        if((typeof(arrRet) == 'object') && (arrRet instanceof Array)) {
                            if(arrRet.length > 0) {
                                var c;
                                for(var i = 0; i < arrRet.length; i++) {
                                    c = new cClassification(arrRet[i][0], arrRet[i][1], arrRet[i][2], arrRet[i][3]);
                                    this.Classifier.SubLevel.SubLevel.SubLevel.OnLevel.push(c);
                                    
                                    this.OPTGenus = document.createElement('option');
                                    this.OPTGenus.text = c.DisplayName;
                                    this.OPTGenus.value = c.ID;
                                    this.OPTGenus.selected = (this.Classifier.SubLevel.SubLevel.SubLevel.SelectedID == c.ID);
                                    this.SELGenus.add(this.OPTGenus, -1);
                                }
                            }
                            var o = document.getElementById('form_classifier_family_tag');
                            o.innerHTML = '&nbsp;';
                            var o = document.getElementById('form_classifier_family_scientificname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            var o = document.getElementById('form_classifier_family_commonname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            var o = document.getElementById('form_classifier_family_commonpluralname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                        } else {
                            var o = document.getElementById('form_classifier_genus_tag');
                            o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
                        }
                        this.SELGenus.disabled = false;
                        
                        var obj = this.SELGenus;
                        obj.focused = false;
                        obj.className='form_raw_input';
                        if(obj.value != obj.lastValue) {
                            var a = obj.id.split('_');
                            Browser.FValidate(a[0]+'_'+a[1]+'_'+a[2]+'_tag', obj.id, obj.value, ((a.length > 3) ? a[2]+'_'+a[3] : a[2]), '&nbsp;');
                            if(a.length > 3) { if(a[3].toLowerCase() == 'select') { obj.lastValue = obj.value; } }
                        }
                        return;
                        break;
                    case 'genus':
                        if(this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.OnLevel.length > 0) {
                            for(var i = this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.OnLevel.length - 1; i >= 0; i--) {
                                delete this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.OnLevel[i];
                            }
                        }
                        this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.OnLevel = [];
                        this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.OnLevel = new Array();
                        
                        if(this.SELSpecies) {
                            eventPop(this.SELSpecies, 'focus', Browser.RawInputFocus);
                            eventPop(this.SELSpecies, 'change', Browser.RawInputBlur);
                            eventPop(this.SELSpecies, 'mousedown', Browser.RawInputMouseDown);
                            eventPop(this.SELSpecies, 'mouseover', Browser.RawInputMouseOver);
                            eventPop(this.SELSpecies, 'mouseout', Browser.RawInputMouseOut);
                            var p = this.SELSpecies.parentNode;
                            if(p) {
                                var o = this.SELSpecies.cloneNode(false);
                                p.replaceChild(o, this.SELSpecies);
                                this.SELSpecies = o;
                            }
                            eventPush(this.SELSpecies, 'focus', Browser.RawInputFocus);
                            eventPush(this.SELSpecies, 'change', Browser.RawInputBlur);
                            eventPush(this.SELSpecies, 'mousedown', Browser.RawInputMouseDown);
                            eventPush(this.SELSpecies, 'mouseover', Browser.RawInputMouseOver);
                            eventPush(this.SELSpecies, 'mouseout', Browser.RawInputMouseOut);
                        }
                        
                        this.TXTSpeciesSciName.value = '';
                        this.TXTSpeciesCommonName.value = '';
                        this.TXTSpeciesCommonNames.value = '';
                        
                        this.SELSpecies.disabled = true;
                        this.OPTSpecies = document.createElement('option');
                        this.OPTSpecies.text = 'Input New Species...';
                        this.OPTSpecies.value = '0';
                        this.OPTSpecies.selected = true;
                        this.SELSpecies.add(this.OPTSpecies, 0);
                        
                        if((typeof(arrRet) == 'object') && (arrRet instanceof Array)) {
                            if(arrRet.length > 0) {
                                var c;
                                for(var i = 0; i < arrRet.length; i++) {
                                    c = new cClassification(arrRet[i][0], arrRet[i][1], arrRet[i][2], arrRet[i][3]);
                                    this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.OnLevel.push(c);
                                    
                                    this.OPTSpecies = document.createElement('option');
                                    this.OPTSpecies.text = c.DisplayName;
                                    this.OPTSpecies.value = c.ID;
                                    this.OPTSpecies.selected = (this.Classifier.SubLevel.SubLevel.SubLevel.SubLevel.SelectedID == c.ID);
                                    this.SELSpecies.add(this.OPTSpecies, -1);
                                }
                            }
                            var o = document.getElementById('form_classifier_genus_tag');
                            o.innerHTML = '&nbsp;';
                            var o = document.getElementById('form_classifier_genus_scientificname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            var o = document.getElementById('form_classifier_genus_commonname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            var o = document.getElementById('form_classifier_genus_commonpluralname');
                            if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                        } else {
                            var o = document.getElementById('form_classifier_species_tag');
                            o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
                        }
                        this.SELSpecies.disabled = false;
                        
                        var obj = this.SELSpecies;
                        obj.focused = false;
                        obj.className='form_raw_input';
                        if(obj.value != obj.lastValue) {
                            var a = obj.id.split('_');
                            Browser.FValidate(a[0]+'_'+a[1]+'_'+a[2]+'_tag', obj.id, obj.value, ((a.length > 3) ? a[2]+'_'+a[3] : a[2]), '&nbsp;');
                            if(a.length > 3) { if(a[3].toLowerCase() == 'select') { obj.lastValue = obj.value; } }
                        }
                        return;
                        break;
                    case 'species':
                        var o = document.getElementById('form_classifier_species_select');
                        if(o) {
                            if(parseInt(o.value) > 0) {
                                var o = document.getElementById('form_classifier_species_tag');
                                o.innerHTML = '&nbsp;';
                                var o = document.getElementById('form_classifier_species_scientificname');
                                if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                                var o = document.getElementById('form_classifier_species_commonname');
                                if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                                var o = document.getElementById('form_classifier_species_commonpluralname');
                                if(o) { o.disabled = false; o.style.color = '#010101'; o.disabled = true; }
                            } else {
                                var o = document.getElementById('form_classifier_species_tag');
                                o.innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
                            }
                        }
                        return;
                        break;
                }
            }
        }
    }
    if((arrRet.length > 1) && (arrState.length > 2)) {
        var oT = document.getElementById(arrState[0]);
        var oV = document.getElementById(arrState[1]);
        if(parseInt(arrRet[0]) == 1) {
            if(oT) { oT.innerHTML = arrState[2]; }
            if(oV) { oV.value = arrRet[1]; }
        } else if(oV && (oV.value.length < 1) && (arrState[0].toLowerCase().indexOf('_login_') >= 0)) {
            if(oT) { oT.innerHTML = arrState[2]; }
        } else {
            if(oT) { oT.innerHTML = arrRet[1]; }
            if(oV) { oV.focus(); }
        }
    }
}
function cBrowser_FValidatePassword(target, tag, defaulttag, field) {
    var pass = document.getElementById(field).value;
    var validated = true;
    if(pass.length > 0) {
        if(pass.length > 7) {
            if(pass.search(/[a-z]/) >= 0) {
                if(pass.search(/[A-Z]/) >= 0) {
                    if(pass.search(/[0-9]/) >= 0) {
                        if(pass.search(/[^a-zA-Z0-9]/) < 0) { validated = false; }
                    } else { validated = false; }
                } else { validated = false; }
            } else { validated = false; }
        } else { validated = false; }
    }
    if(!validated) {
        document.getElementById(target).innerHTML = tag;
    } else {
        if(pass.length < 1) {
            document.getElementById(target).innerHTML = defaulttag;
        } else {
            document.getElementById(target).innerHTML = '&nbsp;';//defaulttag;
        }
    }
}
function cBrowser_RealFadeIn(id, state) {
    if(state < 10) {
        try{ajaxWindows[id].wndbodyloading.style.opacity = state/10;}catch(err){}
	    try{ajaxWindows[id].wndbodyloading.style.filter = 'alpha(opacity='+(state*10)+')';}catch(err){}
	    setTimeout( "Browser.RealFadeIn('"+id+"', "+(state+1)+")", 10);
    }
    else {
        try{ajaxWindows[id].wndbodyloading.style.opacity = state/10;}catch(err){}
	    try{ajaxWindows[id].wndbodyloading.style.filter = 'alpha(opacity='+(state*10)+')';}catch(err){}
        ajaxWindowLoadEnable(id);
    }
}
function cBrowser_RealFadeOut(id, state) {
    if(state > 0) {
        try{ajaxWindows[id].wnd.style.opacity = state/10;}catch(err){}
	    try{ajaxWindows[id].wnd.style.filter = 'alpha(opacity='+(state*10)+')';}catch(err){}
	    setTimeout( "Browser.RealFadeOut('"+id+"', "+(state-1)+")", 10);
    }
    else {
        ajaxRemoveWindow(id);
    }
}
function cBrowser_GetEventKey(e) {
    var ret = new Array();
    ret.push((window.event) ? event.keyCode : (e.which ? e.which : e.keyCode));
    ret.push(String.fromCharCode(ret[0]));
    return(ret);
}
function cBrowser_GetFirstAjaxID() {
    var aID = 0;
    if(this.Ajax.length <= aID) { aID = this.CreateAjax(); }
    return(aID);
}
function cBrowser_GetFreeAjaxID() {
    var Ajx = this.AjaxID;
    this.AjaxID++;
    return(Ajx);
}
function cBrowser_GetAjax(id) {
    if(id < 0) { return(null); }
    if(this.Ajax.length > 0) {
        for(var i = this.Ajax.length - 1; i >= 0; i--) {
            if(this.Ajax[i].ID == id) {
                return(this.Ajax[i]);
            }
        }
    }
    return(null);
}
function cBrowser_GetCooldownOverlay(size) {
    if(size.length < 0) { return(null); }
    if(this.CooldownOverlays.length > 0) {
        for(var i = this.CooldownOverlays.length - 1; i >= 0; i--) {
            if(this.CooldownOverlays[i].Size == size) {
                return(this.CooldownOverlays[i]);
            }
        }
    }
    return(null);
}
function cBrowser_GetMouseCords(e) {
    e = e || window.event;
    if(e.pageX || e.pageY){ 
        return(new Array(e.pageX, e.pageY)); 
    } 
    return(new Array(e.clientX + document.body.scrollLeft - document.body.clientLeft, e.clientY + document.body.scrollTop  - document.body.clientTop));
}
function cBrowser_GetPosition(obj) {
    var output = new Object();
    var mytop=0, myleft=0;
    output.Width = obj.offsetWidth;
    output.Height = obj.offsetHeight;
    while( obj) {
        mytop+= obj.offsetTop;
        myleft+= obj.offsetLeft;
        obj= obj.offsetParent;
    }
    output.X = myleft;
    output.Y = mytop;
    return(output);
}
function cBrowser_GetTextSize(text, fontFamily, fontSize, fontWeight, textDecoration, fontStyle) {
    var sizer = document.getElementById('spanSizeCalc');
    sizer.innerHTML = text;
    sizer.style.fontFamily = fontFamily;
    sizer.style.fontSize = fontSize;
    sizer.style.fontWeight = fontWeight;
    sizer.style.textDecoration = textDecoration;
    sizer.style.fontStyle = fontStyle;
    sizer = this.GetPosition(sizer);
    return(sizer);
}
function cBrowser_HideAll() {
    var o = document.getElementById('divLoading'); if(o) { o.style.display = 'none'; o.style.visibility = 'hidden'; }
    var o = document.getElementById('divMain'); if(o) { o.style.display = 'none'; o.style.visibility = 'hidden'; }
    var o = document.getElementById('divSystem'); if(o) { o.style.display = 'none'; o.style.visibility = 'hidden'; }
    if(this.SysDirectMessage == true) { this.HideDirectMessage(); }
    if(this.SysClassifier == true) { this.HideClassifier(); }
    if(this.SysLogin == true) { this.HideLogin(); }
    if(this.SysLostPassword == true) { this.HideLostPassword(); }
    if(this.SysLostUsername == true) { this.HideLostUsername(); }
    if(this.SysPasswordReset == true) { this.HidePasswordReset(); }
    if(this.SysRegistration == true) { this.HideRegistration(); }
}
function cBrowser_HideLoading() {
    var o = document.getElementById('divLoading');
    if(o) {
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
    }
}
function cBrowser_HideDirectMessage() {
    var o = document.getElementById('divSystem');
    if(o) {
        document.getElementById('img_sys_directmessage_icon').src = 'img/icons/32/blank.png';
        document.getElementById('spn_sys_directmessage_title').innerHTML = '';
        document.getElementById('spn_sys_directmessage_subtitle').innerHTML = '';
        document.getElementById('spn_sys_directmessage_greeting').innerHTML = '';
        document.getElementById('spn_sys_directmessage_subgreeting').innerHTML = '';
        document.getElementById('spn_sys_directmessage_summary').innerHTML = '';
        document.getElementById('spn_sys_directmessage_detail').innerHTML = '';
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemDirectMessage').style.display = 'none';
        document.getElementById('spnSystemDirectMessage').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
    }
    this.SysDirectMessage = false;
}
function cBrowser_HideClassifier() {
    var o = document.getElementById('divSystem');
    if(o) {
        eventPop(this.SELDomain, 'focus', Browser.RawInputFocus);
        eventPop(this.SELDomain, 'change', Browser.RawInputBlur);
        eventPop(this.SELDomain, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELDomain, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELDomain, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTDomainSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTDomainSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTDomainSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTDomainSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTDomainSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTDomainCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTDomainCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTDomainCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTDomainCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTDomainCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTDomainCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTDomainCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTDomainCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTDomainCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTDomainCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELKingdom, 'focus', Browser.RawInputFocus);
        eventPop(this.SELKingdom, 'change', Browser.RawInputBlur);
        eventPop(this.SELKingdom, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELKingdom, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELKingdom, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTKingdomSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTKingdomSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTKingdomSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTKingdomSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTKingdomSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTKingdomCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTKingdomCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTKingdomCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTKingdomCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTKingdomCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTKingdomCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTKingdomCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTKingdomCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTKingdomCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTKingdomCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELPhylum, 'focus', Browser.RawInputFocus);
        eventPop(this.SELPhylum, 'change', Browser.RawInputBlur);
        eventPop(this.SELPhylum, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELPhylum, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELPhylum, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTPhylumSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPhylumSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTPhylumSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPhylumSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPhylumSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTPhylumCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPhylumCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTPhylumCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPhylumCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPhylumCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTPhylumCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPhylumCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTPhylumCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPhylumCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPhylumCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELSubPhylum, 'focus', Browser.RawInputFocus);
        eventPop(this.SELSubPhylum, 'change', Browser.RawInputBlur);
        eventPop(this.SELSubPhylum, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELSubPhylum, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELSubPhylum, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTSubPhylumSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTSubPhylumSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTSubPhylumSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTSubPhylumSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTSubPhylumSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTSubPhylumCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTSubPhylumCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTSubPhylumCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTSubPhylumCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTSubPhylumCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTSubPhylumCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTSubPhylumCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTSubPhylumCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTSubPhylumCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTSubPhylumCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELClass, 'focus', Browser.RawInputFocus);
        eventPop(this.SELClass, 'change', Browser.RawInputBlur);
        eventPop(this.SELClass, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELClass, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELClass, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTClassSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTClassSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTClassSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTClassSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTClassSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTClassCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTClassCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTClassCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTClassCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTClassCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTClassCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTClassCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTClassCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTClassCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTClassCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELOrder, 'focus', Browser.RawInputFocus);
        eventPop(this.SELOrder, 'change', Browser.RawInputBlur);
        eventPop(this.SELOrder, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELOrder, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELOrder, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTOrderSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTOrderSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTOrderSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTOrderSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTOrderSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTOrderCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTOrderCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTOrderCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTOrderCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTOrderCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTOrderCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTOrderCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTOrderCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTOrderCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTOrderCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELFamily, 'focus', Browser.RawInputFocus);
        eventPop(this.SELFamily, 'change', Browser.RawInputBlur);
        eventPop(this.SELFamily, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELFamily, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELFamily, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTFamilySciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTFamilySciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTFamilySciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTFamilySciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTFamilySciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTFamilyCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTFamilyCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTFamilyCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTFamilyCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTFamilyCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTFamilyCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTFamilyCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTFamilyCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTFamilyCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTFamilyCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELGenus, 'focus', Browser.RawInputFocus);
        eventPop(this.SELGenus, 'change', Browser.RawInputBlur);
        eventPop(this.SELGenus, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELGenus, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELGenus, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTGenusSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTGenusSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTGenusSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTGenusSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTGenusSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTGenusCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTGenusCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTGenusCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTGenusCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTGenusCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTGenusCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTGenusCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTGenusCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTGenusCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTGenusCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.SELSpecies, 'focus', Browser.RawInputFocus);
        eventPop(this.SELSpecies, 'change', Browser.RawInputBlur);
        eventPop(this.SELSpecies, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.SELSpecies, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.SELSpecies, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTSpeciesSciName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTSpeciesSciName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTSpeciesSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTSpeciesSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTSpeciesSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTSpeciesCommonName, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTSpeciesCommonName, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTSpeciesCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTSpeciesCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTSpeciesCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPop(this.TXTSpeciesCommonNames, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTSpeciesCommonNames, 'blur', Browser.RawInputBlur);
        eventPop(this.TXTSpeciesCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTSpeciesCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTSpeciesCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        this.TXTDomainSciName.value = '';
        this.TXTDomainCommonName.value = '';
        this.TXTDomainCommonNames.value = '';
        this.TXTKingdomSciName.value = '';
        this.TXTKingdomCommonName.value = '';
        this.TXTKingdomCommonNames.value = '';
        this.TXTPhylumSciName.value = '';
        this.TXTPhylumCommonName.value = '';
        this.TXTPhylumCommonNames.value = '';
        this.TXTSubPhylumSciName.value = '';
        this.TXTSubPhylumCommonName.value = '';
        this.TXTSubPhylumCommonNames.value = '';
        this.TXTClassSciName.value = '';
        this.TXTClassCommonName.value = '';
        this.TXTClassCommonNames.value = '';
        this.TXTOrderSciName.value = '';
        this.TXTOrderCommonName.value = '';
        this.TXTOrderCommonNames.value = '';
        this.TXTFamilySciName.value = '';
        this.TXTFamilyCommonName.value = '';
        this.TXTFamilyCommonNames.value = '';
        this.TXTGenusSciName.value = '';
        this.TXTGenusCommonName.value = '';
        this.TXTGenusCommonNames.value = '';
        this.TXTSpeciesSciName.value = '';
        this.TXTSpeciesCommonName.value = '';
        this.TXTSpeciesCommonNames.value = '';
        if((this.FocusObj == this.SELDomain) || (this.FocusObj == this.TXTDomainSciName) || (this.FocusObj == this.TXTDomainCommonName) || (this.FocusObj == this.TXTDomainCommonNames) || (this.FocusObj == this.SELKingdom) || (this.FocusObj == this.TXTKingdomSciName) || (this.FocusObj == this.TXTKingdomCommonName) || (this.FocusObj == this.TXTKingdomCommonNames) || (this.FocusObj == this.SELPhylum) || (this.FocusObj == this.TXTPhylumSciName) || (this.FocusObj == this.TXTPhylumCommonName) || (this.FocusObj == this.TXTPhylumCommonNames) || (this.FocusObj == this.SELSubPhylum) || (this.FocusObj == this.TXTSubPhylumSciName) || (this.FocusObj == this.TXTSubPhylumCommonName) || (this.FocusObj == this.TXTSubPhylumCommonNames) || (this.FocusObj == this.SELClass) || (this.FocusObj == this.TXTClassSciName) || (this.FocusObj == this.TXTClassCommonName) || (this.FocusObj == this.TXTClassCommonNames) || (this.FocusObj == this.SELOrder) || (this.FocusObj == this.TXTOrderSciName) || (this.FocusObj == this.TXTOrderCommonName) || (this.FocusObj == this.TXTOrderCommonNames) || (this.FocusObj == this.SELFamily) || (this.FocusObj == this.TXTFamilySciName) || (this.FocusObj == this.TXTFamilyCommonName) || (this.FocusObj == this.TXTFamilyCommonNames) || (this.FocusObj == this.SELGenus) || (this.FocusObj == this.TXTGenusSciName) || (this.FocusObj == this.TXTGenusCommonName) || (this.FocusObj == this.TXTGenusCommonNames) || (this.FocusObj == this.SELSpecies) || (this.FocusObj == this.TXTSpeciesSciName) || (this.FocusObj == this.TXTSpeciesCommonName) || (this.FocusObj == this.TXTSpeciesCommonNames)) { this.FocusObj = null; }
        
        document.getElementById('form_classifier_domain_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_kingdom_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_phylum_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_subphylum_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_class_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_order_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_family_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_genus_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_species_tag').innerHTML = '&nbsp;';
        
        document.getElementById('td_classifier_domain_select').removeChild(this.SELDomain);
        document.getElementById('td_classifier_domain_scientificname').removeChild(this.TXTDomainSciName);
        document.getElementById('td_classifier_domain_commonname').removeChild(this.TXTDomainCommonName);
        document.getElementById('td_classifier_domain_commonpluralname').removeChild(this.TXTDomainCommonNames);
        document.getElementById('td_classifier_kingdom_select').removeChild(this.SELKingdom);
        document.getElementById('td_classifier_kingdom_scientificname').removeChild(this.TXTKingdomSciName);
        document.getElementById('td_classifier_kingdom_commonname').removeChild(this.TXTKingdomCommonName);
        document.getElementById('td_classifier_kingdom_commonpluralname').removeChild(this.TXTKingdomCommonNames);
        document.getElementById('td_classifier_phylum_select').removeChild(this.SELPhylum);
        document.getElementById('td_classifier_phylum_scientificname').removeChild(this.TXTPhylumSciName);
        document.getElementById('td_classifier_phylum_commonname').removeChild(this.TXTPhylumCommonName);
        document.getElementById('td_classifier_phylum_commonpluralname').removeChild(this.TXTPhylumCommonNames);
        document.getElementById('td_classifier_subphylum_select').removeChild(this.SELSubPhylum);
        document.getElementById('td_classifier_subphylum_scientificname').removeChild(this.TXTSubPhylumSciName);
        document.getElementById('td_classifier_subphylum_commonname').removeChild(this.TXTSubPhylumCommonName);
        document.getElementById('td_classifier_subphylum_commonpluralname').removeChild(this.TXTSubPhylumCommonNames);
        document.getElementById('td_classifier_class_select').removeChild(this.SELClass);
        document.getElementById('td_classifier_class_scientificname').removeChild(this.TXTClassSciName);
        document.getElementById('td_classifier_class_commonname').removeChild(this.TXTClassCommonName);
        document.getElementById('td_classifier_class_commonpluralname').removeChild(this.TXTClassCommonNames);
        document.getElementById('td_classifier_order_select').removeChild(this.SELOrder);
        document.getElementById('td_classifier_order_scientificname').removeChild(this.TXTOrderSciName);
        document.getElementById('td_classifier_order_commonname').removeChild(this.TXTOrderCommonName);
        document.getElementById('td_classifier_order_commonpluralname').removeChild(this.TXTOrderCommonNames);
        document.getElementById('td_classifier_family_select').removeChild(this.SELFamily);
        document.getElementById('td_classifier_family_scientificname').removeChild(this.TXTFamilySciName);
        document.getElementById('td_classifier_family_commonname').removeChild(this.TXTFamilyCommonName);
        document.getElementById('td_classifier_family_commonpluralname').removeChild(this.TXTFamilyCommonNames);
        document.getElementById('td_classifier_genus_select').removeChild(this.SELGenus);
        document.getElementById('td_classifier_genus_scientificname').removeChild(this.TXTGenusSciName);
        document.getElementById('td_classifier_genus_commonname').removeChild(this.TXTGenusCommonName);
        document.getElementById('td_classifier_genus_commonpluralname').removeChild(this.TXTGenusCommonNames);
        document.getElementById('td_classifier_species_select').removeChild(this.SELSpecies);
        document.getElementById('td_classifier_species_scientificname').removeChild(this.TXTSpeciesSciName);
        document.getElementById('td_classifier_species_commonname').removeChild(this.TXTSpeciesCommonName);
        document.getElementById('td_classifier_species_commonpluralname').removeChild(this.TXTSpeciesCommonNames);
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemClassifier').style.display = 'none';
        document.getElementById('spnSystemClassifier').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
        this.FocusObj = null;
    }
    this.SysClassifier = false;
}
function cBrowser_HideLogin() {
    var o = document.getElementById('divSystem');
    if(o) {
        eventPop(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTPassword, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
        eventPop(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);
        
        this.TXTUsername.value = '';
        this.TXTPassword.value = '';
        if((this.FocusObj == this.TXTUsername) || (this.FocusObj == this.TXTPassword)) { this.FocusObj = null; }
        document.getElementById('td_login_username').removeChild(this.TXTUsername);
        document.getElementById('td_login_password').removeChild(this.TXTPassword);
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemLogin').style.display = 'none';
        document.getElementById('spnSystemLogin').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
        this.FocusObj = null;
    }
    this.SysLogin = false;
}
function cBrowser_HideLostPassword() {
    var o = document.getElementById('divSystem');
    if(o) {
        eventPop(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTEmail, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTEmail, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTCAPTCHA, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.CAPTCHAReloadIcon, 'click', Browser.ButtonInputClick);
        eventPop(this.CAPTCHAReloadIcon, 'mousedown', Browser.ButtonInputMouseDown);
        eventPop(this.CAPTCHAReloadIcon, 'mouseover', Browser.ButtonInputMouseOver);
        eventPop(this.CAPTCHAReloadIcon, 'mouseout', Browser.ButtonInputMouseOut);
        eventPop(this.CAPTCHAReloadIcon, 'mouseup', Browser.ButtonInputMouseUp);
        
        this.TXTUsername.value = '';
        this.TXTEmail.value = '';
        this.TXTCAPTCHA.value = '';
        if((this.FocusObj == this.TXTUsername) || (this.FocusObj == this.TXTEmail) || (this.FocusObj == this.TXTCAPTCHA)) { this.FocusObj = null; }
        document.getElementById('td_lostpassword_username').removeChild(this.TXTUsername);
        document.getElementById('td_lostpassword_email').removeChild(this.TXTEmail);
        document.getElementById('td_lostpassword_captcha').removeChild(this.TXTCAPTCHA);
        document.getElementById('td_lostpassword_captcha_icon_reload').removeChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_lostpassword_captcha_image').removeChild(this.CAPTCHAImage);
        this.FCaptchaClear();
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemLostPassword').style.display = 'none';
        document.getElementById('spnSystemLostPassword').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
        this.FocusObj = null;
    }
    this.SysLostPassword = false;
}
function cBrowser_HideLostUsername() {
    var o = document.getElementById('divSystem');
    if(o) {
        eventPop(this.TXTEmail, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTEmail, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTCAPTCHA, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.CAPTCHAReloadIcon, 'click', Browser.ButtonInputClick);
        eventPop(this.CAPTCHAReloadIcon, 'mousedown', Browser.ButtonInputMouseDown);
        eventPop(this.CAPTCHAReloadIcon, 'mouseover', Browser.ButtonInputMouseOver);
        eventPop(this.CAPTCHAReloadIcon, 'mouseout', Browser.ButtonInputMouseOut);
        eventPop(this.CAPTCHAReloadIcon, 'mouseup', Browser.ButtonInputMouseUp);
        
        this.TXTEmail.value = '';
        this.TXTCAPTCHA.value = '';
        if((this.FocusObj == this.TXTEmail) || (this.FocusObj == this.TXTCAPTCHA)) { this.FocusObj = null; }
        document.getElementById('td_lostusername_email').removeChild(this.TXTEmail);
        document.getElementById('td_lostusername_captcha').removeChild(this.TXTCAPTCHA);
        document.getElementById('td_lostusername_captcha_icon_reload').removeChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_lostusername_captcha_image').removeChild(this.CAPTCHAImage);
        this.FCaptchaClear();
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemLostUsername').style.display = 'none';
        document.getElementById('spnSystemLostUsername').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
        this.FocusObj = null;
    }
    this.SysLostUsername = false;
}
function cBrowser_HidePasswordReset() {
    var o = document.getElementById('divSystem');
    if(o) {
        eventPop(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTPassword, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
        eventPop(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTPasswordConfirm, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPasswordConfirm, 'blur', Browser.RawInputPasswordBlur);
        eventPop(this.TXTPasswordConfirm, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPasswordConfirm, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPasswordConfirm, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTCAPTCHA, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.CAPTCHAReloadIcon, 'click', Browser.ButtonInputClick);
        eventPop(this.CAPTCHAReloadIcon, 'mousedown', Browser.ButtonInputMouseDown);
        eventPop(this.CAPTCHAReloadIcon, 'mouseover', Browser.ButtonInputMouseOver);
        eventPop(this.CAPTCHAReloadIcon, 'mouseout', Browser.ButtonInputMouseOut);
        eventPop(this.CAPTCHAReloadIcon, 'mouseup', Browser.ButtonInputMouseUp);
        
        this.TXTCode.value = '';
        this.TXTUsername.value = '';
        this.TXTPassword.value = '';
        this.TXTPasswordConfirm.value = '';
        this.TXTCAPTCHA.value = '';
        if((this.FocusObj == this.TXTUsername) || (this.FocusObj == this.TXTPassword) || (this.FocusObj == this.TXTPasswordConfirm) || (this.FocusObj == this.TXTCAPTCHA)) { this.FocusObj = null; }
        document.getElementById('td_passwordreset_username').removeChild(this.TXTCode);
        document.getElementById('td_passwordreset_username').removeChild(this.TXTUsername);
        document.getElementById('td_passwordreset_password').removeChild(this.TXTPassword);
        document.getElementById('td_passwordreset_passwordconfirm').removeChild(this.TXTPasswordConfirm);
        document.getElementById('td_passwordreset_captcha').removeChild(this.TXTCAPTCHA);
        document.getElementById('td_passwordreset_captcha_icon_reload').removeChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_passwordreset_captcha_image').removeChild(this.CAPTCHAImage);
        this.FCaptchaClear();
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemPasswordReset').style.display = 'none';
        document.getElementById('spnSystemPasswordReset').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
        this.FocusObj = null;
    }
    this.SysPasswordReset = false;
}
function cBrowser_HideRegistration() {
    var o = document.getElementById('divSystem');
    if(o) {
        eventPop(this.TXTNameFirst, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTNameFirst, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTNameFirst, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTNameFirst, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTNameFirst, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTNameMiddle, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTNameMiddle, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTNameMiddle, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTNameMiddle, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTNameMiddle, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTNameLast, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTNameLast, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTNameLast, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTNameLast, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTNameLast, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTEmail, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTEmail, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTEmailConfirm, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTEmailConfirm, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTEmailConfirm, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTEmailConfirm, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTEmailConfirm, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTPassword, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
        eventPop(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTPasswordConfirm, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTPasswordConfirm, 'blur', Browser.RawInputPasswordBlur);
        eventPop(this.TXTPasswordConfirm, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTPasswordConfirm, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTPasswordConfirm, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPop(this.TXTCAPTCHA, 'blur', Browser.RawInputUsernameBlur);
        eventPop(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPop(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPop(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPop(this.CAPTCHAReloadIcon, 'click', Browser.ButtonInputClick);
        eventPop(this.CAPTCHAReloadIcon, 'mousedown', Browser.ButtonInputMouseDown);
        eventPop(this.CAPTCHAReloadIcon, 'mouseover', Browser.ButtonInputMouseOver);
        eventPop(this.CAPTCHAReloadIcon, 'mouseout', Browser.ButtonInputMouseOut);
        eventPop(this.CAPTCHAReloadIcon, 'mouseup', Browser.ButtonInputMouseUp);
        
        this.TXTNameFirst.value = '';
        this.TXTNameMiddle.value = '';
        this.TXTNameLast.value = '';
        this.TXTEmail.value = '';
        this.TXTEmailConfirm.value = '';
        this.TXTUsername.value = '';
        this.TXTPassword.value = '';
        this.TXTPasswordConfirm.value = '';
        this.TXTCAPTCHA.value = '';
        if((this.FocusObj == this.TXTNameFirst) || (this.FocusObj == this.TXTNameMiddle) || (this.FocusObj == this.TXTNameLast) || (this.FocusObj == this.TXTEmail) || (this.FocusObj == this.TXTEmailConfirm) || (this.FocusObj == this.TXTUsername) || (this.FocusObj == this.TXTPassword) || (this.FocusObj == this.TXTPasswordConfirm) || (this.FocusObj == this.TXTCAPTCHA)) { this.FocusObj = null; }
        document.getElementById('spn_registration_name_first').removeChild(this.TXTNameFirst);
        document.getElementById('spn_registration_name_middle').removeChild(this.TXTNameMiddle);
        document.getElementById('spn_registration_name_last').removeChild(this.TXTNameLast);
        document.getElementById('td_registration_email').removeChild(this.TXTEmail);
        document.getElementById('td_registration_emailconfirm').removeChild(this.TXTEmailConfirm);
        document.getElementById('td_registration_username').removeChild(this.TXTUsername);
        document.getElementById('td_registration_password').removeChild(this.TXTPassword);
        document.getElementById('td_registration_passwordconfirm').removeChild(this.TXTPasswordConfirm);
        document.getElementById('td_registration_captcha').removeChild(this.TXTCAPTCHA);
        document.getElementById('td_registration_captcha_icon_reload').removeChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_registration_captcha_image').removeChild(this.CAPTCHAImage);
        this.FCaptchaClear();
        o.style.display = 'none';
        o.style.visibility = 'hidden';
        document.getElementById('spnSystemRegistration').style.display = 'none';
        document.getElementById('spnSystemRegistration').style.visibility = 'hidden';
        document.getElementById('divMain').style.display = 'block';
        document.getElementById('divMain').style.visibility = 'visible';
        this.FocusObj = null;
    }
    this.SysRegistration = false;
}
function cBrowser_KeyDown(e) {
    if(Browser.FocusControl != null) {
        var p = Browser.GetEventKey(e);
        return(Browser.FocusControl.FireEvent('keydown', false, false, p));
    }
}
function cBrowser_KeyUp(e) {
    if(Browser.FocusControl != null) {
        var p = Browser.GetEventKey(e);
        return(Browser.FocusControl.FireEvent('keyup', false, false, p));
    }
}
function cBrowser_Load() {
    this.CooldownOverlays.push(new cCooldownOverlay(18));
}
function cBrowser_Login(sUser, sPass, rememberme) {
    this.ShowLoading();
    this.HideLogin();
    var msg;
    if(rememberme != true) { msg = new Array('auth', 'login', sUser, sPass, '0'); }
    else                   { msg = new Array('auth', 'login', sUser, sPass, '1'); }
    this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    return(false);
}
function cBrowser_Logout() {
    this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, new Array('auth', 'logout'));
}
function cBrowser_MouseDown(e) {
    var mc = Browser.GetMouseCords(e);
    this.HideTip();
    var i;
}
function cBrowser_MouseMove(e) {
    var mc = Browser.GetMouseCords(e);
    Browser.MouseX = mc[0];
    Browser.MouseY = mc[1];
}
function cBrowser_MouseUp(e) {
    if(Browser.FocusObj != null) { Browser.FocusObj.focus(); }
}
function cBrowser_PreCache() {
    if(this.PreCached != true) {
        this.PreCached = true;/*
        if(this.Style.PreCacheImages.length > 0) {
            var img = null;
            var p = document.getElementById('divResources');
            for(var i = 0; i < this.Style.PreCacheImages.length; i++) {
                img = document.createElement('img');
                img.setAttribute('id', 'imgPreCache_' + i);
                img.setAttribute('src', this.Style.PreCacheImages[i]);
                p.appendChild(img);
            }
        }*/
    }
}
function cBrowser_RawButtonClick(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focus();
        Browser.FReloadCaptcha();
    }
}
function cBrowser_RawButtonMouseDown(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.style.border = ((obj.style.cursor == 'pointer') ? 'solid 1px #000000' : 'solid 1px #EEEEEE');
    }
}
function cBrowser_RawButtonMouseOver(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.style.border = ((obj.style.cursor == 'pointer') ? 'solid 1px #888888' : 'solid 1px #EEEEEE');
    }
}
function cBrowser_RawButtonMouseOut(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.style.border = 'solid 1px #EEEEEE';
    }
}
function cBrowser_RawButtonMouseUp(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.style.border = ((obj.style.cursor == 'pointer') ? 'solid 1px #888888' : 'solid 1px #EEEEEE');
    }
}
function cBrowser_RawInputChangeConfirm(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focused = false;
        obj.className='form_raw_input';
        var a = obj.id.split('_');
        var b = false;
        var ao = obj.id;
        var ac = obj.id;
        if(a[2].length < 7) { a[2] = a[2] + 'confirm'; ac = a.join('_'); }
        else {
            if(a[2].substr(a[2].length - 7, 7).toLowerCase() != 'confirm') { a[2] = a[2] + 'confirm'; ac = a.join('_'); }
            else { if(a[2].length > 7) { a[2] = a[2].substr(0, a[2].length - 7); } else { a[2] = ''; } ao = a.join('_'); }
        }
        Browser.FValidateCompare(ac+'_tag', '<span class=\'form_tag_error_user\'>Does Not Match&nbsp;[<a href=&quot;JavaScript: ShowTip(\'12\');&quot;>?</a>]</span>', ao, ac);
    }
}
function cBrowser_RawInputFocus(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focused = true;
        obj.lastValue = obj.value;
        obj.className='form_raw_input_focus';
        Browser.FStartValidate(obj.id, obj.value);
    }
}
function cBrowser_RawInputMouseDown(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focus();
    }
}
function cBrowser_RawInputMouseOver(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.className=(obj.focused == true ? 'form_raw_input_focus_hover' : 'form_raw_input_hover');
    }
}
function cBrowser_RawInputMouseOut(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.className=(obj.focused == true ? 'form_raw_input_focus' : 'form_raw_input');
    }
}
function cBrowser_RawInputBlur(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focused = false;
        obj.className='form_raw_input';
        if(obj.value != obj.lastValue) {
            var a = obj.id.split('_');
            Browser.FValidate(a[0]+'_'+a[1]+'_'+a[2]+'_tag', obj.id, obj.value, ((a.length > 3) ? a[2]+'_'+a[3] : a[2]), '&nbsp;');
            if(a.length > 3) { if(a[3].toLowerCase() == 'select') { obj.lastValue = obj.value; } }
        }
    }
}
function cBrowser_RawInputPasswordBlur(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focused = false;
        obj.className='form_raw_input';
        if(obj.value != obj.lastValue) {
            var a = obj.id.split('_');
            if(a[1].toLowerCase() == 'login') {
                Browser.FValidate(obj.id+'_tag', obj.id, obj.value, 'password', '&nbsp;');
            } else {
                Browser.FValidate(obj.id+'_tag', obj.id, obj.value, 'password', '<span class="form_tag_error_user">Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'9\');">?</a>]</span>');
            }
        }
    }
}
function cBrowser_RawInputUsernameBlur(e) {
    var obj = EventObj(e);
    if(obj) {
        if (obj.nodeType == 3)
            obj = obj.parentNode;
        obj.focused = false;
        obj.className='form_raw_input';
        if(obj.value != obj.lastValue) {
            Browser.FValidate(obj.id+'_tag', obj.id, obj.value.replace(/ /g, ''), 'username', '&nbsp;');
        }
    }
}
function cBrowser_Register(sNameFirst, sNameMiddle, sNameLast, sEmail, sEmailConfirm, sUser, sPass, sPassConfirm, sCAPTCHA) {
    this.ShowLoading();
    this.HideRegistration();
    var msg = new Array('auth', 'register', sNameFirst, sNameMiddle, sNameLast, sEmail, sEmailConfirm, sUser, sPass, sPassConfirm, sCAPTCHA);
    this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    return(false);
}
function cBrowser_RemoveAjax(id) {
    if(id < 0) { return(null); }
    var bHit = false;
    if(this.Ajax.length > 0) {
        for(var i = this.Ajax.length - 1; i > 0; i--) {
            if(bHit == true) {
                this.Ajax[i] = this.Ajax[i - 1];
            } else {
                if(this.Ajax[i].ID == id) {
                    this.Ajax[i].Dispose();
                    this.Ajax[i] = this.Ajax[i - 1];
                    bHit = true;
                }
            }
        }
        if(bHit == false) {
            if(this.Ajax[0].ID == id) {
                this.Ajax[0].Dispose();
                bHit = true;
            }
        }
        if(bHit == true) {
            this.Ajax.shift();
        }
    }
}
function cBrowser_RequestLostPassword(sUser, sEmail, sCAPTCHA) {
    this.ShowLoading();
    this.HideLostPassword();
    var msg = new Array('auth', 'requestlostpassword', sUser, sEmail, sCAPTCHA);
    this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    return(false);
}
function cBrowser_RequestLostUsername(sEmail, sCAPTCHA) {
    this.ShowLoading();
    this.HideLostUsername();
    var msg = new Array('auth', 'requestlostusername', sEmail, sCAPTCHA);
    this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    return(false);
}
function cBrowser_ResetPassword(sCode, sUser, sPass, sPassConfirm, sCAPTCHA, rememberme) {
    this.ShowLoading();
    this.HidePasswordReset();
    var msg;
    if(rememberme != true) { msg = new Array('auth', 'passwordreset', sCode, sUser, sPass, sPassConfirm, sCAPTCHA, '0'); }
    else                   { msg = new Array('auth', 'passwordreset', sCode, sUser, sPass, sPassConfirm, sCAPTCHA, '1'); }
    this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
    return(false);
}
function cBrowser_SetFocusControl(control) {
    if(this.FocusControl != control) {
        if(this.FocusControl != null) { this.FocusControl.FireEvent('blur', false, false, null); }
        this.FocusControl = control;
        if(this.FocusControl != null) { this.FocusControl.FireEvent('focus', false, false, null); }
    }
}
function cBrowser_ShowLoading() {
    var o = document.getElementById('divLoading');
    if(o) {
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
    }
}
function cBrowser_ShowDirectMessage(icon, title, subtitle, greeting, subgreeting, summary, detail) {
    var o = document.getElementById('divSystem');
    if(o) {
        document.getElementById('img_sys_directmessage_icon').src = 'img/icons/32/'+icon+'.png';
        document.getElementById('spn_sys_directmessage_title').innerHTML = title;
        document.getElementById('spn_sys_directmessage_subtitle').innerHTML = subtitle;
        document.getElementById('spn_sys_directmessage_greeting').innerHTML = greeting;
        document.getElementById('spn_sys_directmessage_subgreeting').innerHTML = subgreeting;
        document.getElementById('spn_sys_directmessage_summary').innerHTML = summary;
        document.getElementById('spn_sys_directmessage_detail').innerHTML = detail;
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemDirectMessage').style.display = 'block';
        document.getElementById('spnSystemDirectMessage').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
    }
    this.SysDirectMessage = true;
}
function cBrowser_ShowClassifier(obj) {
    var o = document.getElementById('divSystem');
    if(o && (this.ClassifierObj == null)) {
        this.ClassifierObj = obj;
		this.SELDomain = document.createElement('select');
        this.SELDomain.setAttribute('id', 'form_classifier_domain_select');
        this.SELDomain.setAttribute('type', 'text');
        this.SELDomain.setAttribute('tabindex', 1);
        this.SELDomain.focused = false;
        this.SELDomain.className = 'form_raw_input';
        this.SELDomain.style.width = '170px';
        this.OPTDomain = document.createElement('option');
        this.OPTDomain.text = 'Eukaryote (Eukaryota)';
        this.OPTDomain.value = '37';
        this.OPTDomain.selected = true;
        this.SELDomain.add(this.OPTDomain, 0);
        this.SELDomain.disabled = true;
		this.TXTDomainSciName = document.createElement('input');
        this.TXTDomainSciName.setAttribute('id', 'form_classifier_domain_scientificname');
        this.TXTDomainSciName.setAttribute('type', 'text');
        this.TXTDomainSciName.setAttribute('tabindex', 1);
        this.TXTDomainSciName.focused = false;
        this.TXTDomainSciName.className = 'form_raw_input';
        this.TXTDomainSciName.style.width = '170px';
        this.TXTDomainSciName.value = 'Eukaryota';
        this.TXTDomainSciName.disabled = true;
		this.TXTDomainCommonName = document.createElement('input');
        this.TXTDomainCommonName.setAttribute('id', 'form_classifier_domain_commonname');
        this.TXTDomainCommonName.setAttribute('type', 'text');
        this.TXTDomainCommonName.setAttribute('tabindex', 1);
        this.TXTDomainCommonName.focused = false;
        this.TXTDomainCommonName.className = 'form_raw_input';
        this.TXTDomainCommonName.style.width = '170px';
        this.TXTDomainCommonName.value = 'Eukaryote';
        this.TXTDomainCommonName.disabled = true;
		this.TXTDomainCommonNames = document.createElement('input');
        this.TXTDomainCommonNames.setAttribute('id', 'form_classifier_domain_commonpluralname');
        this.TXTDomainCommonNames.setAttribute('type', 'text');
        this.TXTDomainCommonNames.setAttribute('tabindex', 1);
        this.TXTDomainCommonNames.focused = false;
        this.TXTDomainCommonNames.className = 'form_raw_input';
        this.TXTDomainCommonNames.style.width = '170px';
        this.TXTDomainCommonNames.value = 'Eukaryotes';
        this.TXTDomainCommonNames.disabled = true;
        
		this.SELKingdom = document.createElement('select');
        this.SELKingdom.setAttribute('id', 'form_classifier_kingdom_select');
        this.SELKingdom.setAttribute('type', 'text');
        this.SELKingdom.setAttribute('tabindex', 1);
        this.SELKingdom.focused = false;
        this.SELKingdom.className = 'form_raw_input';
        this.SELKingdom.style.width = '170px';
        this.OPTKingdom = document.createElement('option');
        this.OPTKingdom.text = 'Animal (Animalia)';
        this.OPTKingdom.value = '38';
        this.OPTKingdom.selected = true;
        this.SELKingdom.add(this.OPTKingdom, 0);
        this.SELKingdom.disabled = true;
		this.TXTKingdomSciName = document.createElement('input');
        this.TXTKingdomSciName.setAttribute('id', 'form_classifier_kingdom_scientificname');
        this.TXTKingdomSciName.setAttribute('type', 'text');
        this.TXTKingdomSciName.setAttribute('tabindex', 1);
        this.TXTKingdomSciName.focused = false;
        this.TXTKingdomSciName.className = 'form_raw_input';
        this.TXTKingdomSciName.style.width = '170px';
        this.TXTKingdomSciName.value = 'Animalia';
        this.TXTKingdomSciName.disabled = true;
		this.TXTKingdomCommonName = document.createElement('input');
        this.TXTKingdomCommonName.setAttribute('id', 'form_classifier_kingdom_commonname');
        this.TXTKingdomCommonName.setAttribute('type', 'text');
        this.TXTKingdomCommonName.setAttribute('tabindex', 1);
        this.TXTKingdomCommonName.focused = false;
        this.TXTKingdomCommonName.className = 'form_raw_input';
        this.TXTKingdomCommonName.style.width = '170px';
        this.TXTKingdomCommonName.value = 'Animal';
        this.TXTKingdomCommonName.disabled = true;
		this.TXTKingdomCommonNames = document.createElement('input');
        this.TXTKingdomCommonNames.setAttribute('id', 'form_classifier_kingdom_commonpluralname');
        this.TXTKingdomCommonNames.setAttribute('type', 'text');
        this.TXTKingdomCommonNames.setAttribute('tabindex', 1);
        this.TXTKingdomCommonNames.focused = false;
        this.TXTKingdomCommonNames.className = 'form_raw_input';
        this.TXTKingdomCommonNames.style.width = '170px';
        this.TXTKingdomCommonNames.value = 'Animals';
        this.TXTKingdomCommonNames.disabled = true;
        
		this.SELPhylum = document.createElement('select');
        this.SELPhylum.setAttribute('id', 'form_classifier_phylum_select');
        this.SELPhylum.setAttribute('type', 'text');
        this.SELPhylum.setAttribute('tabindex', 1);
        this.SELPhylum.focused = false;
        this.SELPhylum.className = 'form_raw_input';
        this.SELPhylum.style.width = '170px';
        this.OPTPhylum = document.createElement('option');
        this.OPTPhylum.text = 'Chordate (Chordata)';
        this.OPTPhylum.value = '39';
        this.OPTPhylum.selected = true;
        this.SELPhylum.add(this.OPTPhylum, 0);
        this.SELPhylum.disabled = true;
		this.TXTPhylumSciName = document.createElement('input');
        this.TXTPhylumSciName.setAttribute('id', 'form_classifier_phylum_scientificname');
        this.TXTPhylumSciName.setAttribute('type', 'text');
        this.TXTPhylumSciName.setAttribute('tabindex', 1);
        this.TXTPhylumSciName.focused = false;
        this.TXTPhylumSciName.className = 'form_raw_input';
        this.TXTPhylumSciName.style.width = '170px';
        this.TXTPhylumSciName.value = 'Chordata';
        this.TXTPhylumSciName.disabled = true;
		this.TXTPhylumCommonName = document.createElement('input');
        this.TXTPhylumCommonName.setAttribute('id', 'form_classifier_phylum_commonname');
        this.TXTPhylumCommonName.setAttribute('type', 'text');
        this.TXTPhylumCommonName.setAttribute('tabindex', 1);
        this.TXTPhylumCommonName.focused = false;
        this.TXTPhylumCommonName.className = 'form_raw_input';
        this.TXTPhylumCommonName.style.width = '170px';
        this.TXTPhylumCommonName.value = 'Chordate';
        this.TXTPhylumCommonName.disabled = true;
		this.TXTPhylumCommonNames = document.createElement('input');
        this.TXTPhylumCommonNames.setAttribute('id', 'form_classifier_phylum_commonpluralname');
        this.TXTPhylumCommonNames.setAttribute('type', 'text');
        this.TXTPhylumCommonNames.setAttribute('tabindex', 1);
        this.TXTPhylumCommonNames.focused = false;
        this.TXTPhylumCommonNames.className = 'form_raw_input';
        this.TXTPhylumCommonNames.style.width = '170px';
        this.TXTPhylumCommonNames.value = 'Chordates';
        this.TXTPhylumCommonNames.disabled = true;
        
		this.SELSubPhylum = document.createElement('select');
        this.SELSubPhylum.setAttribute('id', 'form_classifier_subphylum_select');
        this.SELSubPhylum.setAttribute('type', 'text');
        this.SELSubPhylum.setAttribute('tabindex', 1);
        this.SELSubPhylum.focused = false;
        this.SELSubPhylum.className = 'form_raw_input';
        this.SELSubPhylum.style.width = '170px';
        this.OPTSubPhylum = document.createElement('option');
        this.OPTSubPhylum.text = 'Vertebrate (Vertebrata)';
        this.OPTSubPhylum.value = '41';
        this.OPTSubPhylum.selected = true;
        this.SELSubPhylum.add(this.OPTSubPhylum, 0);
        this.SELSubPhylum.disabled = true;
		this.TXTSubPhylumSciName = document.createElement('input');
        this.TXTSubPhylumSciName.setAttribute('id', 'form_classifier_subphylum_scientificname');
        this.TXTSubPhylumSciName.setAttribute('type', 'text');
        this.TXTSubPhylumSciName.setAttribute('tabindex', 1);
        this.TXTSubPhylumSciName.focused = false;
        this.TXTSubPhylumSciName.className = 'form_raw_input';
        this.TXTSubPhylumSciName.style.width = '170px';
        this.TXTSubPhylumSciName.value = 'Vertebrata';
        this.TXTSubPhylumSciName.disabled = true;
		this.TXTSubPhylumCommonName = document.createElement('input');
        this.TXTSubPhylumCommonName.setAttribute('id', 'form_classifier_subphylum_commonname');
        this.TXTSubPhylumCommonName.setAttribute('type', 'text');
        this.TXTSubPhylumCommonName.setAttribute('tabindex', 1);
        this.TXTSubPhylumCommonName.focused = false;
        this.TXTSubPhylumCommonName.className = 'form_raw_input';
        this.TXTSubPhylumCommonName.style.width = '170px';
        this.TXTSubPhylumCommonName.value = 'Vertebrate';
        this.TXTSubPhylumCommonName.disabled = true;
		this.TXTSubPhylumCommonNames = document.createElement('input');
        this.TXTSubPhylumCommonNames.setAttribute('id', 'form_classifier_subphylum_commonpluralname');
        this.TXTSubPhylumCommonNames.setAttribute('type', 'text');
        this.TXTSubPhylumCommonNames.setAttribute('tabindex', 1);
        this.TXTSubPhylumCommonNames.focused = false;
        this.TXTSubPhylumCommonNames.className = 'form_raw_input';
        this.TXTSubPhylumCommonNames.style.width = '170px';
        this.TXTSubPhylumCommonNames.value = 'Vertebrates';
        this.TXTSubPhylumCommonNames.disabled = true;
        
		this.SELClass = document.createElement('select');
        this.SELClass.setAttribute('id', 'form_classifier_class_select');
        this.SELClass.setAttribute('type', 'text');
        this.SELClass.setAttribute('tabindex', 1);
        this.SELClass.focused = false;
        this.SELClass.className = 'form_raw_input';
        this.SELClass.style.width = '170px';
        this.OPTClass = document.createElement('option');
        this.OPTClass.text = 'Reptile (Reptilia)';
        this.OPTClass.value = '1';
        this.OPTClass.selected = true;
        this.SELClass.add(this.OPTClass, 0);
        this.OPTClass = document.createElement('option');
        this.OPTClass.text = 'Amphibian (Amphibia)';
        this.OPTClass.value = '2';
        this.SELClass.add(this.OPTClass, 0);
		this.TXTClassSciName = document.createElement('input');
        this.TXTClassSciName.setAttribute('id', 'form_classifier_class_scientificname');
        this.TXTClassSciName.setAttribute('type', 'text');
        this.TXTClassSciName.setAttribute('tabindex', 1);
        this.TXTClassSciName.focused = false;
        this.TXTClassSciName.className = 'form_raw_input';
        this.TXTClassSciName.style.width = '170px';
        this.TXTClassSciName.value = 'Reptilia';
        this.TXTClassSciName.disabled = true;
		this.TXTClassCommonName = document.createElement('input');
        this.TXTClassCommonName.setAttribute('id', 'form_classifier_class_commonname');
        this.TXTClassCommonName.setAttribute('type', 'text');
        this.TXTClassCommonName.setAttribute('tabindex', 1);
        this.TXTClassCommonName.focused = false;
        this.TXTClassCommonName.className = 'form_raw_input';
        this.TXTClassCommonName.style.width = '170px';
        this.TXTClassCommonName.value = 'Reptile';
        this.TXTClassCommonName.disabled = true;
		this.TXTClassCommonNames = document.createElement('input');
        this.TXTClassCommonNames.setAttribute('id', 'form_classifier_class_commonpluralname');
        this.TXTClassCommonNames.setAttribute('type', 'text');
        this.TXTClassCommonNames.setAttribute('tabindex', 1);
        this.TXTClassCommonNames.focused = false;
        this.TXTClassCommonNames.className = 'form_raw_input';
        this.TXTClassCommonNames.style.width = '170px';
        this.TXTClassCommonNames.value = 'Reptiles';
        this.TXTClassCommonNames.disabled = true;
        
		this.SELOrder = document.createElement('select');
        this.SELOrder.setAttribute('id', 'form_classifier_order_select');
        this.SELOrder.setAttribute('type', 'text');
        this.SELOrder.setAttribute('tabindex', 1);
        this.SELOrder.focused = false;
        this.SELOrder.className = 'form_raw_input';
        this.SELOrder.style.width = '170px';
        this.SELOrder.value = '';
		this.TXTOrderSciName = document.createElement('input');
        this.TXTOrderSciName.setAttribute('id', 'form_classifier_order_scientificname');
        this.TXTOrderSciName.setAttribute('type', 'text');
        this.TXTOrderSciName.setAttribute('tabindex', 1);
        this.TXTOrderSciName.focused = false;
        this.TXTOrderSciName.className = 'form_raw_input';
        this.TXTOrderSciName.style.width = '170px';
        this.TXTOrderSciName.value = '';
        this.TXTOrderSciName.disabled = true;
		this.TXTOrderCommonName = document.createElement('input');
        this.TXTOrderCommonName.setAttribute('id', 'form_classifier_order_commonname');
        this.TXTOrderCommonName.setAttribute('type', 'text');
        this.TXTOrderCommonName.setAttribute('tabindex', 1);
        this.TXTOrderCommonName.focused = false;
        this.TXTOrderCommonName.className = 'form_raw_input';
        this.TXTOrderCommonName.style.width = '170px';
        this.TXTOrderCommonName.value = '';
        this.TXTOrderCommonName.disabled = true;
		this.TXTOrderCommonNames = document.createElement('input');
        this.TXTOrderCommonNames.setAttribute('id', 'form_classifier_order_commonpluralname');
        this.TXTOrderCommonNames.setAttribute('type', 'text');
        this.TXTOrderCommonNames.setAttribute('tabindex', 1);
        this.TXTOrderCommonNames.focused = false;
        this.TXTOrderCommonNames.className = 'form_raw_input';
        this.TXTOrderCommonNames.style.width = '170px';
        this.TXTOrderCommonNames.value = '';
        this.TXTOrderCommonNames.disabled = true;
        
		this.SELFamily = document.createElement('select');
        this.SELFamily.setAttribute('id', 'form_classifier_family_select');
        this.SELFamily.setAttribute('type', 'text');
        this.SELFamily.setAttribute('tabindex', 1);
        this.SELFamily.focused = false;
        this.SELFamily.className = 'form_raw_input';
        this.SELFamily.style.width = '170px';
        this.SELFamily.value = '';
		this.TXTFamilySciName = document.createElement('input');
        this.TXTFamilySciName.setAttribute('id', 'form_classifier_family_scientificname');
        this.TXTFamilySciName.setAttribute('type', 'text');
        this.TXTFamilySciName.setAttribute('tabindex', 1);
        this.TXTFamilySciName.focused = false;
        this.TXTFamilySciName.className = 'form_raw_input';
        this.TXTFamilySciName.style.width = '170px';
        this.TXTFamilySciName.value = '';
		this.TXTFamilyCommonName = document.createElement('input');
        this.TXTFamilyCommonName.setAttribute('id', 'form_classifier_family_commonname');
        this.TXTFamilyCommonName.setAttribute('type', 'text');
        this.TXTFamilyCommonName.setAttribute('tabindex', 1);
        this.TXTFamilyCommonName.focused = false;
        this.TXTFamilyCommonName.className = 'form_raw_input';
        this.TXTFamilyCommonName.style.width = '170px';
        this.TXTFamilyCommonName.value = '';
		this.TXTFamilyCommonNames = document.createElement('input');
        this.TXTFamilyCommonNames.setAttribute('id', 'form_classifier_family_commonpluralname');
        this.TXTFamilyCommonNames.setAttribute('type', 'text');
        this.TXTFamilyCommonNames.setAttribute('tabindex', 1);
        this.TXTFamilyCommonNames.focused = false;
        this.TXTFamilyCommonNames.className = 'form_raw_input';
        this.TXTFamilyCommonNames.style.width = '170px';
        this.TXTFamilyCommonNames.value = '';
        
		this.SELGenus = document.createElement('select');
        this.SELGenus.setAttribute('id', 'form_classifier_genus_select');
        this.SELGenus.setAttribute('type', 'text');
        this.SELGenus.setAttribute('tabindex', 1);
        this.SELGenus.focused = false;
        this.SELGenus.className = 'form_raw_input';
        this.SELGenus.style.width = '170px';
        this.SELGenus.value = '';
		this.TXTGenusSciName = document.createElement('input');
        this.TXTGenusSciName.setAttribute('id', 'form_classifier_genus_scientificname');
        this.TXTGenusSciName.setAttribute('type', 'text');
        this.TXTGenusSciName.setAttribute('tabindex', 1);
        this.TXTGenusSciName.focused = false;
        this.TXTGenusSciName.className = 'form_raw_input';
        this.TXTGenusSciName.style.width = '170px';
        this.TXTGenusSciName.value = '';
		this.TXTGenusCommonName = document.createElement('input');
        this.TXTGenusCommonName.setAttribute('id', 'form_classifier_genus_commonname');
        this.TXTGenusCommonName.setAttribute('type', 'text');
        this.TXTGenusCommonName.setAttribute('tabindex', 1);
        this.TXTGenusCommonName.focused = false;
        this.TXTGenusCommonName.className = 'form_raw_input';
        this.TXTGenusCommonName.style.width = '170px';
        this.TXTGenusCommonName.value = '';
		this.TXTGenusCommonNames = document.createElement('input');
        this.TXTGenusCommonNames.setAttribute('id', 'form_classifier_genus_commonpluralname');
        this.TXTGenusCommonNames.setAttribute('type', 'text');
        this.TXTGenusCommonNames.setAttribute('tabindex', 1);
        this.TXTGenusCommonNames.focused = false;
        this.TXTGenusCommonNames.className = 'form_raw_input';
        this.TXTGenusCommonNames.style.width = '170px';
        this.TXTGenusCommonNames.value = '';
        
		this.SELSpecies = document.createElement('select');
        this.SELSpecies.setAttribute('id', 'form_classifier_species_select');
        this.SELSpecies.setAttribute('type', 'text');
        this.SELSpecies.setAttribute('tabindex', 1);
        this.SELSpecies.focused = false;
        this.SELSpecies.className = 'form_raw_input';
        this.SELSpecies.style.width = '170px';
        this.SELSpecies.value = '';
		this.TXTSpeciesSciName = document.createElement('input');
        this.TXTSpeciesSciName.setAttribute('id', 'form_classifier_species_scientificname');
        this.TXTSpeciesSciName.setAttribute('type', 'text');
        this.TXTSpeciesSciName.setAttribute('tabindex', 1);
        this.TXTSpeciesSciName.focused = false;
        this.TXTSpeciesSciName.className = 'form_raw_input';
        this.TXTSpeciesSciName.style.width = '170px';
        this.TXTSpeciesSciName.value = '';
		this.TXTSpeciesCommonName = document.createElement('input');
        this.TXTSpeciesCommonName.setAttribute('id', 'form_classifier_species_commonname');
        this.TXTSpeciesCommonName.setAttribute('type', 'text');
        this.TXTSpeciesCommonName.setAttribute('tabindex', 1);
        this.TXTSpeciesCommonName.focused = false;
        this.TXTSpeciesCommonName.className = 'form_raw_input';
        this.TXTSpeciesCommonName.style.width = '170px';
        this.TXTSpeciesCommonName.value = '';
		this.TXTSpeciesCommonNames = document.createElement('input');
        this.TXTSpeciesCommonNames.setAttribute('id', 'form_classifier_species_commonpluralname');
        this.TXTSpeciesCommonNames.setAttribute('type', 'text');
        this.TXTSpeciesCommonNames.setAttribute('tabindex', 1);
        this.TXTSpeciesCommonNames.focused = false;
        this.TXTSpeciesCommonNames.className = 'form_raw_input';
        this.TXTSpeciesCommonNames.style.width = '170px';
        this.TXTSpeciesCommonNames.value = '';
        
        document.getElementById('td_classifier_domain_select').appendChild(this.SELDomain);
        document.getElementById('td_classifier_domain_scientificname').appendChild(this.TXTDomainSciName);
        document.getElementById('td_classifier_domain_commonname').appendChild(this.TXTDomainCommonName);
        document.getElementById('td_classifier_domain_commonpluralname').appendChild(this.TXTDomainCommonNames);
        document.getElementById('td_classifier_kingdom_select').appendChild(this.SELKingdom);
        document.getElementById('td_classifier_kingdom_scientificname').appendChild(this.TXTKingdomSciName);
        document.getElementById('td_classifier_kingdom_commonname').appendChild(this.TXTKingdomCommonName);
        document.getElementById('td_classifier_kingdom_commonpluralname').appendChild(this.TXTKingdomCommonNames);
        document.getElementById('td_classifier_phylum_select').appendChild(this.SELPhylum);
        document.getElementById('td_classifier_phylum_scientificname').appendChild(this.TXTPhylumSciName);
        document.getElementById('td_classifier_phylum_commonname').appendChild(this.TXTPhylumCommonName);
        document.getElementById('td_classifier_phylum_commonpluralname').appendChild(this.TXTPhylumCommonNames);
        document.getElementById('td_classifier_subphylum_select').appendChild(this.SELSubPhylum);
        document.getElementById('td_classifier_subphylum_scientificname').appendChild(this.TXTSubPhylumSciName);
        document.getElementById('td_classifier_subphylum_commonname').appendChild(this.TXTSubPhylumCommonName);
        document.getElementById('td_classifier_subphylum_commonpluralname').appendChild(this.TXTSubPhylumCommonNames);
        document.getElementById('td_classifier_class_select').appendChild(this.SELClass);
        document.getElementById('td_classifier_class_scientificname').appendChild(this.TXTClassSciName);
        document.getElementById('td_classifier_class_commonname').appendChild(this.TXTClassCommonName);
        document.getElementById('td_classifier_class_commonpluralname').appendChild(this.TXTClassCommonNames);
        document.getElementById('td_classifier_order_select').appendChild(this.SELOrder);
        document.getElementById('td_classifier_order_scientificname').appendChild(this.TXTOrderSciName);
        document.getElementById('td_classifier_order_commonname').appendChild(this.TXTOrderCommonName);
        document.getElementById('td_classifier_order_commonpluralname').appendChild(this.TXTOrderCommonNames);
        document.getElementById('td_classifier_family_select').appendChild(this.SELFamily);
        document.getElementById('td_classifier_family_scientificname').appendChild(this.TXTFamilySciName);
        document.getElementById('td_classifier_family_commonname').appendChild(this.TXTFamilyCommonName);
        document.getElementById('td_classifier_family_commonpluralname').appendChild(this.TXTFamilyCommonNames);
        document.getElementById('td_classifier_genus_select').appendChild(this.SELGenus);
        document.getElementById('td_classifier_genus_scientificname').appendChild(this.TXTGenusSciName);
        document.getElementById('td_classifier_genus_commonname').appendChild(this.TXTGenusCommonName);
        document.getElementById('td_classifier_genus_commonpluralname').appendChild(this.TXTGenusCommonNames);
        document.getElementById('td_classifier_species_select').appendChild(this.SELSpecies);
        document.getElementById('td_classifier_species_scientificname').appendChild(this.TXTSpeciesSciName);
        document.getElementById('td_classifier_species_commonname').appendChild(this.TXTSpeciesCommonName);
        document.getElementById('td_classifier_species_commonpluralname').appendChild(this.TXTSpeciesCommonNames);
        document.getElementById('form_classifier_domain_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_kingdom_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_phylum_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_class_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_order_tag').innerHTML = '&nbsp;';
        document.getElementById('form_classifier_family_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_classifier_genus_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_classifier_species_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        
        var obj = this.SELClass;
        obj.focused = false;
        obj.className='form_raw_input';
        if(obj.value != obj.lastValue) {
            var a = obj.id.split('_');
            Browser.FValidate(a[0]+'_'+a[1]+'_'+a[2]+'_tag', obj.id, obj.value, ((a.length > 3) ? a[2]+'_'+a[3] : a[2]), '&nbsp;');
            if(a.length > 3) { if(a[3].toLowerCase() == 'select') { obj.lastValue = obj.value; } }
        }
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemClassifier').style.display = 'block';
        document.getElementById('spnSystemClassifier').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
        
        eventPush(this.SELDomain, 'focus', Browser.RawInputFocus);
        eventPush(this.SELDomain, 'change', Browser.RawInputBlur);
        eventPush(this.SELDomain, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELDomain, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELDomain, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTDomainSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTDomainSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTDomainSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTDomainSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTDomainSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTDomainCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTDomainCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTDomainCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTDomainCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTDomainCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTDomainCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTDomainCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTDomainCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTDomainCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTDomainCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELKingdom, 'focus', Browser.RawInputFocus);
        eventPush(this.SELKingdom, 'change', Browser.RawInputBlur);
        eventPush(this.SELKingdom, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELKingdom, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELKingdom, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTKingdomSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTKingdomSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTKingdomSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTKingdomSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTKingdomSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTKingdomCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTKingdomCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTKingdomCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTKingdomCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTKingdomCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTKingdomCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTKingdomCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTKingdomCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTKingdomCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTKingdomCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELPhylum, 'focus', Browser.RawInputFocus);
        eventPush(this.SELPhylum, 'change', Browser.RawInputBlur);
        eventPush(this.SELPhylum, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELPhylum, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELPhylum, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTPhylumSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPhylumSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTPhylumSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPhylumSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPhylumSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTPhylumCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPhylumCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTPhylumCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPhylumCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPhylumCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTPhylumCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPhylumCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTPhylumCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPhylumCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPhylumCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELSubPhylum, 'focus', Browser.RawInputFocus);
        eventPush(this.SELSubPhylum, 'change', Browser.RawInputBlur);
        eventPush(this.SELSubPhylum, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELSubPhylum, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELSubPhylum, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTSubPhylumSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTSubPhylumSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTSubPhylumSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTSubPhylumSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTSubPhylumSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTSubPhylumCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTSubPhylumCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTSubPhylumCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTSubPhylumCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTSubPhylumCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTSubPhylumCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTSubPhylumCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTSubPhylumCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTSubPhylumCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTSubPhylumCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELClass, 'focus', Browser.RawInputFocus);
        eventPush(this.SELClass, 'change', Browser.RawInputBlur);
        eventPush(this.SELClass, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELClass, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELClass, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTClassSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTClassSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTClassSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTClassSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTClassSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTClassCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTClassCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTClassCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTClassCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTClassCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTClassCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTClassCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTClassCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTClassCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTClassCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELOrder, 'focus', Browser.RawInputFocus);
        eventPush(this.SELOrder, 'change', Browser.RawInputBlur);
        eventPush(this.SELOrder, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELOrder, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELOrder, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTOrderSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTOrderSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTOrderSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTOrderSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTOrderSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTOrderCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTOrderCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTOrderCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTOrderCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTOrderCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTOrderCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTOrderCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTOrderCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTOrderCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTOrderCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELFamily, 'focus', Browser.RawInputFocus);
        eventPush(this.SELFamily, 'change', Browser.RawInputBlur);
        eventPush(this.SELFamily, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELFamily, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELFamily, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTFamilySciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTFamilySciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTFamilySciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTFamilySciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTFamilySciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTFamilyCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTFamilyCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTFamilyCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTFamilyCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTFamilyCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTFamilyCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTFamilyCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTFamilyCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTFamilyCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTFamilyCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELGenus, 'focus', Browser.RawInputFocus);
        eventPush(this.SELGenus, 'change', Browser.RawInputBlur);
        eventPush(this.SELGenus, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELGenus, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELGenus, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTGenusSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTGenusSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTGenusSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTGenusSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTGenusSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTGenusCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTGenusCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTGenusCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTGenusCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTGenusCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTGenusCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTGenusCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTGenusCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTGenusCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTGenusCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.SELSpecies, 'focus', Browser.RawInputFocus);
        eventPush(this.SELSpecies, 'change', Browser.RawInputBlur);
        eventPush(this.SELSpecies, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.SELSpecies, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.SELSpecies, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTSpeciesSciName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTSpeciesSciName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTSpeciesSciName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTSpeciesSciName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTSpeciesSciName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTSpeciesCommonName, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTSpeciesCommonName, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTSpeciesCommonName, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTSpeciesCommonName, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTSpeciesCommonName, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTSpeciesCommonNames, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTSpeciesCommonNames, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTSpeciesCommonNames, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTSpeciesCommonNames, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTSpeciesCommonNames, 'mouseout', Browser.RawInputMouseOut);
        
        //o = document.getElementById('form_login_username');
        //if(o) {
            this.SELDomain.focus();
            this.FocusObj = this.SELDomain;
        //} else {
        //    this.FocusObj = null;
        //}
    }
    this.SysClassifier = true;
}
function cBrowser_ShowLogin() {
    var o = document.getElementById('divSystem');
    if(o) {
		this.TXTUsername = document.createElement('input');
        this.TXTUsername.setAttribute('id', 'form_login_username');
        this.TXTUsername.setAttribute('type', 'text');
        this.TXTUsername.setAttribute('tabindex', 1);
        this.TXTUsername.focused = false;
        this.TXTUsername.className = 'form_raw_input';
        this.TXTUsername.style.width = '170px';
        this.TXTUsername.value = '';
        this.TXTPassword = document.createElement('input');
        this.TXTPassword.setAttribute('id', 'form_login_password');
        this.TXTPassword.setAttribute('type', 'password');
        this.TXTPassword.setAttribute('tabindex', 2);
        this.TXTPassword.focused = false;
        this.TXTPassword.className = 'form_raw_input';
        this.TXTPassword.style.width = '170px';
        this.TXTPassword.value = '';
        document.getElementById('td_login_username').appendChild(this.TXTUsername);
        document.getElementById('td_login_password').appendChild(this.TXTPassword);
        
        document.getElementById('form_login_username_tag').innerHTML = '&nbsp;';
        document.getElementById('form_login_password_tag').innerHTML = '&nbsp;';
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemLogin').style.display = 'block';
        document.getElementById('spnSystemLogin').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
        
        eventPush(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPush(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        eventPush(this.TXTPassword, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
        eventPush(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);
        
        //o = document.getElementById('form_login_username');
        //if(o) {
            this.TXTUsername.focus();
            this.FocusObj = this.TXTUsername;
        //} else {
        //    this.FocusObj = null;
        //}
    }
    this.SysLogin = true;
}
function cBrowser_ShowLostPassword() {
    var o = document.getElementById('divSystem');
    if(o) {
		this.TXTUsername = document.createElement('input');
        this.TXTUsername.setAttribute('id', 'form_lostpassword_username');
        this.TXTUsername.setAttribute('type', 'text');
        this.TXTUsername.setAttribute('tabindex', 1);
        this.TXTUsername.focused = false;
        this.TXTUsername.className = 'form_raw_input';
        this.TXTUsername.style.width = '270px';
        this.TXTUsername.value = '';
        
		this.TXTEmail = document.createElement('input');
        this.TXTEmail.setAttribute('id', 'form_lostpassword_email');
        this.TXTEmail.setAttribute('type', 'text');
        this.TXTEmail.setAttribute('tabindex', 2);
        this.TXTEmail.focused = false;
        this.TXTEmail.className = 'form_raw_input';
        this.TXTEmail.style.width = '270px';
        this.TXTEmail.value = '';
        
		this.TXTCAPTCHA = document.createElement('input');
        this.TXTCAPTCHA.setAttribute('id', 'form_lostpassword_captcha');
        this.TXTCAPTCHA.setAttribute('type', 'text');
        this.TXTCAPTCHA.setAttribute('tabindex', 3);
        this.TXTCAPTCHA.focused = false;
        this.TXTCAPTCHA.className = 'form_raw_input';
        this.TXTCAPTCHA.style.width = '270px';
        this.TXTCAPTCHA.value = '';
        
		this.CAPTCHAReloadIcon = document.createElement('img');
        this.CAPTCHAReloadIcon.setAttribute('id', 'form_lostpassword_captcha_icon_reload');
        this.CAPTCHAReloadIcon.className = 'InlineIcon16';
        this.CAPTCHAReloadIcon.src = 'img/icons/16/refresh.png';
        this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
        this.CAPTCHAReloadIcon.style.margin = '0px 4px 0px 2px';
        this.CAPTCHAReloadIcon.style.cursor = 'pointer';
        this.CAPTCHAReloadIcon.style.visibility = 'visible';
        this.CAPTCHAReloadIcon.alt = 'Get New CAPTCHA';
        this.CAPTCHAReloadIcon.title = 'Get New CAPTCHA';
        
		this.CAPTCHAImage = document.createElement('img');
        this.CAPTCHAImage.setAttribute('id', 'form_lostpassword_captcha_image');
        this.CAPTCHAImage.setAttribute('name', 'form_lostpassword_captcha_image');
        this.CAPTCHAImage.className = 'form_raw_captcha';
        this.CAPTCHAImage.alt = 'Loading CAPTCHA...';
        this.CAPTCHAImage.src = '';
        
        document.getElementById('td_lostpassword_username').appendChild(this.TXTUsername);
        document.getElementById('td_lostpassword_email').appendChild(this.TXTEmail);
        document.getElementById('td_lostpassword_captcha').appendChild(this.TXTCAPTCHA);
        document.getElementById('td_lostpassword_captcha_icon_reload').appendChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_lostpassword_captcha_image').appendChild(this.CAPTCHAImage);
        
        document.getElementById('form_lostpassword_username_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_lostpassword_email_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_lostpassword_captcha_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemLostPassword').style.display = 'block';
        document.getElementById('spnSystemLostPassword').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
        
        eventPush(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPush(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTEmail, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTEmail, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTEmail, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTCAPTCHA, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.CAPTCHAReloadIcon, 'click', Browser.RawButtonClick);
        eventPush(this.CAPTCHAReloadIcon, 'mousedown', Browser.RawButtonMouseDown);
        eventPush(this.CAPTCHAReloadIcon, 'mouseover', Browser.RawButtonMouseOver);
        eventPush(this.CAPTCHAReloadIcon, 'mouseout', Browser.RawButtonMouseOut);
        eventPush(this.CAPTCHAReloadIcon, 'mouseup', Browser.RawButtonMouseUp);
        
        //o = document.getElementById('form_login_username');
        //if(o) {
            this.TXTUsername.focus();
            this.FocusObj = this.TXTUsername;
        //} else {
        //    this.FocusObj = null;
        //}
        this.FSetCaptcha(290);
    }
    this.SysLostPassword = true;
}
function cBrowser_ShowLostUsername() {
    var o = document.getElementById('divSystem');
    if(o) {
		this.TXTEmail = document.createElement('input');
        this.TXTEmail.setAttribute('id', 'form_lostusername_email');
        this.TXTEmail.setAttribute('type', 'text');
        this.TXTEmail.setAttribute('tabindex', 1);
        this.TXTEmail.focused = false;
        this.TXTEmail.className = 'form_raw_input';
        this.TXTEmail.style.width = '270px';
        this.TXTEmail.value = '';
        
		this.TXTCAPTCHA = document.createElement('input');
        this.TXTCAPTCHA.setAttribute('id', 'form_lostusername_captcha');
        this.TXTCAPTCHA.setAttribute('type', 'text');
        this.TXTCAPTCHA.setAttribute('tabindex', 2);
        this.TXTCAPTCHA.focused = false;
        this.TXTCAPTCHA.className = 'form_raw_input';
        this.TXTCAPTCHA.style.width = '270px';
        this.TXTCAPTCHA.value = '';
        
		this.CAPTCHAReloadIcon = document.createElement('img');
        this.CAPTCHAReloadIcon.setAttribute('id', 'form_lostusername_captcha_icon_reload');
        this.CAPTCHAReloadIcon.className = 'InlineIcon16';
        this.CAPTCHAReloadIcon.src = 'img/icons/16/refresh.png';
        this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
        this.CAPTCHAReloadIcon.style.margin = '0px 4px 0px 2px';
        this.CAPTCHAReloadIcon.style.cursor = 'pointer';
        this.CAPTCHAReloadIcon.style.visibility = 'visible';
        this.CAPTCHAReloadIcon.alt = 'Get New CAPTCHA';
        this.CAPTCHAReloadIcon.title = 'Get New CAPTCHA';
        
		this.CAPTCHAImage = document.createElement('img');
        this.CAPTCHAImage.setAttribute('id', 'form_lostusername_captcha_image');
        this.CAPTCHAImage.setAttribute('name', 'form_lostusername_captcha_image');
        this.CAPTCHAImage.className = 'form_raw_captcha';
        this.CAPTCHAImage.alt = 'Loading CAPTCHA...';
        this.CAPTCHAImage.src = '';
        
        document.getElementById('td_lostusername_email').appendChild(this.TXTEmail);
        document.getElementById('td_lostusername_captcha').appendChild(this.TXTCAPTCHA);
        document.getElementById('td_lostusername_captcha_icon_reload').appendChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_lostusername_captcha_image').appendChild(this.CAPTCHAImage);
        
        document.getElementById('form_lostusername_email_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_lostusername_captcha_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemLostUsername').style.display = 'block';
        document.getElementById('spnSystemLostUsername').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
        
        eventPush(this.TXTEmail, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTEmail, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTEmail, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTCAPTCHA, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.CAPTCHAReloadIcon, 'click', Browser.RawButtonClick);
        eventPush(this.CAPTCHAReloadIcon, 'mousedown', Browser.RawButtonMouseDown);
        eventPush(this.CAPTCHAReloadIcon, 'mouseover', Browser.RawButtonMouseOver);
        eventPush(this.CAPTCHAReloadIcon, 'mouseout', Browser.RawButtonMouseOut);
        eventPush(this.CAPTCHAReloadIcon, 'mouseup', Browser.RawButtonMouseUp);
        
        //o = document.getElementById('form_login_username');
        //if(o) {
            this.TXTEmail.focus();
            this.FocusObj = this.TXTEmail;
        //} else {
        //    this.FocusObj = null;
        //}
        this.FSetCaptcha(290);
    }
    this.SysLostUsername = true;
}
function cBrowser_ShowPasswordReset(sCode) {
    var o = document.getElementById('divSystem');
    if(o) {
		this.TXTCode = document.createElement('input');
        this.TXTCode.setAttribute('id', 'form_passwordreset_code');
        this.TXTCode.setAttribute('type', 'hidden');
        this.TXTCode.value = sCode;
        
		this.TXTUsername = document.createElement('input');
        this.TXTUsername.setAttribute('id', 'form_passwordreset_username');
        this.TXTUsername.setAttribute('type', 'text');
        this.TXTUsername.setAttribute('tabindex', 6);
        this.TXTUsername.focused = false;
        this.TXTUsername.className = 'form_raw_input';
        this.TXTUsername.style.width = '270px';
        this.TXTUsername.value = '';
        
        this.TXTPassword = document.createElement('input');
        this.TXTPassword.setAttribute('id', 'form_passwordreset_password');
        this.TXTPassword.setAttribute('type', 'password');
        this.TXTPassword.setAttribute('tabindex', 7);
        this.TXTPassword.focused = false;
        this.TXTPassword.className = 'form_raw_input';
        this.TXTPassword.style.width = '270px';
        this.TXTPassword.value = '';
        
        this.TXTPasswordConfirm = document.createElement('input');
        this.TXTPasswordConfirm.setAttribute('id', 'form_passwordreset_passwordconfirm');
        this.TXTPasswordConfirm.setAttribute('type', 'password');
        this.TXTPasswordConfirm.setAttribute('tabindex', 8);
        this.TXTPasswordConfirm.focused = false;
        this.TXTPasswordConfirm.className = 'form_raw_input';
        this.TXTPasswordConfirm.style.width = '270px';
        this.TXTPasswordConfirm.value = '';
        
		this.TXTCAPTCHA = document.createElement('input');
        this.TXTCAPTCHA.setAttribute('id', 'form_passwordreset_captcha');
        this.TXTCAPTCHA.setAttribute('type', 'text');
        this.TXTCAPTCHA.setAttribute('tabindex', 9);
        this.TXTCAPTCHA.focused = false;
        this.TXTCAPTCHA.className = 'form_raw_input';
        this.TXTCAPTCHA.style.width = '270px';
        this.TXTCAPTCHA.value = '';
        
		this.CAPTCHAReloadIcon = document.createElement('img');
        this.CAPTCHAReloadIcon.setAttribute('id', 'form_passwordreset_captcha_icon_reload');
        this.CAPTCHAReloadIcon.className = 'InlineIcon16';
        this.CAPTCHAReloadIcon.src = 'img/icons/16/refresh.png';
        this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
        this.CAPTCHAReloadIcon.style.margin = '0px 4px 0px 2px';
        this.CAPTCHAReloadIcon.style.cursor = 'pointer';
        this.CAPTCHAReloadIcon.style.visibility = 'visible';
        this.CAPTCHAReloadIcon.alt = 'Get New CAPTCHA';
        this.CAPTCHAReloadIcon.title = 'Get New CAPTCHA';
        
		this.CAPTCHAImage = document.createElement('img');
        this.CAPTCHAImage.setAttribute('id', 'form_passwordreset_captcha_image');
        this.CAPTCHAImage.setAttribute('name', 'form_passwordreset_captcha_image');
        this.CAPTCHAImage.className = 'form_raw_captcha';
        this.CAPTCHAImage.alt = 'Loading CAPTCHA...';
        this.CAPTCHAImage.src = '';
        
        document.getElementById('td_passwordreset_username').appendChild(this.TXTCode);
        document.getElementById('td_passwordreset_username').appendChild(this.TXTUsername);
        document.getElementById('td_passwordreset_password').appendChild(this.TXTPassword);
        document.getElementById('td_passwordreset_passwordconfirm').appendChild(this.TXTPasswordConfirm);
        document.getElementById('td_passwordreset_captcha').appendChild(this.TXTCAPTCHA);
        document.getElementById('td_passwordreset_captcha_icon_reload').appendChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_passwordreset_captcha_image').appendChild(this.CAPTCHAImage);
        
        document.getElementById('form_passwordreset_username_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_passwordreset_password_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        document.getElementById('form_passwordreset_passwordconfirm_tag').innerHTML = '&nbsp;';
        document.getElementById('form_passwordreset_captcha_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemPasswordReset').style.display = 'block';
        document.getElementById('spnSystemPasswordReset').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
        
        eventPush(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPush(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTPassword, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTPassword, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
        eventPush(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTPasswordConfirm, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTPasswordConfirm, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPasswordConfirm, 'blur', Browser.RawInputPasswordBlur);
        eventPush(this.TXTPasswordConfirm, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPasswordConfirm, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPasswordConfirm, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTCAPTCHA, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.CAPTCHAReloadIcon, 'click', Browser.RawButtonClick);
        eventPush(this.CAPTCHAReloadIcon, 'mousedown', Browser.RawButtonMouseDown);
        eventPush(this.CAPTCHAReloadIcon, 'mouseover', Browser.RawButtonMouseOver);
        eventPush(this.CAPTCHAReloadIcon, 'mouseout', Browser.RawButtonMouseOut);
        eventPush(this.CAPTCHAReloadIcon, 'mouseup', Browser.RawButtonMouseUp);
        
        //o = document.getElementById('form_login_username');
        //if(o) {
            this.TXTUsername.focus();
            this.FocusObj = this.TXTUsername;
        //} else {
        //    this.FocusObj = null;
        //}
        this.FSetCaptcha(290);
    }
    this.SysPasswordReset = true;
}
function cBrowser_ShowProfileEditor(nameFirst, nameMiddle, nameLast, email, website, nameTag, emailTag, confirmEmailTag, websiteTag, passwordTag, confirmPasswordTag, captchaTag) {
    this.HideAll();
    document.getElementById('divMain').style.display = 'block';
    document.getElementById('divMain').style.visibility = 'visible';
    this.TXTNameFirst = document.createElement('input');
    this.TXTNameFirst.setAttribute('id', 'form_profile_name_first');
    this.TXTNameFirst.setAttribute('type', 'text');
    this.TXTNameFirst.setAttribute('tabindex', 1);
    this.TXTNameFirst.focused = false;
    this.TXTNameFirst.className = 'form_raw_input';
    this.TXTNameFirst.style.width = '100px';
    this.TXTNameFirst.style.marginRight = '0px';
    this.TXTNameFirst.style.borderRight = '0px';
    this.TXTNameFirst.value = nameFirst;

    this.TXTNameMiddle = document.createElement('input');
    this.TXTNameMiddle.setAttribute('id', 'form_profile_name_middle');
    this.TXTNameMiddle.setAttribute('type', 'text');
    this.TXTNameMiddle.setAttribute('tabindex', 2);
    this.TXTNameMiddle.focused = false;
    this.TXTNameMiddle.className = 'form_raw_input';
    this.TXTNameMiddle.style.width = '30px';
    this.TXTNameMiddle.style.marginRight = '0px';
    this.TXTNameMiddle.style.marginLeft = '0px';
    this.TXTNameMiddle.value = nameMiddle;

    this.TXTNameLast = document.createElement('input');
    this.TXTNameLast.setAttribute('id', 'form_profile_name_last');
    this.TXTNameLast.setAttribute('type', 'text');
    this.TXTNameLast.setAttribute('tabindex', 3);
    this.TXTNameLast.focused = false;
    this.TXTNameLast.className = 'form_raw_input';
    this.TXTNameLast.style.width = '140px';
    this.TXTNameLast.style.marginLeft = '0px';
    this.TXTNameLast.style.borderLeft = '0px';
    this.TXTNameLast.value = nameLast;

    this.TXTEmail = document.createElement('input');
    this.TXTEmail.setAttribute('id', 'form_profile_email');
    this.TXTEmail.setAttribute('type', 'text');
    this.TXTEmail.setAttribute('tabindex', 4);
    this.TXTEmail.focused = false;
    this.TXTEmail.className = 'form_raw_input';
    this.TXTEmail.style.width = '270px';
    this.TXTEmail.value = email;

    this.TXTEmailConfirm = document.createElement('input');
    this.TXTEmailConfirm.setAttribute('id', 'form_profile_emailconfirm');
    this.TXTEmailConfirm.setAttribute('type', 'text');
    this.TXTEmailConfirm.setAttribute('tabindex', 5);
    this.TXTEmailConfirm.focused = false;
    this.TXTEmailConfirm.className = 'form_raw_input';
    this.TXTEmailConfirm.style.width = '270px';
    this.TXTEmailConfirm.value = email;

    this.TXTWebsite = document.createElement('input');
    this.TXTWebsite.setAttribute('id', 'form_profile_website');
    this.TXTWebsite.setAttribute('type', 'text');
    this.TXTWebsite.setAttribute('tabindex', 6);
    this.TXTWebsite.focused = false;
    this.TXTWebsite.className = 'form_raw_input';
    this.TXTWebsite.style.width = '270px';
    this.TXTWebsite.value = website;

    this.TXTPassword = document.createElement('input');
    this.TXTPassword.setAttribute('id', 'form_profile_password');
    this.TXTPassword.setAttribute('type', 'password');
    this.TXTPassword.setAttribute('tabindex', 7);
    this.TXTPassword.focused = false;
    this.TXTPassword.className = 'form_raw_input';
    this.TXTPassword.style.width = '270px';
    this.TXTPassword.value = '';

    this.TXTPasswordConfirm = document.createElement('input');
    this.TXTPasswordConfirm.setAttribute('id', 'form_profile_passwordconfirm');
    this.TXTPasswordConfirm.setAttribute('type', 'password');
    this.TXTPasswordConfirm.setAttribute('tabindex', 8);
    this.TXTPasswordConfirm.focused = false;
    this.TXTPasswordConfirm.className = 'form_raw_input';
    this.TXTPasswordConfirm.style.width = '270px';
    this.TXTPasswordConfirm.value = '';

    this.TXTCAPTCHA = document.createElement('input');
    this.TXTCAPTCHA.setAttribute('id', 'form_profile_captcha');
    this.TXTCAPTCHA.setAttribute('type', 'text');
    this.TXTCAPTCHA.setAttribute('tabindex', 9);
    this.TXTCAPTCHA.focused = false;
    this.TXTCAPTCHA.className = 'form_raw_input';
    this.TXTCAPTCHA.style.width = '270px';
    this.TXTCAPTCHA.value = '';

    this.CAPTCHAReloadIcon = document.createElement('img');
    this.CAPTCHAReloadIcon.setAttribute('id', 'form_profile_captcha_icon_reload');
    this.CAPTCHAReloadIcon.className = 'InlineIcon16';
    this.CAPTCHAReloadIcon.src = 'img/icons/16/refresh.png';
    this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
    this.CAPTCHAReloadIcon.style.margin = '0px 4px 0px 2px';
    this.CAPTCHAReloadIcon.style.cursor = 'pointer';
    this.CAPTCHAReloadIcon.style.visibility = 'visible';
    this.CAPTCHAReloadIcon.alt = 'Get New CAPTCHA';
    this.CAPTCHAReloadIcon.title = 'Get New CAPTCHA';

    this.CAPTCHAImage = document.createElement('img');
    this.CAPTCHAImage.setAttribute('id', 'form_profile_captcha_image');
    this.CAPTCHAImage.setAttribute('name', 'form_profile_captcha_image');
    this.CAPTCHAImage.className = 'form_raw_captcha';
    this.CAPTCHAImage.alt = 'Loading CAPTCHA...';
    this.CAPTCHAImage.src = '';

    document.getElementById('spn_profile_name_first').appendChild(this.TXTNameFirst);
    document.getElementById('spn_profile_name_middle').appendChild(this.TXTNameMiddle);
    document.getElementById('spn_profile_name_last').appendChild(this.TXTNameLast);
    document.getElementById('td_profile_email').appendChild(this.TXTEmail);
    document.getElementById('td_profile_emailconfirm').appendChild(this.TXTEmailConfirm);
    document.getElementById('td_profile_website').appendChild(this.TXTWebsite);
    document.getElementById('td_profile_password').appendChild(this.TXTPassword);
    document.getElementById('td_profile_passwordconfirm').appendChild(this.TXTPasswordConfirm);
    document.getElementById('td_profile_captcha').appendChild(this.TXTCAPTCHA);
    document.getElementById('td_profile_captcha_icon_reload').appendChild(this.CAPTCHAReloadIcon);
    document.getElementById('td_profile_captcha_image').appendChild(this.CAPTCHAImage);

    document.getElementById('form_profile_name_tag').innerHTML = nameTag;
    document.getElementById('form_profile_email_tag').innerHTML = emailTag;
    document.getElementById('form_profile_emailconfirm_tag').innerHTML = confirmEmailTag;
    document.getElementById('form_profile_website_tag').innerHTML = websiteTag;
    document.getElementById('form_profile_password_tag').innerHTML = passwordTag;
    document.getElementById('form_profile_passwordconfirm_tag').innerHTML = confirmPasswordTag;
    document.getElementById('form_profile_captcha_tag').innerHTML = captchaTag;

    eventPush(this.TXTNameFirst, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTNameFirst, 'blur', Browser.RawInputBlur);
    eventPush(this.TXTNameFirst, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTNameFirst, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTNameFirst, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTNameMiddle, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTNameMiddle, 'blur', Browser.RawInputBlur);
    eventPush(this.TXTNameMiddle, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTNameMiddle, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTNameMiddle, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTNameLast, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTNameLast, 'blur', Browser.RawInputBlur);
    eventPush(this.TXTNameLast, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTNameLast, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTNameLast, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTEmail, 'change', Browser.RawInputChangeConfirm);
    eventPush(this.TXTEmail, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTEmail, 'blur', Browser.RawInputBlur);
    eventPush(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTEmailConfirm, 'change', Browser.RawInputChangeConfirm);
    eventPush(this.TXTEmailConfirm, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTEmailConfirm, 'blur', Browser.RawInputBlur);
    eventPush(this.TXTEmailConfirm, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTEmailConfirm, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTEmailConfirm, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTWebsite, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTWebsite, 'blur', Browser.RawInputUsernameBlur);
    eventPush(this.TXTWebsite, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTWebsite, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTWebsite, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTPassword, 'change', Browser.RawInputChangeConfirm);
    eventPush(this.TXTPassword, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
    eventPush(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTPasswordConfirm, 'change', Browser.RawInputChangeConfirm);
    eventPush(this.TXTPasswordConfirm, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTPasswordConfirm, 'blur', Browser.RawInputPasswordBlur);
    eventPush(this.TXTPasswordConfirm, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTPasswordConfirm, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTPasswordConfirm, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
    eventPush(this.TXTCAPTCHA, 'blur', Browser.RawInputBlur);
    eventPush(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
    eventPush(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
    eventPush(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);

    eventPush(this.CAPTCHAReloadIcon, 'click', Browser.RawButtonClick);
    eventPush(this.CAPTCHAReloadIcon, 'mousedown', Browser.RawButtonMouseDown);
    eventPush(this.CAPTCHAReloadIcon, 'mouseover', Browser.RawButtonMouseOver);
    eventPush(this.CAPTCHAReloadIcon, 'mouseout', Browser.RawButtonMouseOut);
    eventPush(this.CAPTCHAReloadIcon, 'mouseup', Browser.RawButtonMouseUp);

    //o = document.getElementById('form_login_username');
    //if(o) {
        this.TXTNameFirst.focus();
        this.FocusObj = this.TXTNameFirst;
    //} else {
    //    this.FocusObj = null;
    //}
    this.FSetCaptcha(290);
}
function cBrowser_ShowRegistration() {
    var o = document.getElementById('divSystem');
    if(o) {
		this.TXTNameFirst = document.createElement('input');
        this.TXTNameFirst.setAttribute('id', 'form_registration_name_first');
        this.TXTNameFirst.setAttribute('type', 'text');
        this.TXTNameFirst.setAttribute('tabindex', 1);
        this.TXTNameFirst.focused = false;
        this.TXTNameFirst.className = 'form_raw_input';
        this.TXTNameFirst.style.width = '100px';
        this.TXTNameFirst.style.marginRight = '0px';
        this.TXTNameFirst.style.borderRight = '0px';
        this.TXTNameFirst.value = '';
        
		this.TXTNameMiddle = document.createElement('input');
        this.TXTNameMiddle.setAttribute('id', 'form_registration_name_middle');
        this.TXTNameMiddle.setAttribute('type', 'text');
        this.TXTNameMiddle.setAttribute('tabindex', 2);
        this.TXTNameMiddle.focused = false;
        this.TXTNameMiddle.className = 'form_raw_input';
        this.TXTNameMiddle.style.width = '30px';
        this.TXTNameMiddle.style.marginRight = '0px';
        this.TXTNameMiddle.style.marginLeft = '0px';
        this.TXTNameMiddle.value = '';
        
		this.TXTNameLast = document.createElement('input');
        this.TXTNameLast.setAttribute('id', 'form_registration_name_last');
        this.TXTNameLast.setAttribute('type', 'text');
        this.TXTNameLast.setAttribute('tabindex', 3);
        this.TXTNameLast.focused = false;
        this.TXTNameLast.className = 'form_raw_input';
        this.TXTNameLast.style.width = '140px';
        this.TXTNameLast.style.marginLeft = '0px';
        this.TXTNameLast.style.borderLeft = '0px';
        this.TXTNameLast.value = '';
        
		this.TXTEmail = document.createElement('input');
        this.TXTEmail.setAttribute('id', 'form_registration_email');
        this.TXTEmail.setAttribute('type', 'text');
        this.TXTEmail.setAttribute('tabindex', 4);
        this.TXTEmail.focused = false;
        this.TXTEmail.className = 'form_raw_input';
        this.TXTEmail.style.width = '270px';
        this.TXTEmail.value = '';
        
		this.TXTEmailConfirm = document.createElement('input');
        this.TXTEmailConfirm.setAttribute('id', 'form_registration_emailconfirm');
        this.TXTEmailConfirm.setAttribute('type', 'text');
        this.TXTEmailConfirm.setAttribute('tabindex', 5);
        this.TXTEmailConfirm.focused = false;
        this.TXTEmailConfirm.className = 'form_raw_input';
        this.TXTEmailConfirm.style.width = '270px';
        this.TXTEmailConfirm.value = '';
        
		this.TXTUsername = document.createElement('input');
        this.TXTUsername.setAttribute('id', 'form_registration_username');
        this.TXTUsername.setAttribute('type', 'text');
        this.TXTUsername.setAttribute('tabindex', 6);
        this.TXTUsername.focused = false;
        this.TXTUsername.className = 'form_raw_input';
        this.TXTUsername.style.width = '270px';
        this.TXTUsername.value = '';
        
        this.TXTPassword = document.createElement('input');
        this.TXTPassword.setAttribute('id', 'form_registration_password');
        this.TXTPassword.setAttribute('type', 'password');
        this.TXTPassword.setAttribute('tabindex', 7);
        this.TXTPassword.focused = false;
        this.TXTPassword.className = 'form_raw_input';
        this.TXTPassword.style.width = '270px';
        this.TXTPassword.value = '';
        
        this.TXTPasswordConfirm = document.createElement('input');
        this.TXTPasswordConfirm.setAttribute('id', 'form_registration_passwordconfirm');
        this.TXTPasswordConfirm.setAttribute('type', 'password');
        this.TXTPasswordConfirm.setAttribute('tabindex', 8);
        this.TXTPasswordConfirm.focused = false;
        this.TXTPasswordConfirm.className = 'form_raw_input';
        this.TXTPasswordConfirm.style.width = '270px';
        this.TXTPasswordConfirm.value = '';
        
		this.TXTCAPTCHA = document.createElement('input');
        this.TXTCAPTCHA.setAttribute('id', 'form_registration_captcha');
        this.TXTCAPTCHA.setAttribute('type', 'text');
        this.TXTCAPTCHA.setAttribute('tabindex', 9);
        this.TXTCAPTCHA.focused = false;
        this.TXTCAPTCHA.className = 'form_raw_input';
        this.TXTCAPTCHA.style.width = '270px';
        this.TXTCAPTCHA.value = '';
        
		this.CAPTCHAReloadIcon = document.createElement('img');
        this.CAPTCHAReloadIcon.setAttribute('id', 'form_registration_captcha_icon_reload');
        this.CAPTCHAReloadIcon.className = 'InlineIcon16';
        this.CAPTCHAReloadIcon.src = 'img/icons/16/refresh.png';
        this.CAPTCHAReloadIcon.style.border = 'solid 1px #EEEEEE';
        this.CAPTCHAReloadIcon.style.margin = '0px 4px 0px 2px';
        this.CAPTCHAReloadIcon.style.cursor = 'pointer';
        this.CAPTCHAReloadIcon.style.visibility = 'visible';
        this.CAPTCHAReloadIcon.alt = 'Get New CAPTCHA';
        this.CAPTCHAReloadIcon.title = 'Get New CAPTCHA';
        
		this.CAPTCHAImage = document.createElement('img');
        this.CAPTCHAImage.setAttribute('id', 'form_registration_captcha_image');
        this.CAPTCHAImage.setAttribute('name', 'form_registration_captcha_image');
        this.CAPTCHAImage.className = 'form_raw_captcha';
        this.CAPTCHAImage.alt = 'Loading CAPTCHA...';
        this.CAPTCHAImage.src = '';
        
        document.getElementById('spn_registration_name_first').appendChild(this.TXTNameFirst);
        document.getElementById('spn_registration_name_middle').appendChild(this.TXTNameMiddle);
        document.getElementById('spn_registration_name_last').appendChild(this.TXTNameLast);
        document.getElementById('td_registration_email').appendChild(this.TXTEmail);
        document.getElementById('td_registration_emailconfirm').appendChild(this.TXTEmailConfirm);
        document.getElementById('td_registration_username').appendChild(this.TXTUsername);
        document.getElementById('td_registration_password').appendChild(this.TXTPassword);
        document.getElementById('td_registration_passwordconfirm').appendChild(this.TXTPasswordConfirm);
        document.getElementById('td_registration_captcha').appendChild(this.TXTCAPTCHA);
        document.getElementById('td_registration_captcha_icon_reload').appendChild(this.CAPTCHAReloadIcon);
        document.getElementById('td_registration_captcha_image').appendChild(this.CAPTCHAImage);
        
        document.getElementById('form_registration_system_tag').innerHTML = '';
        document.getElementById('td_registration_system').style.display = 'none';
        document.getElementById('td_registration_system_left').style.display = 'none';
        document.getElementById('td_registration_system_right').style.display = 'none';
        document.getElementById('td_registration_system').style.visibility = 'hidden';
        document.getElementById('td_registration_system_left').style.visibility = 'hidden';
        document.getElementById('td_registration_system_right').style.visibility = 'hidden';
        
        document.getElementById('form_registration_name_tag').innerHTML = '<span class="form_tag_error_user">Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'6\');">?</a>]</span>';
        document.getElementById('form_registration_email_tag').innerHTML = '<span class="form_tag_error_user">Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'7\');">?</a>]</span>';
        document.getElementById('form_registration_emailconfirm_tag').innerHTML = '&nbsp;';
        document.getElementById('form_registration_username_tag').innerHTML = '<span class="form_tag_error_user">Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'10\');">?</a>]</span>';
        document.getElementById('form_registration_password_tag').innerHTML = '<span class="form_tag_error_user">Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'9\');">?</a>]</span>';
        document.getElementById('form_registration_passwordconfirm_tag').innerHTML = '&nbsp;';
        document.getElementById('form_registration_captcha_tag').innerHTML = '<span class=\'form_tag_error_user\'>Incomplete&nbsp;[<a href="JavaScript: ShowTip(\'17\');">?</a>]</span>';
        
        o.style.display = 'block';
        o.style.visibility = 'visible';
        document.getElementById('spnSystemRegistration').style.display = 'block';
        document.getElementById('spnSystemRegistration').style.visibility = 'visible';
        document.getElementById('divMain').style.display = 'none';
        document.getElementById('divMain').style.visibility = 'hidden';
        
        eventPush(this.TXTNameFirst, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTNameFirst, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTNameFirst, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTNameFirst, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTNameFirst, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTNameMiddle, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTNameMiddle, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTNameMiddle, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTNameMiddle, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTNameMiddle, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTNameLast, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTNameLast, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTNameLast, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTNameLast, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTNameLast, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTEmail, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTEmail, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTEmail, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTEmail, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTEmail, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTEmail, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTEmailConfirm, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTEmailConfirm, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTEmailConfirm, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTEmailConfirm, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTEmailConfirm, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTEmailConfirm, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTUsername, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTUsername, 'blur', Browser.RawInputUsernameBlur);
        eventPush(this.TXTUsername, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTUsername, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTUsername, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTPassword, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTPassword, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPassword, 'blur', Browser.RawInputPasswordBlur);
        eventPush(this.TXTPassword, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPassword, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPassword, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTPasswordConfirm, 'change', Browser.RawInputChangeConfirm);
        eventPush(this.TXTPasswordConfirm, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTPasswordConfirm, 'blur', Browser.RawInputPasswordBlur);
        eventPush(this.TXTPasswordConfirm, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTPasswordConfirm, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTPasswordConfirm, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.TXTCAPTCHA, 'focus', Browser.RawInputFocus);
        eventPush(this.TXTCAPTCHA, 'blur', Browser.RawInputBlur);
        eventPush(this.TXTCAPTCHA, 'mousedown', Browser.RawInputMouseDown);
        eventPush(this.TXTCAPTCHA, 'mouseover', Browser.RawInputMouseOver);
        eventPush(this.TXTCAPTCHA, 'mouseout', Browser.RawInputMouseOut);
        
        eventPush(this.CAPTCHAReloadIcon, 'click', Browser.RawButtonClick);
        eventPush(this.CAPTCHAReloadIcon, 'mousedown', Browser.RawButtonMouseDown);
        eventPush(this.CAPTCHAReloadIcon, 'mouseover', Browser.RawButtonMouseOver);
        eventPush(this.CAPTCHAReloadIcon, 'mouseout', Browser.RawButtonMouseOut);
        eventPush(this.CAPTCHAReloadIcon, 'mouseup', Browser.RawButtonMouseUp);
        
        //o = document.getElementById('form_login_username');
        //if(o) {
            this.TXTNameFirst.focus();
            this.FocusObj = this.TXTNameFirst;
        //} else {
        //    this.FocusObj = null;
        //}
        this.FSetCaptcha(290);
    }
    this.SysRegistration = true;
}
function cBrowser_Size(obj) {
    if(this.Sizing == true) { return; }
    var oW = this.ScreenMetrics.Width;
    var oH = this.ScreenMetrics.Height;
    this.ScreenMetrics = this.GetPosition(obj);
    if((oW > this.ScreenMetrics.Width) || (oH > this.ScreenMetrics.Height)) {
        Browser.Size(obj);
    }
}
function cBrowser_SystemCommand(command, code) {
    this.ShowLoading();
    var bH = false;
    var msg;
    switch(command.toLowerCase()) {
        case 'blockreg':
            msg = new Array('auth', 'registrationblock', code);
            this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
            bH = true;
            break;
        case 'confirmreg':
            msg = new Array('auth', 'registrationconfirm', code);
            this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
            bH = true;
            break;
        case 'login':
            this.HideLoading();
            this.ShowLogin();
            bH = true;
            break;
        case 'lostpassword':
            this.HideLoading();
            this.ShowLostPassword();
            bH = true;
            break;
        case 'lostusername':
            this.HideLoading();
            this.ShowLostUsername();
            bH = true;
            break;
        case 'login':
            this.HideLoading();
            this.ShowLogin();
            bH = true;
            break;
        case 'pwaudit':
            msg = new Array('auth', 'pwaudit', code);
            this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
            bH = true;
            break;
        case 'pwreset':
            msg = new Array('auth', 'pwreset', code);
            this.GetAjax(this.GetFirstAjaxID()).Send(true, -1, -1, -1, msg);
            bH = true;
            break;
        case 'register':
            this.HideLoading();
            this.ShowRegistration();
            bH = true;
            break;
    }
    if(bH == false) {
        if(this.SysFail.length > 0) {
            setTimeout('Browser.HideLoading();' + this.SysFail, 1);
        }
    }
}
function cBrowser_TickSize(itr) {
    this.Sizing = false;
    if(itr <= 0) {
        this.Size(document.getElementById('divSize'));
    } else {
        this.Sizing = true;
        setTimeout('Browser.TickSize(' + (itr - 1) + ')', 1000);
    }
}
function ShowTip(tipID) {
    document.getElementById('tipContainer').style.visibility = 'visible';
    document.getElementById('tipContainer').style.display = 'block';
    document.getElementById('ifTip').src = 'inc/tips/'+tipID+'.htm';
}
function HideTip() {
    document.getElementById('tipContainer').style.display = 'none';
    document.getElementById('tipContainer').style.visibility = 'hidden';
}
cBrowser.prototype.Activate = cBrowser_Activate;
cBrowser.prototype.AjaxArrival = cBrowser_AjaxArrival;
cBrowser.prototype.AjaxProcess = cBrowser_AjaxProcess;
cBrowser.prototype.AjaxProcessAuth = cBrowser_AjaxProcessAuth;
cBrowser.prototype.AjaxProcessAuthBlockRegEmail = cBrowser_AjaxProcessAuthBlockRegEmail;
cBrowser.prototype.AjaxProcessAuthConfirmRegistration = cBrowser_AjaxProcessAuthConfirmRegistration;
cBrowser.prototype.AjaxProcessAuthClassify = cBrowser_AjaxProcessAuthClassify;
cBrowser.prototype.AjaxProcessAuthLogin = cBrowser_AjaxProcessAuthLogin;
cBrowser.prototype.AjaxProcessAuthLostPassword = cBrowser_AjaxProcessAuthLostPassword;
cBrowser.prototype.AjaxProcessAuthLostUsername = cBrowser_AjaxProcessAuthLostUsername;
cBrowser.prototype.AjaxProcessAuthPasswordReset = cBrowser_AjaxProcessAuthPasswordReset;
cBrowser.prototype.AjaxProcessAuthPWAudit = cBrowser_AjaxProcessAuthPWAudit;
cBrowser.prototype.AjaxProcessAuthPWReset = cBrowser_AjaxProcessAuthPWReset;
cBrowser.prototype.AjaxProcessAuthRegistration = cBrowser_AjaxProcessAuthRegistration;
cBrowser.prototype.AjaxProcessAuthStat = cBrowser_AjaxProcessAuthStat;
cBrowser.prototype.AjaxProcessValidator = cBrowser_AjaxProcessValidator;
cBrowser.prototype.Classify = cBrowser_Classify;
cBrowser.prototype.ClearFocusControl = cBrowser_ClearFocusControl;
cBrowser.prototype.CreateAjax = cBrowser_CreateAjax;
cBrowser.prototype.DisplayPhoto = cBrowser_DisplayPhoto;
cBrowser.prototype.FCaptchaClear = cBrowser_FCaptchaClear;
cBrowser.prototype.FCaptchaRefresh = cBrowser_FCaptchaRefresh;
cBrowser.prototype.FetchClassificationDisplayName = cBrowser_FetchClassificationDisplayName;
cBrowser.prototype.FReloadCaptcha = cBrowser_FReloadCaptcha;
cBrowser.prototype.FSetCaptcha = cBrowser_FSetCaptcha;
cBrowser.prototype.FStartValidate = cBrowser_FStartValidate;
cBrowser.prototype.FValidate = cBrowser_FValidate;
cBrowser.prototype.FValidateCompare = cBrowser_FValidateCompare;
cBrowser.prototype.FValidateEnd = cBrowser_FValidateEnd;
cBrowser.prototype.FValidatePassword = cBrowser_FValidatePassword;
cBrowser.prototype.GetCooldownOverlay = cBrowser_GetCooldownOverlay;
cBrowser.prototype.GetEventKey = cBrowser_GetEventKey;
cBrowser.prototype.GetFirstAjaxID = cBrowser_GetFirstAjaxID;
cBrowser.prototype.GetFreeAjaxID = cBrowser_GetFreeAjaxID;
cBrowser.prototype.GetAjax = cBrowser_GetAjax;
cBrowser.prototype.GetMouseCords = cBrowser_GetMouseCords;
cBrowser.prototype.GetPosition = cBrowser_GetPosition;
cBrowser.prototype.GetTextSize = cBrowser_GetTextSize;
cBrowser.prototype.HideAll = cBrowser_HideAll;
cBrowser.prototype.HideLoading = cBrowser_HideLoading;
cBrowser.prototype.HideDirectMessage = cBrowser_HideDirectMessage;
cBrowser.prototype.HideClassifier = cBrowser_HideClassifier;
cBrowser.prototype.HideLogin = cBrowser_HideLogin;
cBrowser.prototype.HideLostPassword = cBrowser_HideLostPassword;
cBrowser.prototype.HideLostUsername = cBrowser_HideLostUsername;
cBrowser.prototype.HidePasswordReset = cBrowser_HidePasswordReset;
cBrowser.prototype.HidePhoto = cBrowser_HidePhoto;
cBrowser.prototype.HideRegistration = cBrowser_HideRegistration;
cBrowser.prototype.KeyDown = cBrowser_KeyDown;
cBrowser.prototype.KeyUp = cBrowser_KeyUp;
cBrowser.prototype.Load = cBrowser_Load;
cBrowser.prototype.Login = cBrowser_Login;
cBrowser.prototype.Logout = cBrowser_Logout;
cBrowser.prototype.MouseDown = cBrowser_MouseDown;
cBrowser.prototype.MouseMove = cBrowser_MouseMove;
cBrowser.prototype.MouseUp = cBrowser_MouseUp;
cBrowser.prototype.PreCache = cBrowser_PreCache;
cBrowser.prototype.RawButtonClick = cBrowser_RawButtonClick;
cBrowser.prototype.RawButtonMouseDown = cBrowser_RawButtonMouseDown;
cBrowser.prototype.RawButtonMouseOver = cBrowser_RawButtonMouseOver;
cBrowser.prototype.RawButtonMouseOut = cBrowser_RawButtonMouseOut;
cBrowser.prototype.RawButtonMouseUp = cBrowser_RawButtonMouseUp;
cBrowser.prototype.RawInputChangeConfirm = cBrowser_RawInputChangeConfirm;
cBrowser.prototype.RawInputFocus = cBrowser_RawInputFocus;
cBrowser.prototype.RawInputMouseDown = cBrowser_RawInputMouseDown;
cBrowser.prototype.RawInputMouseOver = cBrowser_RawInputMouseOver;
cBrowser.prototype.RawInputMouseOut = cBrowser_RawInputMouseOut;
cBrowser.prototype.RawInputBlur = cBrowser_RawInputBlur;
cBrowser.prototype.RawInputPasswordBlur = cBrowser_RawInputPasswordBlur;
cBrowser.prototype.RawInputUsernameBlur = cBrowser_RawInputUsernameBlur;
cBrowser.prototype.Register = cBrowser_Register;
cBrowser.prototype.RemoveAjax = cBrowser_RemoveAjax;
cBrowser.prototype.RequestLostPassword = cBrowser_RequestLostPassword;
cBrowser.prototype.RequestLostUsername = cBrowser_RequestLostUsername;
cBrowser.prototype.ResetPassword = cBrowser_ResetPassword;
cBrowser.prototype.SetFocusControl = cBrowser_SetFocusControl;
cBrowser.prototype.ShowLoading = cBrowser_ShowLoading;
cBrowser.prototype.ShowDirectMessage = cBrowser_ShowDirectMessage;
cBrowser.prototype.ShowLogin = cBrowser_ShowLogin;
cBrowser.prototype.ShowClassifier = cBrowser_ShowClassifier;
cBrowser.prototype.ShowLostPassword = cBrowser_ShowLostPassword;
cBrowser.prototype.ShowLostUsername = cBrowser_ShowLostUsername;
cBrowser.prototype.ShowPasswordReset = cBrowser_ShowPasswordReset;
cBrowser.prototype.ShowProfileEditor = cBrowser_ShowProfileEditor;
cBrowser.prototype.ShowRegistration = cBrowser_ShowRegistration;
cBrowser.prototype.Size = cBrowser_Size;
cBrowser.prototype.SystemCommand = cBrowser_SystemCommand;
cBrowser.prototype.TickSize = cBrowser_TickSize;
cBrowser.prototype.ShowTip = ShowTip;
cBrowser.prototype.HideTip = HideTip;
function cCooldownOverlay(size) {
    this.Size = size;
    this.Active = false;
    this.StartTime = 0;
    this.Cooldown = 0;
    this.OverObject = null;
    
    //X:0, Y:0, Width: 18, Height: 18, Icon:'img/icons/odd/18cooldown_76.png', Count:76
    this.Style = {X:0, Y:0, Width: 18, Height: 18, Image:'img/icons/odd/18cooldown_76.png', Count:76 };
    
    this.DIVButton = document.createElement('div');
    this.DIVButton.setAttribute('id', 'divCooldownOverlay_' + size);
    this.DIVButton.style.border = '0px';
    this.DIVButton.style.margin = '0px';
    this.DIVButton.style.padding = '0px';
    this.DIVButton.style.position = 'absolute';
    this.DIVButton.style.display = 'none';
    this.DIVButton.style.visibility = 'hidden';
    this.SPANIcon = document.createElement('span');
    this.SPANIcon.setAttribute('id', 'spnCooldownOverlayIcon_' + size);
    this.SPANIcon.style.border = '0px';
    this.SPANIcon.style.margin = '0px';
    this.SPANIcon.style.padding = '0px';
    this.SPANIcon.style.marginLeft = this.Style.X + 'px';
    this.SPANIcon.style.marginTop = this.Style.Y + 'px';
    this.SPANIcon.style.left = '0px';
    this.SPANIcon.style.top = '0px';
    this.SPANIcon.style.width = this.Style.Width + 'px';
    this.SPANIcon.style.height = this.Style.Height + 'px';
    this.SPANIcon.style.backgroundImage = 'url('+this.Style.Image+')';
    this.SPANIcon.style.display = 'block';
    this.SPANIcon.style.visibility = 'visible';
    this.SPANIcon.style.overflow = 'hidden';

        this.DIVButton.appendChild(this.SPANIcon);
    document.body.appendChild(this.DIVButton);
    
}
function cCooldownOverlay_Dispose() {
        this.DIVButton.removeChild(this.SPANIcon);
    document.body.removeChild(this.DIVButton);
}
function cCooldownOverlay_Hide() {
    this.Active = false;
    this.OverObject = null;
    this.DIVButton.style.display = 'none';
    this.DIVButton.style.visibility = 'hidden';
}
function cCooldownOverlay_Position() {
    if(this.OverObject == null) { return; }
    var p = Browser.GetPosition(this.OverObject);
    if(p == null) { return; }
    this.DIVButton.style.left = (p.X + this.Style.X) + 'px';
    this.DIVButton.style.top = (p.Y + this.Style.Y) + 'px';
    this.DIVButton.style.width = this.Style.Width + 'px';
    this.DIVButton.style.height = this.Style.Height + 'px';
}
function cCooldownOverlay_RenderSize() {
    this.SPANIcon.style.marginLeft = this.Style.X + 'px';
    this.SPANIcon.style.marginTop = this.Style.Y + 'px';
    this.SPANIcon.style.width = this.Style.Width + 'px';
    this.SPANIcon.style.height = this.Style.Height + 'px';
}
function cCooldownOverlay_Show(obj, cooldown) {
    this.TimeoutItr = 0;
    this.OverObject = obj;
    this.RenderSize();
    this.Position();
    this.SPANIcon.style.backgroundPosition = '0px 0px';
    this.SPANIcon.style.visibility = 'visible';
    this.SPANIcon.style.display = 'block';
    this.DIVButton.style.visibility = 'visible';
    this.DIVButton.style.display = 'block';
    this.DIVButton.style.zIndex = 999999;
    var dt = new Date();
    this.StartTime = dt.getTime();
    delete dt;
    this.Cooldown = cooldown;
    this.DIVButton.title = this.OverObject.title + ' - Cooldown in ' + parseInt(this.Cooldown / 1000) + ' seconds'
    setTimeout('Browser.GetCooldownOverlay(' + this.Size + ').Timeout();', parseInt(this.Cooldown / this.Style.Count));
    this.Active = true;
}
function cCooldownOverlay_Timeout() {
    var dt = new Date();
    var CurrentTime = dt.getTime();
    delete dt;
    dt = (CurrentTime - this.StartTime);
    CurrentTime = ((dt / this.Cooldown) * this.Style.Count);
    if(CurrentTime >= (this.Style.Count - 1)) {
        this.Hide();
    } else {
        this.Position();
        this.SPANIcon.style.backgroundPosition = (parseInt(this.Style.Count - CurrentTime) * this.Size) + 'px 0px';
        this.DIVButton.title = this.OverObject.title + ' - Cooldown in ' + parseInt((this.Cooldown - dt) / 1000) + ' seconds'
        setTimeout('Browser.GetCooldownOverlay(' + this.Size + ').Timeout();', parseInt(this.Cooldown / this.Style.Count));
    }
}
cCooldownOverlay.prototype.Dispose = cCooldownOverlay_Dispose;
cCooldownOverlay.prototype.Hide = cCooldownOverlay_Hide;
cCooldownOverlay.prototype.Position = cCooldownOverlay_Position;
cCooldownOverlay.prototype.RenderSize = cCooldownOverlay_RenderSize;
cCooldownOverlay.prototype.Show = cCooldownOverlay_Show;
cCooldownOverlay.prototype.Timeout = cCooldownOverlay_Timeout;function cQueue(){var _1=[];var _2=0;this.size=function(){return _1.length-_2;};this.empty=function(){return (_1.length==0);};this.push=function(_3){_1.push(_3);};this.pop=function(){var _4=undefined;if(_1.length){_4=_1[_2];if(++_2*2>=_1.length){_1=_1.slice(_2);_2=0;}}return _4;};this.front=function(){var _5=undefined;if(_1.length){_5=_1[_2];}return _5;};}
function StartBrowser() {
    Browser = new cBrowser();
    Browser.Load();
    Browser.Size(document.getElementById('divMain'));
    PageMain();
}

