Simple Modal on a hidden div

Cav*_*rob 2 html jquery simplemodal jquery-plugins visible

I want to have a hidden div on the page with the elements of a SimpleModal dialogue, but when I set the CSS visibility to hidden and fire the modal, it is empty.

How can I use a DIV in this fashion without making it visible on the page?

Nic*_*ver 5

而不是visibility: hidden;你想要的是什么display: none;.大多数的jQuery插件工作过display,而不是visibility(与显示/隐藏做到这一点更是jQuery核心功能).

SimpleModal(以及我所知道的所有其他jQuery模式)display: none在显示模态时会反转......他们实际上期待这个:)