Code: Select all
<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript">
$(document).ready(function(){
//START
$("div").click(function(event){
$("#getcontent").html("<img src='throbber.gif' alt='Loading...' />");
$.get("test.php", function(data){
$("#getcontent").html(data);
});
});
//END
});
</script>
</head>
<body>
<div id='getcontent' width='343' height='333' style='background-color:red;height:333;'>test</div>
</body>
</html>