Reputation: 23230
I'm new to JS and am writing a notification plug-in. Currently I'm calling this plug-in like so:
$.notifyBar({
cls: "error",
html: "message"
});
By default it stays for 2 seconds and disappears. What I want to do is, if delay set to 0, then notifybar will not disappear automatically. I want it to disappear it programmatically, in ajax success function. How can I modify this plug-in to realize my idea?
Upvotes: 0
Views: 309
Reputation: 27637
You can just set the delay
very high:
$.notifyBar({
cls: "error",
html: "message"
});
And then close the bar with:
$(".jquery-notify-bar").slideUp();
Upvotes: 2