can't return false in live event on Internet Explorer
This works fine in Firefox, but Internet Explorer ignores the return false and just follows the link.
-
$('#favorite>a').live("click", function(){
$('#favorite>a').attr("disabled", "disabled");
var photo_id = '<?php echo $_GET['id']; ?>';
var user_id = '<?php echo $user_id; ?>';
$.ajax({
type: 'POST',
url: 'process_favorite.php',
data: 'favorite=true&photo_id=' + photo_id + '&user_id=' + user_id,
success: function(result) {
$('#favorite').html(result);
}
});
return false;
});