layer模態窗簡單使用


layer.open({
type: 1,//模態窗種類
skin: "layui-layer-rim",
title: "編輯信息",
area: ["400px", "500px"],
maxmin: true,
//拼接字符串自定義名稱
content: '<div><input type="text" name="Name"><input type="button" value="提交" onclick="add()" /></div>'
});


layer.open({
type: 2,//模態窗種類
skin: "layui-layer-rim",
title: "編輯信息",
area: ["400px", "500px"],
maxmin: true,
//拼接字符串自定義名稱
content: '/Student/Add'//要加載的頁面路徑
});

window.parent.location.reload();//關閉當前頁


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM