
正文
使用ymPrompt弹框
提示:扫一扫查出行【扫一扫了解最新限行尾号】
复制提示
使用弹框
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%><%@ taglib prefix="s" uri="/struts-tags" %><%String path = request.getContextPath();String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html> <head> <base href="<%=basePath%>"> <title>My JSP 'systemConfig-list.jsp' starting page</title> <script type="text/javascript" src="${pageContext.request.contextPath }/js/jquery-1.8.3.min.js"></script> <script type="text/javascript" src="${pageContext.request.contextPath }/js/ymPrompt.js"></script> <link rel="stylesheet" id='skin' type="text/css" href="${pageContext.request.contextPath }/alertframe/skin/simple_gray/ymPrompt.css" /> <style type="text/css"> #table{ width:960px; margin-left:auto; margin-right:auto; } #table:first-child{ border-collapse: collapse; border:1px solid #c4c4c4; width: 960px; cellspacing:"0"; cellpadding:"0"; line-height: 28px; height: 28px; text-align: center; } #table tr:first-child{ background-color:#efefef; } td{ border:1px solid #c4c4c4; font-size: 12px; } .message { font:18px; text-align:center; padding:25px; } </style> <script type="text/javascript"> function deleteSystemconfig(){ ymPrompt.win({ width:240, height:145, icoCls: '', message:'<div class="message">您确定要删除【'+$("#tdvalue").val()+'】配置吗?</div>', titleBar:false, winPos:'c', btn:[['OK'],['Cancel']], handler:getButtons }); function getButtons(btn){ //拿到按钮的值 //删除行 var path = $("#path").val(); var id = $("#id").val(); window.location.href = path+"/deleteSystemconfig.action?id="+id; } } </script> <meta http-equiv="pragma" content="no-cache"> <meta http-equiv="cache-control" content="no-cache"> <meta http-equiv="expires" content="0"> <meta http-equiv="keywords" content="keyword1,keyword2,keyword3"> <meta http-equiv="description" content="This is my page"> <!-- <link rel="stylesheet" type="text/css" href="styles.css"> --> </head> <body> <div> <input type="button" value="demo" onclick="Open()" /> <form> <!-- <input type="button" value="添加账户类型"> --> <table id="table"> <tr> <th width="120px">序号</th> <th width="310px">配置类型</th> <th width="225px">是否启用</th> <th width="294px">操作</th> </tr> <s:iterator value="systemconfigs" status="status"> <tr> <td><s:property value="id"/></td> <td><s:property value="configTypeName"/></td> <td> <s:if test="isStart == 1">启用</s:if> <s:else>不启用</s:else> </td> <td> <a href="#">修改</a> | <a href="javascript:void(0);" onclick="deleteSystemconfig();">删除</a> <input type="hidden" id="tdvalue" value="<s:property value='configTypeName'/>"> <input type="hidden" id="id" value="<s:property value='id'/>"> <input type="hidden" id="path" value="${pageContext.request.contextPath }"/> </td> </tr> </s:iterator> </table> </form> </div> </body></html>







