Some time ago in the Construction Bank project with ext complete a single page system, too rushed, did not record anything, now forget, blame pity. This project uses jquery to do JS stuff. The main use of a pop-up layer control Thickbox, I also expanded and modified a bit. Here to write down, also provide you to download, I hope to be useful to everyone.
Thickbox official website (with examples and basic methods of use): http://jquery.com/demo/thickbox/
In the course of my use, Thickbox frequently asked questions:
1. The pop-up layer across the IFRAME.
Symptom (s): Every time the Thickbox is only popped in a frame, it will not cover the entire screen.
Reasons and Solutions:
Thickbox uses the Tb_show () function to add a pop-up layer behind the body. You can use Window.top.tb_show () to add a pop-up layer to the page. My Tihickbox plugin is modified as follows: Replace Tb_show (T,A,G) with the following in Tb_init ()
if(a.indexOf ('TB_iniframe') != -1)
{
window.top.tb_show(t,a,g);
}
else
{
tb_show(t,a,g);
}
So just add tb_iniframe=true to the original link, such as div.aspx? Height=180&width=400&tb_iframe=true&tb_iniframe=true&modal=true
2.thickbox support only one layer of pop-up, can not support multi-layer pop-up.
The modified control has been supported (insufficient: invalid IE6 under the expiration of the failed pop-up layer, accounting for the time is not resolved, haha)