﻿// JScript File
function SwitchImage(identifier, image)
{
    identifier.src = image;
}

function checkTextBoxLength128(objSource, objArgs)
{
    objArgs.IsValid = (objArgs.Value.length <=128);
}

function checkTextBoxLength256(objSource, objArgs)
{
    objArgs.IsValid = (objArgs.Value.length <=256);
}

function checkTextBoxLength512(objSource, objArgs)
{
    objArgs.IsValid = (objArgs.Value.length <=512);
}

function checkTextBoxLength1024(objSource, objArgs)
{
    objArgs.IsValid = (objArgs.Value.length <=1024);
}

function checkTextBoxLength4000(objSource, objArgs)
{
    objArgs.IsValid = (objArgs.Value.length <=4000);
}

//scroller.... it works? IT WAS, but not with mozilla
/*
//scroller width
var swidth

//scroller height
var sheight

//scroller's speed;
var sspeed

var mymessage=''

//text: change to your own

function start()
{
    if (document.all) return
    if (document.getElementById)
    {
        document.getElementById("slider").style.visibility="show"
        ns6marquee(document.getElementById('slider'))
    }
    else 
        if(document.layers)
        {
            document.slider1.visibility="show"
            ns4marquee(document.slider1.document.slider2)
        }
}
function ns4marquee(whichlayer)
{
    ns4layer=eval(whichlayer)
    ns4layer.document.write(mymessage)
    ns4layer.document.close()
    sizeup=ns4layer.document.height
    ns4layer.top-=sizeup
    ns4slide()
}
function ns4slide()
{
    if (ns4layer.top>=sizeup*(-1))
    {
        ns4layer.top-=sspeed
        setTimeout("ns4slide()",100)
    }
    else
    {
        ns4layer.top=sheight
        ns4slide()
    }
}
function ns6marquee(whichdiv)
{
    ns6div=eval(whichdiv)
    ns6div.innerHTML=mymessage
    ns6div.style.top=sheight
    sizeup=sheight
    ns6slide()
}
function ns6slide()
{
    if (parseInt(ns6div.style.top)>=sizeup*(-1))
    {
        ns6div.style.top=parseInt(ns6div.style.top)-sspeed
        setTimeout("ns6slide()",100)
    }
    else
    {
        ns6div.style.top=sheight
        ns6slide()
    }
}

function MM_jumpMenu(targ,selObj,restore)
{ //v3.0
    eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
    if (restore) selObj.selectedIndex=0;
}

function ExecuteText(text, width, height, speed)
{
    if (document.all)
    {
        mymessage = text
        swidth=width
        sheight=height
        sspeed=speed

        document.writeln('<marquee id="ieslider" scrollAmount=' + speed + ' width=' + width + ' height=' + height + ' direction=up >')
        document.writeln(mymessage)
        ieslider.onmouseover=new Function("ieslider.scrollAmount=0")
        ieslider.onmouseout=new Function("if (document.readyState=='complete') ieslider.scrollAmount=" + speed)
        document.write('</marquee>')
    }
    if (document.getElementById&&!document.all)
    { 
        document.write('<div style="position:relative;overflow:hidden;width:' + width + ';height:' +  height + ';clip:rect(0 302 102 0);" onMouseover="sspeed=0;" onMouseout="sspeed=' + speed + '">')
        document.write('<div id="slider" style="position:relative;width:&{swidth};">')
        document.write('</div></div>')
    }
}
*/
