日期:2014-05-16 浏览次数:20363 次
<p id="msg">This paragraph is for AJAX demo</p>
<!DOCTYPE html>
<html>
<head>
<title></title>
<link rel="stylesheet" type="text/css" href="resources/css/ext-all.css"/>
<script type="text/javascript" src="js/ext-all-debug.js" ></script>
<script type="text/javascript">
var myDiv;
function loadParagraph(){
Ext.get('container').load({
url:'ajax_piece.html',
callback:function(el,success,response){
console.debug(success); //1
console.debug(response); //2
}
});
}
Ext.onReady(function(){
myDiv = Ext.get('msg');
console.debug(myDiv.dom.innerHTML);
Ext.Function.defer(loadParagraph,1000);
});
</script>
</head>
<body>
<div id="container">
<div id="msg">This is local msg.</div>
</div>
</body>
</html>
status 0
statusText ""
responseText "<p id="msg">This paragraph is for AJAX demo</p>"