1 |
1 2 3 4 5 6 7 | btn_Close: true , //关闭按钮 btn_Max: true , //最大化按钮 btn_Refresh: true , //刷新按钮 btn_NewWindow: true , //新窗口按钮 resize: true //调整窗口大小按钮 }}); |
1 2 | var tempelem = $( "<div style=" \"margin:50px " auto;width:80%;height:300px;border:1px=" " solid=" " #ddd;\"=" ">这是在测试</div>" ); $.NZ_Window.show({content:tempelem,width:800,height:550}); |
1 2 3 4 5 | var tempelem = $( "<div style=" \"margin:50px " auto;width:80%;height:300px;border:1px=" " solid=" " #ddd;\"=" "><button class=" \"button\" " id=" \"btn4-1\" ">我能关闭这个窗口</button></div>" ); tempelem.find( ".button" ).click( function () { $.NZ_Window.close(windowid); }); var windowid = $.NZ_Window.show({ content: tempelem, width: 800, height: 550 }); |
1 2 3 4 | var windowid = $.NZ_Window.show({ alert( "你关闭了一个窗口" ); } }); |
1 2 3 4 | var windowid = $.NZ_Window.show({ alert( "你关闭了一个窗口" ); } }); |
1 | $.NZ_Window.show({ url: "https://www.w3school.com.cn" , width: 800, height: 550, style: { btnColor: "white" , titleBarColor: "#373737" },title: "一个个性化标题栏" }); |
1 2 3 4 5 6 7 8 9 10 11 12 13 | $.ajax({ type: "get" , url: "/localdata/showcontent.json" , dataType: "json" , success: function (data) { $.NZ_Window.show({ content: unescape(data.con), type: 1 }); }, error: function (error) { alert(error.responeseText); } }); |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | { content: null , //动态对象内容 url: null , //链接 title: "" , //标题 type: 0, //0:普通窗口,1:不带标题栏的特殊窗口 width: 600, //宽度 height: 350, //高度 maximize: false , //是否最大化显示 scrollbar: { //滚动条设置 x: false , y: true }, operate: { //操作按钮显示控制 btn_Close: true , //关闭按钮 btn_Max: true , //最大化按钮 btn_Refresh: false , //刷新按钮 btn_NewWindow: false , //新窗口按钮 resize: true //调整窗口大小按钮 } , style: { //个性化样式 btnColor: "black" , //按钮风格:black/white titleBarColor: "" , //标题栏背景颜色 bgColor: "#111" //遮罩背景颜色 } , callback: null //回调 } |