?? kehu_add.asp
字號:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file=DataBase/conn.asp-->
<!--#include file=config.asp-->
<!--#include file=purview.asp-->
<%
call client
if request("post")<>"" then
set rs=server.CreateObject("adodb.recordset")
sql="select * from tb_Client"
rs.open sql,conn,1,3
rs.addnew
rs("ClientName")=request("ClientName")
rs("ClientAddress")=request("ClientAddress")
rs("ClientTel")=request("ClientTel")
rs("ClientFax")=request("ClientFax")
rs("ClientNumber")=request("ClientNumber")
rs("ClientPage")=request("ClientPage")
rs("ClientEmail")=request("ClientEmail")
rs("ClientCountry")=request("ClientCountry")
rs("ClientHabitude")=request("ClientHabitude")
rs("ClientSize")=request("ClientSize")
rs("ClientCity")=request("ClientCity")
rs("ClientPay")=request("ClientPay")
rs("ClientCredit")=request("ClientCredit")
rs("ClientList")=request("ClientList")
rs("ClientYear")=request("ClientYear")
rs("ClientCyc")=request("ClientCyc")
rs("SetTime")=now()
rs("EditTime")=now()
rs("SetName")=session("admin_name")
rs.update
rs.close
conn.close
response.Write("<script language=javascript>alert('客戶信息添加成功')</script>")
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>無標(biāo)題文檔</title>
<style type="text/css">
<!--
body {
background-color: #DFEEFF;
}
body,td,th {
font-size: 12px;
}
-->
</style>
<link href="css/css.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style1 {font-weight: bold}
-->
</style>
</head>
<script language="javascript">
function checks()
{
if(form1.ClientName.value=="")
{
alert("公司名稱不能為空");
return false;
}
else if(form1.ClientTel.value=="")
{
alert("公司電話不能為空");
return false;
}
else if(form1.ClientAddress.value=="")
{
alert("公司地址不能為空");
return false;
}
else if(form1.ClientCountry.value=="")
{
alert("國家地區(qū)不能為空");
return false;
}
else if(form1.ClientCity.value=="")
{
alert("所在城市不能為空");
return false;
}
else if(form1.ClientCity.value=="")
{
alert("E-mail不能為空");
return false;
}
else if(form1.ClientFax.value=="")
{
alert("公司傳真不能為空");
return false;
}
else if(form1.ClientNumber.value=="")
{
alert("公司郵政編碼不能為空");
return false;
}
else if(form1.ClientPage.value=="")
{
alert("公司網(wǎng)址不能為空");
return false;
}
else if(form1.ClientList.value=="")
{
alert("最高訂單不能為空");
return false;
} else if(form1.ClientYear.value=="")
{
alert("年度訂單不能為空");
return false;
}
else if(form1.ClientCyc.value=="")
{
alert("需求周期不能為空");
return false;
}
}
</script>
<body >
<form name="form1" method="post" action="">
<fieldset class="fiedset">
<legend>添加客戶信息</legend>
<table width="970" border="0" align="center" cellspacing="0" bgcolor="#FFFFFF" class="table">
<tr>
<td width="18%" height="30" align="right">公司名稱:</td>
<td colspan="3" ><input name="ClientName" type="text" class="in" id="ClientName" size="30">
<input name="post" type="hidden" id="post" value="true"></td>
<td width="7%" align="right">公司電話:</td>
<td colspan="3"><input name="ClientTel" type="text" class="in" id="ClientTel" size="30"></td>
</tr>
<tr>
<td height="30" align="right">公司地址:</td>
<td colspan="3"><input name="ClientAddress" type="text" class="in" id="ClientAddress" size="30"></td>
<td align="right">國家地區(qū):</td>
<td colspan="3"><input name="ClientCountry" type="text" class="in" id="ClientCountry" size="30"></td>
</tr>
<tr>
<td height="30" align="right">所在城市:</td>
<td colspan="3"><input name="ClientCity" type="text" class="in" id="ClientCity2" size="30"></td>
<td align="right">E-mail:</td>
<td colspan="3"><input name="ClientEmail" type="text" class="in" id="ClientEmail" size="30"></td>
</tr>
<tr>
<td height="30" align="right">公司傳真:</td>
<td colspan="3"><input name="ClientFax" type="text" class="in" id="ClientFax" size="30"></td>
<td align="right">郵政編碼:</td>
<td colspan="3"><input name="ClientNumber" type="text" class="in" id="ClientNumber" size="30" maxlength="6"></td>
</tr>
<tr>
<td height="30" align="right">公司網(wǎng)址:</td>
<td colspan="3"><input name="ClientPage" type="text" class="in" id="ClientPage2" size="30"></td>
<td align="right">最高訂單:</td>
<td colspan="3"><input name="ClientList" type="text" class="in" id="ClientList3" size="30"></td>
</tr>
<tr>
<td height="30" align="right">年度訂單:</td>
<td colspan="3"><input name="ClientYear" type="text" class="in" id="ClientYear2" size="30"></td>
<td align="right">需求周期:</td>
<td colspan="3"><input name="ClientCyc" type="text" class="in" id="ClientCyc2" size="30"></td>
</tr>
<tr>
<td height="30" align="right">公司規(guī)模:</td>
<td width="10%"><select name="ClientSize" id="ClientSize">
<option value="大">大</option>
<option value="中">中</option>
<option value="小">小</option>
</select></td>
<td width="7%" align="center">企業(yè)性質(zhì):</td>
<td width="20%"><select name="ClientHabitude" id="select">
<option value="外企">外企</option>
<option value="國企">國企</option>
<option value="民營">民營</option>
<option value="私營">私營</option>
</select></td>
<td align="right">結(jié)款方式:</td>
<td width="11%"><select name="ClientPay" id="ClientPay">
<option value="現(xiàn)金">現(xiàn)金</option>
<option value="支票">支票</option>
<option value="匯票">匯票</option>
</select></td>
<td width="8%" align="center">結(jié)款信用:</td>
<td width="19%"><select name="ClientCredit" id="select2">
<option>好</option>
<option>中</option>
<option>差</option>
</select></td>
</tr>
<tr align="center">
<td height="30" colspan="8"><input name="Submit" type="submit" class="input" value=" 添 加 " onClick="return checks()"></td>
</tr>
</table>
<table width="90%" height="5" border="0" align="center">
<tr>
<td></td>
</tr>
</table>
</fieldset>
</form>
</body>
</html>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -