Monday, 15 June 2015

jquery - how to get fancybox textbox value after closing fancybox -



jquery - how to get fancybox textbox value after closing fancybox -

how fancybox textbox value after closing fancybox...i have tried this

'onstart' : function(){ x = $('#fancybox-frame').contents().find('#comment_count').val(); alert(x); }, 'onclosed': function(){ x = $('#fancybox-frame').contents().find('#comment_count').val(); alert(x); }

and iam declaring var x @ top of script displayng undefined both times....can suggest me right way

onclosed executed when fancybox content has removed gives undefined.use oncleanup able give value of x after closing fancybox .

"oncleanup": function(){ x = $('#fancybox-frame').contents().find('#comment_count').val(); alert(x); }, "onclosed": function(){ x = $('#fancybox-frame').contents().find('#comment_count').val(); //opt alert(x); //opt }

jquery

No comments:

Post a Comment