Question on JavaScript
- From: Dorothy Mantooth <schmidtkk@xxxxxxxxx>
- Date: Mon, 30 Jun 2008 08:55:20 -0700 (PDT)
My company is switching from using a vendor DNS server to our own as
well as creating a new network. We want to verify whether or not our
customers can "reach" our new network so we have placed some
JavaScript on the logon page of one of our applications to check for
the existence of an image on the new network. We have had over 20,000
successes and about 300 failures. I want to know if the failures
could be do to the following scripting code or if we should continue
to look at the DNS, ACL's, etc. I want to rule out the script. The
failures are falling into the isBad funciton and we are logging.
function testImage(URL)
var tester=new Image();
tester.onload=isGood;
tester.onerror=isBad;
tester.src=URL;
}
function isGood() {
if( debug ) {
alert('Image exists!');
//Log success (around 20,000)
}
}
function isBad() {
if( debug ) {
alert('Image does no exist!');
//Log failure (around 300)
}
}
.
- Prev by Date: Visual Mapping Source
- Next by Date: Re: Prefixes of regular expressions
- Previous by thread: Visual Mapping Source
- Next by thread: new to java, help simple project
- Index(es):
Relevant Pages
|