Problem with unbind (to bind again)
Hi all,
I have a problem with unbind/bind.
My code is something like
- $(document).ready(function(){
- $("#icon_left").click(function(){
- $('#icon_left').unbind('click'); //This works ok, here I prevent the user clicks while I'm executing some instructions
-
- //A lot of stuff
- ...
- ...
- //now the user should be able to click again
- $('#icon_left').bind('click'); //Unfortunatelly, I can't click :S
- });
- });
I have no idea about why it happens...
Thanks a lot for your help!