msgbox("我是一个提示框");
msgbox("我是一个提示框","主席发来贺电!");
msgbox("我是一个提示框",{ buttons: [ {type: "button", value: "确定", style : 'primary'}, {type: "button", value: "取消", style : 'secondary'}, {type: "button", value: "终止", style : 'danger'}, ], } );
msgbox("我是一个提示框",{ buttons: [ {type: "button", value: "确定", style : 'primary'}, {type: "button", value: "取消", style : 'secondary'}, {type: "button", value: "终止", style : 'danger'}, ], }, function(text){ if(text === "确定"){ alert("你按下了确定"); }else if(text === "取消"){ alert("你按下了取消"); }else if(text === "终止"){ alert("你按下了终止"); } } );
msgbox("我是一个提示框",{ inputs : [ {type: "text", label: "用户名:", value: "George"}, {type: "password", label: "密码:"} ], buttons : [ {type: "button", value: "确定", style : 'primary'}, {type: "button", value: "取消", style : 'secondary'}, {type: "button", value: "终止", style : 'danger'}, ], }, function(text){ if(text === "确定"){ alert("你按下了确定"); }else if(text === "取消"){ alert("你按下了取消"); }else if(text === "终止"){ alert("你按下了终止"); } } );
msgbox("我是一个提示框",{ inputs : [ {type: "text", label: "用户名:", value: "George"}, {type: "password", label: "密码:"} ], buttons : [ {type: "button", value: "确定", style : 'primary'}, {type: "button", value: "取消", style : 'secondary'}, ], }, function(text, value1, value2){ if(text === "确定"){ msgbox("输入数据
第一个表单值:" + value1 + "
第二个表单值:" + value2); }else if(text === "取消"){ alert("你按下了取消"); } } );
msgbox("",{ buttons : null, // 删除默认按钮 remote : 'https://www.tianlunvip.com/demo/remote.html' } );