How to pass the event interface?
I have following situation:
$('selector').live('click', openSite);
and open site takes the event like this
function openSite(e){
e.preventDefault();
}
If I change my first line of code to
$('selector').live('click', function(e){
});
How do I call siteOp开发者_JS百科en within this code correctly? openSite(e) does not work.
Have you double checked your code for any typos? Here's a working example of how you've described your desired functionality.
http://jsbin.com/ijufe4
精彩评论