/////////////ajax代码
<script type="text/javascript">
var xmlHttp;
function createXMLHttpRequest() {
if (window.ActiveXObject) {
xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
}
else if (window.XMLHttpRequest) {
xmlHttp = new XMLHttpRequest();
}
}
function startRequest(obj) {
createXMLHttpRequest();
xmlHttp.onreadystatechange = handleStateChange;
xmlHttp.open("GET", "getOptions.aspx?prov="+escape(obj)+"×tamp="+new Date().getTime(), true);
xmlHttp.send(null);
}
function handleStateChange() {
if(xmlHttp.readyState == 4) {
if(xmlHttp.status == 200) {
var ocity=new String(xmlHttp.responseText);
document.getElementById("AreaID").innerHTML="";
var tt=ocity.split(',');
for(var i=0;i<tt.length;i++)
{
var ott=new Option(tt[i],tt[i],false,false);
document.getElementById("AreaID").options.add(ott);
}
}
}
else
{
document.getElementById("AreaID").options.add(new Option("请等待..."));
}
}
</script>
////////////////////
////后台
AreaID.Items[AreaID.SelectedIndex].Value
/////
可这里的SelectedIndex跟踪显示总是0,
高手帮忙解答了