樣式表,CSS代碼:
.abc{
position:absolute;
left:1px;
top:1px;
width:1024px;
height:768px;
z-index:0;
background-repeat: repeat;
background-color:white;
FILTER: alpha(opacity=60);
opacity: 0.6;
}
.start{
}
.abc1 {
position:absolute;
left:350px;
top:240px;
width:300px;
height:100px;
z-index:0;
}
腳本,Javascript代碼:
var XMLHttp;
function createXMLHttpRequest() {
if (window.ActiveXObject) {
xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
}
else if (window.XMLHttpRequest) {
xmlHttp = new XMLHttpRequest();
}
}
function forget(){
createXMLHttpRequest();
var queryString = "tryAJaxAction.do?";
queryString = queryString + createString()
+ "&timeStamp=" + new Date().getTime();
XMLHttp.onreadystatechange = doForget;
XMLHttp.open("GET", "forget.JSP", "true");
XMLHttp.send(null);
}
function doForget(){
if(XMLHttp.readyState == 4) {
if(XMLHttp.status == 200) {
var layer = document.getElementById("Layer1");
layer.className = "abc";
var layer2 = document.getElementById("Layer2");
layer2.className = "abc1";
layer2.innerHtml = XMLHttp.responseText;
}
}
}
頁面內容,XML代碼:
<table width="100%" height="587" border="0">