ho trovato questo solo come posso fare per far vedere i risultati in una nuova pagina?
codice:
<html>
<head>
<script type="text/javascript" src="js/jquery/jquery-1.3.2.js"></script><script type="text/javascript">
$(document).ready(function() {
$('#preloader').hide();
$('#preloader')
.ajaxStart(function(){
//hides the button
$('#submitBTN').hide();
//show preloader
$(this).show();
}).ajaxStop(function(){
//hides preloader on complete
$(this).hide();
//shows button again
$('#submitBTN').show();
});
$('#form form').submit(function(){
$('#return').empty();
//data.php is the processsing script
$.get('data.php', $(this).serialize(), function(data){
$('#return').html(data);
});
return false;
});
});
</script>
</head>
<body>
<div id="form">
<form id="myform">
name : <input type="text" name="name">
age : <input type="text" name="age">
<input type="submit" name="submit" value="Submit" id = "submitBTN" ><div id="preloader">[img]/img/ajax_progress2.gif[/img] Loading...</div>
</form>
</div>
<div id="return"></div>
</body>
</html>