📄 webconfig.asp
字号:
<!--#include file="conn.asp"-->
<%if session("admin")="" then
response.Write "<script language='javascript'>alert('网络超时或您还没有登陆!');window.location.reload('login.asp')</script>"
response.End
else
if session("flag")>1 then
response.Write "<div align=center><font size=80 color=red><b>您没有此项目管理权限!</b></font></div>"
response.End
end if
end if
%>
<%dim action
action=request.QueryString("action")
'//保存信息
if action="save" then
set rs=server.CreateObject("adodb.recordset")
rs.Open "select webname,musicd,musicurl,webemail,dizhi,youbian,dianhua,copyright,weblogo,weburl,webbanner from shop_config ",conn,1,3
rs("webname")=trim(request("webname"))
rs("webemail")=trim(request("webemail"))
rs("dizhi")=trim(request("dizhi"))
rs("youbian")=trim(request("youbian"))
rs("dianhua")=trim(request("dianhua"))
rs("copyright")=trim(request("copyright"))
rs("weblogo")=trim(request("weblogo"))
rs("webbanner")=trim(request("webbanner"))
rs("weburl")=trim(request("weburl"))
rs("musicurl")=trim(request("musicurl"))
rs("musicd")=request("musicd")
rs.update
rs.close
set rs=nothing
response.Write "<script language=javascript>alert('网站资料修改成功!');window.location.reload('javascript:history.go(-1)')</script>"
end if%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../images/css.css" rel="stylesheet" type="text/css">
</head>
<body>
<table width="80%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#6B8FC8">
<tr>
<td height="16"><div align="center"><font color="#FFFFFF">网站信息设置</font></div></td>
</tr>
<tr>
<td height="107" bgcolor="#E8F1FF">
<table width="360" border="0" align="center" cellpadding="3" cellspacing="0">
<form name="form1" method="post" action="webconfig.asp?action=save">
<%set rs=server.CreateObject("adodb.recordset")
rs.Open "select webname,musicurl,musicd,webemail,dizhi,youbian,dianhua,copyright,weblogo,weburl,webbanner from shop_config",conn,1,1%>
<tr>
<td>书店网址:</td>
<td>HTTP://
<input name="weburl" type="text" id="weburl" size="21" value="<%=trim(rs("weburl"))%>"></td>
</tr>
<tr>
<td width="70">书店名称:</td>
<td width="278"> <input name="webname" type="text" id="webname" size="28" value="<%=trim(rs("webname"))%>">
</td>
</tr>
<tr>
<td width="70">书店Email:</td>
<td width="278"> <input name="webemail" type="text" id="webemail" size="28" value="<%=trim(rs("webemail"))%>">
</td>
</tr>
<tr>
<td width="70">公司地址:</td>
<td width="278"> <input name="dizhi" type="text" id="dizhi" size="28" value="<%=trim(rs("dizhi"))%>">
</td>
</tr>
<tr>
<td width="70">公司邮编:</td>
<td width="278"><input name="youbian" type="text" id="youbian" size="28" value="<%=trim(rs("youbian"))%>" onkeypress = "return regInput(this, /^[0-9]*$/, String.fromCharCode(event.keyCode))"
onpaste = "return regInput(this, /^[0-9]*$/, window.clipboardData.getData('Text'))"
ondrop = "return regInput(this, /^[0-9]*$/, event.dataTransfer.getData('Text'))"
> </td>
</tr>
<tr>
<td width="70">公司电话:</td>
<td width="278"> <input name="dianhua" type="text" id="dianhua" size="28" value="<%=trim(rs("dianhua"))%>">
</td>
</tr>
<tr>
<td width="70">书店版权:</td>
<td width="278"><input name="copyright" type="text" size="28" value="<%=trim(rs("copyright"))%>"></td>
</tr>
<tr>
<td height="22">书店Logo:</td>
<td height="22"><input name="weblogo" type="text" id="weblogo" size="28" value="<%=trim(rs("weblogo"))%>"></td>
</tr>
<tr>
<td height="22">Banner:<br>
Flash地址</td>
<td height="22"><input name="webbanner" type="text" id="webbanner" size="28" value="<%=trim(rs("webbanner"))%>"></td>
</tr>
<tr>
<td height="22">首页音乐:</td>
<td height="22"><%select case rs("musicd")
case 1%><input name="musicd" type="radio" value="1" checked>打开
<input type="radio" name="musicd" value="0">关闭
<%case 0%>
<input name="musicd" type="radio" value="1" >打开
<input type="radio" name="musicd" value="0" checked>关闭
<%end select%></td>
</tr>
<tr>
<td height="22">音乐地址:</td>
<td height="22"><input name="musicurl" type="text" id="musicurl" size="36" value="<%=trim(rs("musicurl"))%>"></td>
</tr>
<tr>
<td height="22" colspan="2"><div align="center">
<input type="submit" name="Submit" value="提 交">
<input type="reset" name="Submit2" value="恢 复">
</div></td>
</tr>
</form>
</table><%rs.Close
set rs=nothing%>
</td>
</tr>
</table>
<br>
<table width="80%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#6B8FC8">
<tr>
<td bgcolor="#6B8FC8"><div align="center"><font color="#FFFFFF">操作注意事项及说明</font></div></td>
</tr>
<tr>
<td bgcolor="#E8F1FF"><table width="80%" border="0" align="center" cellpadding="5" cellspacing="0">
<tr>
<td height="16"><font color="#FF0000">·请注意分类名称不要含有非法字符。<br>
·Logo的长和宽为170(左右)*60,Flash Banner的长和宽是468*60。<br>
</font></td>
</tr>
</table></td>
</tr>
</table>
</body>
</html>
<script>
function regInput(obj, reg, inputStr)
{
var docSel = document.selection.createRange()
if (docSel.parentElement().tagName != "INPUT") return false
oSel = docSel.duplicate()
oSel.text = ""
var srcRange = obj.createTextRange()
oSel.setEndPoint("StartToStart", srcRange)
var str = oSel.text + inputStr + srcRange.text.substr(oSel.text.length)
return reg.test(str)
}
</script>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -