codecamp

showDialog() 显示对话框

showDialog() 显示对话框


function showDialog(msg, mode, t, func, cover, funccancel, leftmsg, confirmtxt, canceltxt, closetime, locationtime)



key

默认值

含义

可选值及解释

msg

(必填)

提示信息内容

 

mode

'alert'

对话框模式

alert/right:有确定按钮

confirm:有确定和取消按钮

notice:有确定按钮

info:没有按钮

t

'提示信息'

对话框标题

 

func

 

点"确定"执行的函数

 

cover

1 (mode = 'info' 时为 0)

是否显示一个遮罩覆盖整个页面

1:是

0:否

funccancel

 

点"取消"执行的函数

 

leftmsg

 

底部左侧信息

 

confirmtxt

'确定'

确定按钮的文字

 

canceltxt

'取消'

取消按钮的文字

 

closetime

 

自动关闭的时间,单位"秒"

leftmsg 强制更改为"n 秒后窗口关闭"

 

locationtime

 

自动跳转时间,单位"秒"

leftmsg 强制更改为"n 秒后页面跳转"

jaxpost() AJAX/POST请求(提交数据)
​showWindow() AJAX弹窗
温馨提示
下载编程狮App,免费阅读超1000+编程语言教程
取消
确定
目录

Dzz系统框架

输入数据处理

数据DB层

安全相关

上传组件

评论组件

关闭

MIP.setData({ 'pageTheme' : getCookie('pageTheme') || {'day':true, 'night':false}, 'pageFontSize' : getCookie('pageFontSize') || 20 }); MIP.watch('pageTheme', function(newValue){ setCookie('pageTheme', JSON.stringify(newValue)) }); MIP.watch('pageFontSize', function(newValue){ setCookie('pageFontSize', newValue) }); function setCookie(name, value){ var days = 1; var exp = new Date(); exp.setTime(exp.getTime() + days*24*60*60*1000); document.cookie = name + '=' + value + ';expires=' + exp.toUTCString(); } function getCookie(name){ var reg = new RegExp('(^| )' + name + '=([^;]*)(;|$)'); return document.cookie.match(reg) ? JSON.parse(document.cookie.match(reg)[2]) : null; }