⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 edit_xinxi.asp

📁 信息类网站的不错选择
💻 ASP
字号:
<!--#include file="conn1.asp"-->
<!--#include file="err.asp"-->
<!--#include file=usercookies.asp-->
<!--#include file="config.asp"-->
<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 6.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title><%=title%>-信息修改</title>
<link href="inc_style.css" rel="stylesheet" type="text/css">
</head>

<body topmargin="0">
<!--#include file=top.asp-->
<div align="center">
  <center>
  <table border="0" cellpadding="0" style="border-collapse: collapse" bordercolor="#111111" width="760" height="428">

    <tr>
      <td width="157" height="356" valign="top"><br>
      <!--#include file=userleft.asp--></td>
      <td width="10" height="356" background="images/line_01.gif"> </td>
      <td width="603" height="356" valign="top"> <div align="center">
        <center>
            <table width="489" border="0" cellspacing="0" cellpadding="0" style="border-collapse: collapse" bordercolor="#111111">
              <form action="edit_xinxichk.asp" name="myform" method="POST">
                <tr> 
                <td width="16">
                <img src="images/obj_waku3_01.gif"></td>
                <td width="497">
                <img src="images/ba_home.gif"></td>
                <td width="17">
                <img src="images/obj_waku3_02.gif"></td>
              </tr>
              <tr> 
                <td width="16" background="images/obj_waku3_03.gif">
                 </td>
                <td bgcolor="#EEEEEE">
                  <table border="0" cellpadding="0" style="border-collapse: collapse">
                    
                    <tr> 
                      <td height="21" bgcolor="#EEEEEE" colspan="2">
                      <p align="center">修改信息</td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      信息类别:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
<%
dim rs,sql,i,count,username,qq,id,class1,biaoti,leixing,jiage,diqu,memo,name,email,dianhua,acount
id=trim(request("id"))
username=request.cookies("cnmai")("username")
set rs=server.createobject("adodb.recordset")
sql = "select * from xinxi where username='"&username&"' and id="&cstr(id)
rs.open sql,conn,1,1
if rs.eof then
errcnmai(0)
response.end
end if
class1=rs("class1")
biaoti=rs("biaoti")
leixing=rs("leixing")
jiage=rs("jiage")
diqu=rs("diqu")

memo=rs("memo")
name=rs("name")
email=rs("email")
dianhua=rs("dianhua")
qq=rs("qq")
rs.close



%>
<SCRIPT language=javascript>
<!--
function CheckForm()
{
if(document.myform.biaoti.value.length<1)
	{
	    alert("信息标题没有填写!");
	    return false;
	}
if(document.myform.jiage.value.length<1)
	{
	    alert("价格填写不正确!");
	    return false;
	}

if(document.myform.diqu.value=="0"  || document.myform.diqu.value=="")
	{
	    alert("交易一级地区没有填写!");
	    return false;
	}
if(document.myform.memo.value.length<1)
	{
	    alert("信息内容没有填写!");
	    return false;
	}


if(document.myform.name.value.length<1)
	{
	    alert("联系人姓名没有填写!");
	    return false;
	}
if(document.myform.dianhua.value.length<1)
	{
	    alert("联系电话没有填写!");
	    return false;
	}
}
//-->
</SCRIPT>





<%
sql = "select * from class1 order by paixu desc"
rs.open sql,conn,1,1
if rs.eof and rs.bof then
response.write "请先添加分类。"
response.end
else
%>
<SELECT name="class1" onChange="changelocation(document.myform.class1.options[document.myform.class1.selectedIndex].value)" size="1">
	<OPTION value="0">==分类==</OPTION>
	<%do while not rs.eof%>
	<OPTION  <%if trim(class1)=cstr(rs("id")) then%>selected<%end if%>  value="<%=trim(rs("id"))%>"><%=trim(rs("class1"))%></OPTION>
        <%
        rs.movenext
        loop
	    end if
        rs.close
        %>
</SELECT>
<input type="hidden" name="id" size="7" maxlength="6" value="<%=id%>"></td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      信息标题:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <input type="text" maxlength="40" name="biaoti" size="35" value="<%=biaoti%>">(<font color="#CC5200">40字以内</font>)</td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      交易类型:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <select name="leixing">
 <%
dim rslx,sqllx
set rslx=server.createobject("adodb.recordset")
sqllx="select * from [leixing] "
rslx.open sqllx,conn,1,1
do while not rslx.eof

%>
                      
 <option <%if leixing=rslx("id") then%>selected<%end if%> value=<%=rslx("id")%>><%=rslx("leixing")%></option>
                      
                    
<%rslx.movenext
loop
rslx.close
set rslx=nothing
%>
                      </select></td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      价&nbsp;&nbsp;&nbsp; 格:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <input type="text" name="jiage" size="12" maxlength="6" value="<%=jiage%>"> 
                      元 (<font color="#CC5200">建议写清楚有关价格方面的信息,</font>0<font color="#CC5200">元表示面议</font>)</td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      交易地区:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399"> 
                    <input type="text" maxlength="40" name="diqu" size="35" value="<%=diqu%>"></td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      <p>信息说明:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <textarea rows="15" name="memo" cols="62"><%=memo%></textarea></td>
                    </tr>
<%
sql = "select * from [user] where username='"&username&"'"
rs.open sql,conn,1,1
if rs.eof then
errcnmai(9)
response.end
end if
%>
                    <tr>
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      联系人:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <input type="text" name="name" size="23" maxlength="20" value="<%=name%>"></td>
                    </tr>
                    <tr>
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      联系电话:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <input type="text" name="dianhua" size="23" maxlength="40" value="<%=dianhua%>"></td>
                    </tr>
                    <tr>
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      QQ或MSN:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <input type="text" name="qq" size="23" maxlength="40" value="<%=qq%>"></td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      email:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      <input type="text" name="email" size="23" maxlength="40" value="<%=email%>">(<font color="#CC5200">该邮件地址将接收你的交易信息</font>)</td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      联系地址:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      	<input type="text" name="dizhi" size="54" maxlength="54" value="<%=rs("dizhi")%>"></td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" width="100" align="right">
                      发布天数:</td>
                      <td height="25" bgcolor="#EEEEEE" width="399">
                      	<select name="days" size="1">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7" selected>7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
<option value="13">13</option>
<option value="14">14</option>
<option value="15">15</option>
<option value="16">16</option>
<option value="17">17</option>
<option value="18">18</option>
<option value="19">19</option>
<option value="20">20</option>
<option value="21">21</option>
<option value="22">22</option>
<option value="23">23</option>
<option value="24">24</option>
<option value="25">25</option>
<option value="26">26</option>
<option value="27">27</option>
<option value="28">28</option>
<option value="29">29</option>
<option value="30">30</option>
<option value="60">两个月</option>
<option value="90">三个月</option>
<option value="180">半年</option>
<option value="360">一年</option>
<option value="88888">长期</option>
</select> 天</td>
                    </tr>
                    <tr> 
                      <td height="25" bgcolor="#EEEEEE" colspan="2">
                      <p align="center">
                      <input border="0" onClick="javascript:return CheckForm();" src="images/Login_but.gif" name="I2" type="image"></td>
                    </tr>
                    <tr> 
                      <td height="20" bgcolor="#EEEEEE" colspan="2">
                      <p align="left"> </td>
                    </tr>
                  </table>
                </td>
                <td width="17" background="images/obj_waku3_04.gif">
                 </td>
              </tr>
              <tr> 
                <td width="16">
                <img src="images/obj_waku3_05.gif"></td>
                <td width="497">
                <img src="images/obj_waku3_06.gif"></td>
                <td width="17">
                <img src="images/obj_waku3_07.gif"></td>
              </tr>
              </form>
            </table>  
        </center>
      </div></td>
      <td width="8" height="356" background="images/line_01.gif"> </td>
    </tr><!--#include file=end.htm-->
  </table>
  </center>
</div>
</body>
</html>
<%
rs.close
set rs=nothing
closedb
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -