trigger() not passing arguments properly
I have a problem with passing arguments from a trigger to a click-handler;
With jQuery 1.9.1 arguments are not passed to the click handler, as where with jquery 1.7.2 they are nicely passed.
A example to demonstrate:
<!doctype html>
<head>
<script src="js/jquery-1.9.1.js" type="text/javascript"></script>
<script src="js/jquery-ui-1.10.1.min.js" type="text/javascript"></script>
</head>
<body>
<input id="test" type="checkbox" checked="checked">
<button id='trigger'>trigger</button>
</body>
<script type="text/javascript">
$('#test').click(
function (e, passed1,passed2){
alert('first passed=' + passed1 + ' second passed='+passed2);
});
$('#trigger').click(
function (e){
$('#test').trigger('click',['first','second']);
});
</script>
</html>
When I use jquery-1.7.2.js it still works fine.
What am I missing? Please help me.