I have to two select boxes with values and two javascripts which call server-side scripts. The first select box will write to the first <div id='txtHint1'></div>, but when I intoduce a second <div id='txtHint2'></div>, the first select box writes to there instead of <div id='txtHint1'></div>.
First Select Box
Second Select Box
First JS
[CODE=javascript]function stateChanged()
{
if (xmlHttp.readyS tate==4 || xmlHttp.readySt ate=="complete" )
{
document.getEle mentById("txtHi nt1").innerHTML =xmlHttp.respon seText
}
}
[/CODE]
Second JS
[CODE=javascript]function stateChanged()
{
if (xmlHttp.readyS tate==4 || xmlHttp.readySt ate=="complete" )
{
document.getEle mentById("txtHi nt2").innerHTML =xmlHttp.respon seText
}
}[/CODE]
First Select Box
Code:
onchange='javascript:showCertificates(this.value)
Code:
onchange='javascript:showEndorsements(this.value)
[CODE=javascript]function stateChanged()
{
if (xmlHttp.readyS tate==4 || xmlHttp.readySt ate=="complete" )
{
document.getEle mentById("txtHi nt1").innerHTML =xmlHttp.respon seText
}
}
[/CODE]
Second JS
[CODE=javascript]function stateChanged()
{
if (xmlHttp.readyS tate==4 || xmlHttp.readySt ate=="complete" )
{
document.getEle mentById("txtHi nt2").innerHTML =xmlHttp.respon seText
}
}[/CODE]
Comment