jquery 1.4.2 - $post - memory and handles grows up on IE 7/8- memory grows up in firefox and opera
Hi,
I've switched to the new version of jquery and get trouble with ajax ($post). I see in the taskmanager of windows on every ajax call there are 2 handles lost and the memory usage of the browers grows up. With jquery 1.3.2 there are no problems.
Is there a solution?
Regards
Dirk
I'm using
apache 2.2.14 (win32)
php 5.2.13 (cli)
jquery 1.4.2
code:
1) test_post.html
2) test_post.php
- <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>test post</title>
<!--
<script type="text/javascript" src="jqs/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="jqs/jquery.json-2.2.js"></script>
-->
<script type="text/javascript" src="jqs/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="jqs/jquery.json-2.2.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$('#start').bind("click",function(){
$.post("test_post.php", { name: "John", time: "2pm" },function(data){
$("#out").text(data.name + " " + data.time);
},'json');
});
});
</script>
</head>
<body>
<button id='start'>Start</button>
<br/>
<br/>
<br/>
<span id="out"></span>
</body>
</html>
- <?php
session_start();
$t->name = $_POST['name'];
$t->time = $_POST['time'];
echo json_encode($t);
?>