Ok, IsaBelM yo no me acuerdo de donde me baje el cod pero si que esta mal estructurado.
A ver que te parece este que te veo muy estresada
Código PHP:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Prueba</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
<script type="text/javascript">
$(function(){
$.ajax({
url: 'x.php',
beforeSend: function(data) {
$('body').html('Cargando...');
},
complete: function(){
$('body').html('');
}
});
});
</script>
<style>
</style>
</head>
<body>
</body>
</html>
Un saludo