function ACClient( queryurl, width, objInput, objLable )
{
this.xmldom = getXmlhttp();
this.queryurl = クエリurl;
this.prolist = new Array();
this.divwidth = 幅;
this.objInput = objInput;
this.getEligible = function(ac) {
var subject = new Array();
if (ac.inputText.length document.getElementById(objInput.name).value = "";
document.getElementById(objLable.name).value = "";
返品対象。
}
var strURL = this.queryurlscape(ac.inputText) "&rand=" Math.random();
this.xmldom.open("GET", strURL, false);
試してください {
this.xmldom.send();
}
catch (e) {
return;
}
this.prolist = this.xmldom.responseXML.documentElement.selectNodes("/duxion/object");
if (0 == this.prolist.length) {
返品対象;
}
for (var i = 0; i < this.prolist.length; i ) {
if (i > 15)
break;
var ノード = this.prolist.item(i);
eligible[eligible.length] = node.getAttribute("fullcontent");
}
ac.div.style.width = this.divwidth;
返品対象。
};
this.useSuggestion = function( sel )
{
if( sel>=0 )
{
var node = this.prolist.item(sel);
if(typeof(node.getAttribute( "value" )) != "未定義")
document.getElementById(objInput.name).value = node.getAttribute( "value" );
else
document.getElementById(objInput.name).value = "";
if(typeof(node.getAttribute( "content" )) != "未定義")
document.getElementById(objLable.name).value = node.getAttribute( "content" );
else
document.getElementById(objLable.name).value = "";
if (this.objInput.name == "hidfreq_code") {
document.getElementById("txtfreq_name").value = node.getAttribute("Name");
document.getElementById("hidfreq_code").value = node.getAttribute("コード");
}
}
};
これを返します;
}