All,
How to close and open a jgrowl manually
jQuery("div.jGrowl").trigger("jGrowl.close");
The above code doesnt seem to work.
Thanks.
This worked for me
$("div.jGrowl").jGrowl("close");
Three options:
$('div.jGrowl').find('div.jGrowl-notification').children().parent().remove();
$('div.jGrowl').find('div.jGrowl-notification').trigger('jGrowl.close');
$('div.jGrowl').find('.jGrowl-close').trigger('jGrowl.close');
Any of them close all notifications. I'm not sure how to close an individual notification, though.
This one worked for me, closing the last notification:
$('div.jGrowl-close').triggerHandler('click');
Edit: Improved efficiency by replacing trigger with triggerHandler. See http://api.jquery.com/triggerHandler/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With