Skip to content

Commit b322705

Browse files
committed
Support jquery object content for type html
You can hide the dom element first, it will show in msgbox
1 parent dd3b77b commit b322705

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

jquery.msgbox.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -616,7 +616,8 @@
616616

617617
case 'html':
618618
case 'confirm':
619-
this.$loaded.html(this.options.content).appendTo(this.$content);
619+
var content = $.type(this.options.content)==='object' ? this.options.content.show() : this.options.content;
620+
this.$loaded.html(content).appendTo(this.$content);
620621
this.loaded = true;
621622
if (callback) callback.apply(this);
622623
if (this.options.onLoad) this.options.onLoad.apply(this);

0 commit comments

Comments
 (0)