?? edit.asp
字號:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK href="../css/Style.css" rel=stylesheet type=text/css>
<title>企業資料修改</title></head>
<%
if Request.Cookies("globalec")("globalecmaster")="" or Request.Cookies("globalec")("masterflag")="" then
response.write "<script language='javascript'>"
response.write"this.location.href='../login.asp';</SCRIPT>"
response.end
end if
if instr(Request.Cookies("globalec")("masterflag"),"21")=0 then
response.redirect "../err.asp"
response.end
end if
%>
<!--#include file="../../conn/conn.asp"-->
<!--#include file="../../inc/safe.asp"-->
<script Language="JavaScript">
function FormCheck()
{
if (trim(document.Form1.qymc.value) =="")
{
alert("請輸入公司全稱!");
document.Form1.qymc.focus();
return (false);
}
if (trim(document.Form1.p_z_Z_EmployeesCount.value) =="")
{
alert("請選擇公司員工人數!");
document.Form1.p_z_Z_EmployeesCount.focus();
return (false);
}
if (trim(document.Form1.p_z_Z_LegalStatus.value) =="")
{
alert("請選擇企業類型!");
document.Form1.p_z_Z_LegalStatus.focus();
return (false);
}
var check=true;
for(var i=0;i<document.Form1.qylb.length;i++){
if (document.Form1.qylb[i].checked) {
check=false;
break;
}
}
if (check){
alert("請選擇企業經營模式!");
document.Form1.qylb[0].focus();
return (false);
}
if (trim(document.Form1.p_z_Z_AnnualRevenue.value) =="")
{
alert("請選擇企業年營業額!");
document.Form1.p_z_Z_AnnualRevenue.focus();
return (false);
}
if(trim(document.Form1.productionService.value) == "")
{
alert("主要相關產品名/服務名最少要填一個\n\n并且按左至右的順序填寫");
document.Form1.productionService.focus();
return (false);
}
if (trim(document.Form1.p_z_Z_FoundedPlace.value) =="")
{
alert("請填寫公司注冊地!");
document.Form1.p_z_Z_FoundedPlace.focus();
return (false);
}
if (trim(document.Form1.p_z_Z_BizPlace.value) =="")
{
alert("請填寫主要經營地點!");
document.Form1.p_z_Z_BizPlace.focus();
return (false);
}
if (trim(document.Form1.qyjj.value.length) <50)
{
alert("公司介紹不能少于50字");
document.Form1.qyjj.focus();
return (false);
}
if (trim(document.Form1.qyjj.value.length) >2000)
{
alert("公司介紹不能多于2000字");
document.Form1.qyjj.focus();
return (false);
}
if (trim(document.Form1.phonecountry.value) =="")
{
alert("請輸入聯系電話的國家區號!");
document.Form1.phonecountry.focus();
return (false);
}
var filter=/^\s*[0-9]{0,3}\s*$/;
if (!filter.test(document.Form1.phonecountry.value)) {
alert("國家區號不正確,請重新填寫!不超過3個數字,注意不要使用空格。");
document.Form1.phonecountry.focus();
document.Form1.phonecountry.select();
return false;
}
if (trim(document.Form1.phonearea.value) =="")
{
alert("請輸入聯系電話的城市區號!");
document.Form1.phonearea.focus();
return (false);
}
var filter=/^\s*[0-9]{0,4}\s*$/;
if (!filter.test(document.Form1.phonearea.value)) {
alert("城市區號不正確,請重新填寫!不超過4個數字,注意不要使用空格。");
document.Form1.phonearea.focus();
document.Form1.phonearea.select();
return false;
}
if (trim(document.Form1.phonenumber.value) =="")
{
alert("請輸入您的聯系電話號碼!");
document.Form1.phonenumber.focus();
return (false);
}
if (trim(document.Form1.country1.value) =="中國")
{
if (trim(document.Form1.province.value) =="")
{
alert("請選擇省份!");
document.Form1.province.focus();
return (false);
}
if (trim(document.Form1.city.value) =="")
{
alert("請選擇地級城市!");
document.Form1.city.focus();
return (false);
}
}
if (trim(document.Form1.address.value) =="")
{
alert("請輸入您的聯系地址!");
document.Form1.address.focus();
return (false);
}
if (trim(document.Form1.email.value) =="")
{
alert("請輸入您的電子郵件地址!");
document.Form1.email.focus();
document.Form1.email.select();
return false;
}
var str1 = document.Form1.email.value
if(str1.indexOf("@") == -1 || str1.indexOf(".") == -1){
alert("E-mail格式不正確,請重新填寫!");
document.Form1.email.focus();
document.Form1.email.select();
return false;
}
var productionService = Form1.productionService.value;
for(i=0;i<productionService.length;i++){productionService=productionService.replace(',',',');}
if(Form1.productionService2.value){
for(i=0;i<Form1.productionService2.value.length;i++){Form1.productionService2.value=Form1.productionService2.value.replace(',',',');}
productionService+=','+Form1.productionService2.value;
}
if(Form1.productionService3.value){
for(i=0;i<Form1.productionService3.value.length;i++){Form1.productionService3.value=Form1.productionService3.value.replace(',',',');}
productionService+=','+Form1.productionService3.value;
}
Form1.p_z_Z_productionService.value = productionService
document.Form1.submit()
}
//-->
//-->
function trim(inputString) {
if (typeof inputString != "string") { return inputString; }
var retValue = inputString;
var ch = retValue.substring(0, 1);
while (ch == " ") {
//檢查字符串開始部分的空格
retValue = retValue.substring(1, retValue.length);
ch = retValue.substring(0, 1);
}
ch = retValue.substring(retValue.length-1, retValue.length);
while (ch == " ") {
//檢查字符串結束部分的空格
retValue = retValue.substring(0, retValue.length-1);
ch = retValue.substring(retValue.length-1, retValue.length);
}
while (retValue.indexOf(" ") != -1) {
//將文字中間多個相連的空格變為一個空格
retValue = retValue.substring(0, retValue.indexOf(" ")) + retValue.substring(retValue.indexOf(" ")+1, retValue.length);
}
return retValue;
}
//-->
</script>
<%
if Chkrequest(request("id")) then
id=request("id")
else
Response.Redirect ("/login/chklogin.asp?login=4")
end if
dim sql
dim rs
sql="select * from corporation where id="&id
Set rs= Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,1,1
zycp=rs("zycp")
pharry=split(rs("phone")," ")
faarry=split(rs("fax")," ")
%>
<table cellpadding="2" cellspacing="1" border="0" width="95%" class="tableBorder" align=center>
<tr>
<th align=center colspan=8 height=23>用戶資料管理</th>
</tr>
<tr>
<td width=9% class=forumrowHighlight>注意事項</td>
<td width=91% class=forumrowHighlight colspan=7><li>刪除按鈕將刪除所選定的用戶全部相關信息,此操作是不可逆的;</td>
</tr>
</table>
<br>
<form method="post" action="save.asp?id=<%=request("id")%>" name="Form1">
<table cellpadding="2" cellspacing="1" border="0" width="95%" class="tableBorder" align=center>
<tr>
<th align=left height=23>公司檔案</th>
</tr>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -