|
作者: bailove [bailove] 论坛用户 | 登录 |
第二个是,分页函数出了什么问题,还有这个过滤是怎么一会事啊。那里出错了? 在评论中的email,fangshi.只能添入数字。其他了就会说 还没有填入 <!--#include file="conn.asp"--> <!--#include file="format.asp"--> <!--#include file="member/error.asp"--> <!--#include file="config.asp"--> <% ' *** Edit Operations: declare variables MM_editAction = CStr(Request("URL")) If (Request.QueryString <> "") Then MM_editAction = MM_editAction & "?" & Request.QueryString End If ' boolean to abort record edit MM_abortEdit = false ' query string to execute MM_editQuery = "" ' *** Insert Record: set variables If (CStr(Request("MM_insert")) <> "") Then MM_editConnection = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("admin/data.mdb") MM_editTable = "d_remark" MM_editRedirectUrl = "changedetail.asp" MM_fieldsStr = "remarker|value|remark|value|email|value|fangshi|value|haved_id|value" MM_columnsStr = "remarker|',none,''|remark|',none,''|email|',none,''|fangshi|',none,''|haved_id|none,none,NULL" ' create the MM_fields and MM_columns arrays MM_fields = Split(MM_fieldsStr, "|") MM_columns = Split(MM_columnsStr, "|") ' set the form values For i = LBound(MM_fields) To UBound(MM_fields) Step 2 MM_fields(i+1) = CStr(Request.Form(MM_fields(i))) Next ' append the query string to the redirect URL If (MM_editRedirectUrl <> "" And Request.QueryString <> "") Then If (InStr(1, MM_editRedirectUrl, "?", vbTextCompare) = 0 And Request.QueryString <> "") Then MM_editRedirectUrl = MM_editRedirectUrl & "?" & Request.QueryString Else MM_editRedirectUrl = MM_editRedirectUrl & "&" & Request.QueryString End If End If End If ' *** Insert Record: construct a sql insert statement and execute it If (CStr(Request("MM_insert")) <> "") Then ' create the sql insert statement MM_tableValues = "" MM_dbValues = "" For i = LBound(MM_fields) To UBound(MM_fields) Step 2 FormVal = MM_fields(i+1) MM_typeArray = Split(MM_columns(i+1),",") Delim = MM_typeArray(0) If (Delim = "none") Then Delim = "" AltVal = MM_typeArray(1) If (AltVal = "none") Then AltVal = "" EmptyVal = MM_typeArray(2) If (EmptyVal = "none") Then EmptyVal = "" If (FormVal = "") Then FormVal = EmptyVal Else If (AltVal <> "") Then FormVal = AltVal ElseIf (Delim = "'") Then ' escape quotes FormVal = "'" & Replace(FormVal,"'","''") & "'" Else FormVal = Delim + FormVal + Delim End If End If If (i <> LBound(MM_fields)) Then MM_tableValues = MM_tableValues & "," MM_dbValues = MM_dbValues & "," End if MM_tableValues = MM_tableValues & MM_columns(i) MM_dbValues = MM_dbValues & FormVal Next MM_editQuery = "insert into " & MM_editTable & " (" & MM_tableValues & ") values (" & MM_dbValues & ")" If (Not MM_abortEdit) Then ' execute the insert Set MM_editCmd = Server.CreateObject("ADODB.Command") MM_editCmd.ActiveConnection = MM_editConnection MM_editCmd.CommandText = MM_editQuery MM_editCmd.Execute MM_editCmd.ActiveConnection.Close If (MM_editRedirectUrl <> "") Then Response.Redirect(MM_editRedirectUrl) End If End If End If %> <HTML><HEAD><TITLE>东南车网---二手车详细消息</TITLE> <META http-equiv=Content-Type content="text/html; charset=gb2312"> <LINK href="../新建文件夹/mai.files/css.css" type=text/css rel=stylesheet> <SCRIPT language=JavaScript type=text/JavaScript> <!-- function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } //--> </SCRIPT> <script language="JavaScript" type="text/JavaScript"> <!-- function MM_findObj(n, d) { //v4.01 var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n]; for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); if(!x && d.getElementById) x=d.getElementById(n); return x; } function YY_checkform() { //v4.66 //copyright (c)1998,2002 Yaromat.com var args = YY_checkform.arguments; var myDot=true; var myV=''; var myErr='';var addErr=false;var myReq; for (var i=1; i<args.length;i=i+4){ if (args[i+1].charAt(0)=='#'){myReq=true; args[i+1]=args[i+1].substring(1);}else{myReq=false} var myObj = MM_findObj(args[i].replace(/\[\d+\]/ig,"")); myV=myObj.value; if (myObj.type=='text'||myObj.type=='password'||myObj.type=='hidden'){ if (myReq&&myObj.value.length==0){addErr=true} if ((myV.length>0)&&(args[i+2]==1)){ //fromto var myMa=args[i+1].split('_');if(isNaN(myV)||myV<myMa[0]/1||myV > myMa[1]/1){addErr=true} } else if ((myV.length>0)&&(args[i+2]==2)){ var rx=new RegExp("^[\\w\.=-]+@[\\w\\.-]+\\.[a-z]{2,4}$");if(!rx.test(myV))addErr=true; } else if ((myV.length>0)&&(args[i+2]==3)){ // date var myMa=args[i+1].split("#"); var myAt=myV.match(myMa[0]); if(myAt){ var myD=(myAt[myMa[1]])?myAt[myMa[1]]:1; var myM=myAt[myMa[2]]-1; var myY=myAt[myMa[3]]; var myDate=new Date(myY,myM,myD); if(myDate.getFullYear()!=myY||myDate.getDate()!=myD||myDate.getMonth()!=myM){addErr=true}; }else{addErr=true} } else if ((myV.length>0)&&(args[i+2]==4)){ // time var myMa=args[i+1].split("#"); var myAt=myV.match(myMa[0]);if(!myAt){addErr=true} } else if (myV.length>0&&args[i+2]==5){ // check this 2 var myObj1 = MM_findObj(args[i+1].replace(/\[\d+\]/ig,"")); if(myObj1.length)myObj1=myObj1[args[i+1].replace(/(.*\[)|(\].*)/ig,"")]; if(!myObj1.checked){addErr=true} } else if (myV.length>0&&args[i+2]==6){ // the same var myObj1 = MM_findObj(args[i+1]); if(myV!=myObj1.value){addErr=true} } } else if (!myObj.type&&myObj.length>0&&myObj[0].type=='radio'){ var myTest = args[i].match(/(.*)\[(\d+)\].*/i); var myObj1=(myObj.length>1)?myObj[myTest[2]]:myObj; if (args[i+2]==1&&myObj1&&myObj1.checked&&MM_findObj(args[i+1]).value.length/1==0){addErr=true} if (args[i+2]==2){ var myDot=false; for(var j=0;j<myObj.length;j++){myDot=myDot||myObj[j].checked} if(!myDot){myErr+='* ' +args[i+3]+'\n'} } } else if (myObj.type=='checkbox'){ if(args[i+2]==1&&myObj.checked==false){addErr=true} if(args[i+2]==2&&myObj.checked&&MM_findObj(args[i+1]).value.length/1==0){addErr=true} } else if (myObj.type=='select-one'||myObj.type=='select-multiple'){ if(args[i+2]==1&&myObj.selectedIndex/1==0){addErr=true} }else if (myObj.type=='textarea'){ if(myV.length<args[i+1]){addErr=true} } if (addErr){myErr+='* '+args[i+3]+'\n'; addErr=false} } if (myErr!=''){alert('The required information is incomplete or contains errors:\t\t\t\t\t\n\n'+myErr)} document.MM_returnValue = (myErr==''); } //--> </script> <SCRIPT language=JavaScript> function frmLogin_submit() { if (document.frmLogin.user.value=='' ) { alert('请输入您的用户名!'); document.frmLogin.user.focus(); return false; } if (document.frmLogin.password.value=='' ) { alert('请输入您的密码!'); document.frmLogin.password.focus(); return false; } return true; } </SCRIPT> <SCRIPT language=javascript> function show_sader(mylink) { window.open(mylink,'','top=140,left=135,width=480,height=280,scrollbars=no ') } </SCRIPT> <SCRIPT language=javascript> function show_car(mylink) { window.open(mylink,'','top=0,left=0,width=550,height=500,scrollbars=yes ') } </SCRIPT> <META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD> <BODY> <SCRIPT language=javascript> function show_sader(mylink) { window.open(mylink,'','top=140,left=135,width=480,height=280,scrollbars=no') } </SCRIPT> <%sql="select * from haved where id="&cint(request.querystring("id")) set rs=server.createobject("adodb.recordset") rs.open sql,conn,1,1%> <TABLE height=95 cellSpacing=0 cellPadding=0 width=770 align=center border=0> <TBODY> <TR> <TD height=59> </TD></TR> <TR> <TD vAlign=bottom align=right background=../新建文件夹/mai.files/line.gif height=44> </TD></TR></TBODY></TABLE> <TABLE cellSpacing=0 cellPadding=0 width=760 align=center border=0> <TBODY> <TR> <TD vAlign=top width=225 height=126> </TD> <TD vAlign=top align=left width=543> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD height=30> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD> <A href="http://www.zj2car.com/change.asp">旧车交易</A>---><FONT color=#ff0000><% if rs("change")<> "卖" then response.write"买" else response.write"卖" end if%> </FONT>汽车介绍 </TD> <TD><INPUT onclick=javascript:history.go(-1) type=submit align=right value=返回 name=submit2></TD></TR></TBODY></TABLE></TD></TR> <TR> <TD background=../新建文件夹/mai.files/ve.gif height=1></TD></TR> <TR> <TD> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width=344 height=110 valign="top" align="center"> <DIV align=center> <table border="0" width="100%" cellspacing="1" id="table1"> <tr> <td align="center" valign="top"><% if rs("pic")<>"" then%> <img border="0" src="member/<%=rs("pic")%>" width="337" height="258" alt="点击放大"> <%else response.write" 请广大用户谨慎的选择交易对象,防止被骗和买到走私车" end if%> </td> </tr> <tr> <td> <table border="0" width="100%" cellspacing="0" cellpadding="0" id="table2"> <tr> <td width="112" valign="top"><% if rs("pic1")<>"" then%> <img border="0" src="member/<%=rs("pic1")%>" width="110" height="90"><%end if%></td> <td valign="top"><% if rs("pic2")<>"" then%> <img border="0" src="member/<%=rs("pic2")%>" width="110" height="90"><%end if%></td> <td valign="top"><% if rs("pic2")<>"" then%> <img border="0" src="member/<%=rs("pic3")%>" width="110" height="90"><%end if%></td> </tr> </table> </td> </tr> </table> </DIV></TD> <TD width=199> <div align="center"> <TABLE cellSpacing=1 cellPadding=5 width="90%" border=0> <TBODY> <TR> <TD bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 车辆类型:</TD> <TD width=105 bgColor=#f0f4fd><%=rs("cartype")%> [<FONT color=#ff0000><%=rs("change")%> </FONT>]</TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD width=100 bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 车辆品牌:</TD> <TD bgColor=#f0f4fd><%=rs("brand")%> </TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD width=100 bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 款 式:</TD> <TD bgColor=#f0f4fd><%=rs("type")%> </TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 汽车颜色:</TD> <TD bgColor=#f0f4fd><%=rs("color")%> </TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD width=100 bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 地 区:</TD> <TD bgColor=#f0f4fd><%=rs("city")%> </TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 能否过户:</TD> <TD bgColor=#f0f4fd><%=rs("transfer")%></TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD width=100 bgColor=#f0f4fd height=29><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3></FONT> 购买时间:</TD> <TD bgColor=#f0f4fd><%=rs("birthyear")%></TD></TR> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3><STRONG> </STRONG></FONT>价 格:</TD> <TD bgColor=#f0f4fd><%=rs("money")%>(元)</TD></TR> <tr> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD> </tr> <tr> <TD bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3><STRONG> </STRONG></FONT>刊登期限:</TD> <TD bgColor=#f0f4fd><%=rs("kdqx")%></TD> </tr> <TR height=1 background="images/ve.gif"> <TD background=../新建文件夹/mai.files/ve.gif colSpan=2 height=1></TD></TR> <TR> <TD bgColor=#f0f4fd><FONT color=#cc0000> <IMG height=5 src="../新建文件夹/mai.files/sanjiao.gif" width=3><STRONG> </STRONG></FONT>浏览人数:</TD> <TD bgColor=#f0f4fd><%=rs("hit")%></TD></TR></TBODY></TABLE></div> <BR></TD><!-- 汽车图片 --></TR></TBODY></TABLE></TD></TR> <TR> <TD> </TD></TR> <TR> <TD> <TABLE cellSpacing=0 borderColorDark=#ffffff cellPadding=0 width="100%" align=center borderColorLight=#ffffff border=0> <TBODY> <TR> <TD background=../新建文件夹/mai.files/ve.gif colSpan=3 height=1></TD></TR> <TR> <TD align=left width=247> 车 辆 执 照 : <%=rs("paizhao")%> </TD> <TD align=middle width=4> </TD> <TD align=middle width=296 height=25> <DIV align=left>登 记 日 期 : <%=rs("date")%></DIV></TD></TR> <TR> <TD background=../新建文件夹/mai.files/ve.gif colSpan=3 height=1></TD></TR> <TR> <TD align=middle colSpan=2 height=25> <DIV align=left> 原车用途: <%=rs("foruse")%> </DIV></TD> <TD align=middle width=296> <DIV align=left>行程/公里数 : <%=rs("journey")%> 公里 </DIV></TD></TR> <TR> <TD background=../新建文件夹/mai.files/ve.gif colSpan=3 height=1></TD></TR> <TR> <TD background=../新建文件夹/mai.files/ve.gif colSpan=3 height=1></TD></TR> <TR> <TD colSpan=3 height=25> 车 况 : <%=ubb2html(formatStr(autourl(rs("meno"))),true,true)%></TD></TR> <TR> <TD background=../新建文件夹/mai.files/ve.gif colSpan=3 height=1></TD></TR> <TR> <TD colSpan=3 height=25> </TD></TR></TBODY></TABLE> <DIV align=left> </DIV></TD></TR> </TBODY></TABLE> <TABLE cellSpacing=0 cellPadding=1 width="100%" bgColor=#3399cc border=0><TBODY> <TR> <TD> <TABLE cellSpacing=0 cellPadding=0 width="100%" align=center bgColor=#ffffff border=0> <TBODY> <TR> <TD colSpan=4> <TABLE cellSpacing=0 cellPadding=0 width="92%" border=0> <TBODY> <TR> <TD vAlign=bottom width=120 background=../新建文件夹/mai.files/bj01.gif> <IMG height=20 src="../新建文件夹/mai.files/lx01.gif" width=120 border=0></TD> <TD width=145> <IMG height=48 src="../新建文件夹/mai.files/lx02.gif" width=100 border=0></TD> <TD width=165> <IMG height=48 src="../新建文件夹/mai.files/lx03.gif" width=115 border=0></TD> <TD width=121> <IMG height=48 src="../新建文件夹/mai.files/lx04.gif" width=95 border=0></TD> <TD width=101> <IMG height=48 src="../新建文件夹/mai.files/lx05.gif" width=110 border=0></TD></TR></TBODY></TABLE></TD></TR> <TR> <TD width="14%">姓名:</TD> <TD width="38%" height=25><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("name")%>" name=textfield10> </FONT></TD> <TD width="8%">城市:</TD> <TD width="40%"><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("city")%>" name=textfield62> </FONT></TD></TR> <TR> <TD height=25>电话:</TD> <TD><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("phone")%>" name=textfield22> </FONT></TD> <TD>地区:</TD> <TD><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("sf")%>" name=textfield72> </FONT></TD></TR> <TR> <TD height=27>E-MAIL</TD> <TD><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("email")%>" name=textfield32> </FONT></TD> <TD>邮编:</TD> <TD><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("post")%>" name=textfield82> </FONT></TD></TR> <TR> <TD height=25>手机:</TD> <TD><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=29 value="<%=rs("mobile")%>" name=textfield42> </FONT></TD> </TR> <TR> <TD height=25>公司名称:</TD> <TD colSpan=3><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly size=70 value="<%=rs("company")%>" name=textfield422> </FONT><FONT color=#990000> </FONT></TD></TR> <TR> <TD height=25>地址:</TD> <TD colSpan=3><FONT color=#990000> <INPUT style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; FONT-SIZE: 9pt; BORDER-LEFT: medium none; BORDER-BOTTOM: rgb(0,0,0) 1px solid" readOnly maxLength=100 size=70 value="<%=rs("address")%>" name=textfield52> </FONT></TD></TR></TBODY></TABLE></TD></TR> <TR> <TD align=right bgColor=#ffffff height=20></TD></TR> <TR> <TD align=right bgColor=#ffffff><FONT color=#ff0000>此信息共有 0条评论!</FONT></TD></TR> <TR> <TD align=right bgColor=#ffffff height=20></TD></TR></TBODY></TABLE> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="10%"><FONT color=#ff0000>注意!</FONT></TD> <TD><FONT color=#990000>本站近日推出手机机主所在地查询服务,以便更好的判断信息的真伪。</FONT></TD></TR> <TR> <TD> </TD> <TD align=left bgColor=#ffffff height=20 a> <FORM onsubmit="window.open('', 'mywindow', 'height=180,width=280,status=yes,toolbar=no,menubar=no,location=no')" action=http://www.cnonline.org/gs/index.asp method=post target=mywindow><FONT color=#990000>请输入要查询的手机号码:</FONT> <INPUT size=16 name=n> <INPUT type=submit value=查询> </FORM></TD></TR></TBODY></TABLE> <P>此汽车没评论 </P> <table border="0" width="100%" cellspacing="0" cellpadding="0" id="table3"> <tr> <% dim totalremark,Currentpage,totalpages,i sql5="select * from d_remark where haved_id="&rs("id") set rs5=server.createobject("adodb.recordset") rs5.open sql5,conn,1,1 %> <tr bgcolor="#EFEBEF"> <td colspan="5" background="../images/dh.gif" bgcolor="#F5F5F5"><b>网友评论</b> [<%=rs5.recordcount%>条评论]</td> </tr> <% if not rs5.eof then rs5.movefirst rs5.pagesize=remarkperpage if trim(request("page"))<>"" then currentpage=clng(request("page")) if currentpage>rs5.pagecount then currentpage=rs5.pagecount end if else currentpage=1 end if totalremark=rs5.recordcount if currentpage<>1 then if (currentpage-1)*remarkperpage<totalremark then rs5.move(currentpage-1)*remarkperpage dim bookmark bookmark=rs5.bookmark end if end if if (totalremark mod remarkperpage)=0 then totalpages=totalremark\remarkperpage else totalpages=totalremark\remarkperpage+1 end if i=0 do while not rs5.eof and i<remarkperpage%> '就是这里---------------(remarkperpage我是设置了6。但是不行。只显示一个出来。我生气之下写了3215就能全部显示出来。这是什么原因了。 这样的代码我都用了十几次了。这次却出问题 <tr> <td colspan="5" bgcolor="#FFFFFF"><span >>></span> <%=rs5("remarker")%> 发表于<span ><%=rs5("remark_date")%><br> ---------------------------------------------------------------<br> </span> <font color="#9F9F9F"><%=ubb2html(formatStr(autourl(rs5("remark"))), true, true)%></font> </td> </tr> <% i=i+1 rs5.movenext loop else if rs5.eof and rs5.bof then %> <tr bgcolor="#ffffff"> <td colspan="5">暂时还没有网友发表评论。</td> </tr> <%end if end if%> <tr bgcolor="#ffffff" align="right"> <td colspan="5" >Page <%=currentpage%> of <%=totalpages%>,<%=totalremark%> records, <% i=1 for i=1 to totalpages if i=currentpage then %> <%=i%> <%else%> <a href="changedetail.asp?id=<%=request.querystring("id")%>&page=<%=i%>"><%=i%></a> <%end if next%> </td> </tr> </table> </center> </div> <table cellspacing=1 cellpadding=0 width="100%" align=center border=0> <tr> <td width="100%" height="5"></td> </tr> </table> <div align="center"> <table width="98%" cellspacing="1" bgcolor="#B2B2B2" cellpadding="6"> <form name="addremark" method="POST" action="<%=MM_editAction%>"> <tr bgcolor="#F7FFFF"> <td bgcolor="#FFFFFF" colspan="2">发表评论:</td> </tr> <tr> <td bgcolor="#FFFFFF" height="13" width="14%">您的称呼-</td> <td bgcolor="#FFFFFF" height="13" width="86%"> <input type="text" name="remarker" class="textarea" size="30" maxlength="30"> 最多30个字符</td> </tr> <tr> <td bgcolor="#FFFFFF" height="13" width="14%">E-MAIL -</td> <td bgcolor="#FFFFFF" height="13" width="86%"> <input type="text" name="email" class="textarea" size="23" maxlength="30"> </td> </tr> <tr> <td bgcolor="#FFFFFF" height="13" width="14%">联系方式-</td> <td bgcolor="#FFFFFF" height="13" width="86%"> <input type="text" name="fangshi" class="textarea" size="23" maxlength="30"> </td> </tr> <tr> <td bgcolor="#FFFFFF" width="14%" valign="top">您的意见-<br> <br> </td> <td bgcolor="#FFFFFF" width="86%"> <textarea name="remark" cols="58" rows="6" class="textarea"></textarea> <br> 最多225字符 </td> </tr> <tr> <td bgcolor="#F5F5F5" colspan="2"> <div align="center"> <input type="submit" name="Submit2" value="确定发表" onClick="YY_checkform('addremark','remarker','#q','0','称呼必须填写!','email','1','1','评论email必须填写!','fangshi','1','1','评论联系方式必须填写!','remark','1','1','评论内容必须填写!');return document.MM_returnValue"> <input type="reset" name="reset" value="取消重写" > </div></td> </tr> <input type="hidden" name="MM_insert" value="true"> <input type="hidden" name="haved_id" value="<%=request.querystring("id")%>"> </form> </table> </div> </tr> </table> </TD></TR></TBODY></TABLE> <%sql="update haved set hit = hit + 1" conn.execute(sql) closedatabase%> <TABLE cellSpacing=0 cellPadding=0 align=center border=0> <TBODY> <TR> <TD> </TD></TR></TBODY></TABLE> <TABLE cellSpacing=0 cellPadding=0 width=770 align=center border=0> <TBODY> <TR> <TD> </TD></TR></TBODY></TABLE></BODY></HTML> |
地主 发表时间: 04-08-06 16:23 |
回复: tommy_he [tommy_he] 版主 | 登录 |
还是把所有的文件弄出来,放到软件里看好了,这么看不死也重伤啊! |
B1层 发表时间: 04-08-07 02:13 |
回复: kailangq [kailangq] 版主 | 登录 |
...你想让我眼睛挂还是人挂? |
B2层 发表时间: 04-08-07 04:24 |
回复: zybzc [zybzc] 论坛用户 | 登录 |
路过 顺便问下``` 后台管理页面 提交编辑页面后显示的是已编辑的页面 我想让提交后显示重新编辑的新页面```改URL不行 噢 最近才开始弄ASP滴 不熟 HOHO` |
B3层 发表时间: 04-08-07 09:05 |
回复: bailove [bailove] 论坛用户 | 登录 |
现在这问题 解决了 还有一个很短的代码 帮忙看下. 问题是提交一次.数据库被添加了两次.相关的文件http://menhoo.com.cn/member.rar 里面有conn.asp和数据库. 帮我看下我数据库里面的表弄的有问题吗? 下面的代码我真看不出错了 <!--#include file="Conn.asp"--> <!--#include file="membermenu.asp"--> <!-- #include file="../admin/char.asp"--> <!--#include file="error.asp"--> <!--#include file="error1.asp"--> <% dim founderr,errmsg,sessionvar,userid founderr=false errmsg="" sessionvar="ok" userid=session("userid") if session("userlogin")<>sessionvar then founderr=true errmsg=errmsg+"<br>"+"你尚未登录,或者超时了!请重新登录!" call diserror1() response.end else if request.form("MM_insert") then if request.form("action")="add" then sql="select * from haved" set rs=server.createobject("adodb.recordset") rs.open sql,conn,1,3 rs.addnew dim oil,money,color,transfer,birthyear,journey,foruse,kdqx,pic,pic1,pic2,pic3,meno,paizhao,phone,post,sf,flag,address,change,city,company,email,mobile dim fax,name,sip,stype,brand,cartype cartype=trim(request.form("cartype")) brand=trim(replace(request.form("brand"),"'","")) paizhao=trim(replace(request.form("paizhao"),"'","")) stype=trim(replace(request.form("type"),"'","")) oil=trim(replace(request.form("oil"),"'","")) money=cint(request.form("money")) color=trim(replace(request.form("color"),"'","")) transfer=trim(replace(request.form("transfer"),"'","")) birthyear=trim(replace(request.form("birthyear"),"'","")) journey=trim(replace(request.form("journey"),"'","")) foruse=trim(replace(request.form("foruse"),"'","")) kdqx=trim(replace(request.form("kdqx"),"'","")) pic=trim(replace(request.form("pic"),"'","")) pic1=trim(replace(request.form("pic1"),"'","")) pic2=trim(replace(request.form("pic2"),"'","")) pic3=trim(replace(request.form("pic3"),"'","")) meno=trim(replace(request.form("meno"),"'","")) phone=trim(replace(request.form("phone"),"'","")) post=trim(replace(request.form("post"),"'","")) phone=trim(replace(request.form("phone"),"'","")) sf=trim(replace(request.form("province"),"'","")) flag=trim(replace(request.form("flag"),"'","")) address=trim(replace(request.form("address"),"'","")) change=trim(replace(request.form("change"),"'","")) city=trim(replace(request.form("city"),"'","")) company=trim(replace(request.form("company"),"'","")) email=trim(replace(request.form("email"),"'","")) fax=trim(replace(request.form("fax"),"'","")) name=trim(replace(request.form("username"),"'","")) mobile=trim(replace(request.form("mobile"),"'","")) sip=Request.ServerVariables("REMOTE_ADDR") If sip="" Then sip=request.ServerVariables("HTTP_X_FORWARDED_FOR") End If if cartype="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须汽车分类!" else rs("cartype")=cartype end if if brand="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须填写汽车品牌!" else rs("brand")=brand end if rs("paizhao")=paizhao if stype="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须选择汽车型号!" else rs("type")=stype end if rs("oil")=oil if money="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须填写交易价格!" else rs("money")=money end if if color="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须填写汽车颜色!" else rs("color")=color end if rs("transfer")=transfer rs("birthyear")=birthyear if journey="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须填写行驶公里!" else rs("journey")=journey end if if foruse="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须选择车用途!" else rs("foruse")=foruse end if if kdqx="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须选择刊登期限!" else rs("kdqx")=kdqx end if rs("pic")=pic rs("pic1")=pic1 rs("pic2")=pic2 rs("pic3")=pic3 if meno="" then founderr=true errmsg=errmsg+"<br>"+"<li>你必须填写汽车备注!" else rs("meno")=meno end if rs("phone")=phone rs("post")=post rs("sf")=sf rs("flag")=flag rs("address")=address rs("change")=change rs("city")=city rs("company")=company rs("email")=email rs("fax")=fax rs("name")=name rs("mobile")=mobile rs("userid")=userid rs("ip")=sip if founderr then call diserror() response.end else rs.update rs.close set rs=nothing end if response.write "<script language=JavaScript>{window.alert('添加成功!');window.location.href='chelist.asp?type="&change&"';}</script>" end if end if %> <HTML><HEAD><TITLE>东南车网――会员专区</TITLE> <META http-equiv=Content-Type content="text/html; charset=gb2312"> <LINK href="images/css.css" type=text/css rel=stylesheet> <SCRIPT language=JavaScript type=text/JavaScript> <!-- function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } //--> </SCRIPT> <SCRIPT language=javascript> function show_sader(mylink) { window.open(mylink,'','top=140,left=135,width=480,height=280,scrollbars=no ') } </SCRIPT> <META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD> <BODY> <SCRIPT language=JavaScript type=text/JavaScript> <!-- function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } //--> </SCRIPT> <SCRIPT language=javascript> function show_sader(mylink) { window.open(mylink,'','top=140,left=135,width=480,height=280,scrollbars=no ') } </SCRIPT> <SCRIPT language=JavaScript> function CheckInput() { if (document.Form1.cartype.value == "") { alert("汽车分类不能为空!"); document.Form1.cartype.focus(); return false; } if (document.Form1.brand.value == "") { alert("请输入汽车品牌!"); document.Form1.brand.focus(); return false; } if (document.Form1.type.value == "") { alert("请输入汽车型号!"); document.Form1.type.focus(); return false; } if (document.Form1.money.value == "") { alert("请输入汽车价格!"); document.Form1.money.focus(); return false; } if (document.Form1.meno.value == "") { alert("请输入汽车状况!"); document.Form1.meno.focus(); return false; } document.Form1.submit() } </SCRIPT> <div align="center"> <TABLE height=47 cellSpacing=0 cellPadding=0 width=770 border=0> <TBODY> <TR> <TD vAlign=bottom align=right background=images/line.gif height=44> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width=300> </TD> <TD vAlign=bottom align=right width=460><A href="erro1.asp"> <IMG src="images/reset.gif" border=0></A> <A href="../asp/logincheck.asp?action=logout"> <IMG src="images/back.gif" border=0></A> </TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE> </div> <div align="center"> <table border="0" width="80%" cellspacing="0" cellpadding="0"> <tr> <td width="189" valign="top"> <%call membermenu()%></td> <td> <table border="0" width="100%" cellspacing="0" cellpadding="0" height="100%" id="table1"> <tr> <td height="51"> <IMG height=36 src="images/hyzq_t.gif" width=109></td> </tr> <tr> <td valign="top"> <%sql="select * from [user] where userid='"&userid&"'" set rs=server.createobject("adodb.recordset") rs.open sql,conn,1,1%> <table border="1" width="100%" id="table2"> <tr> <td> <FORM name=Form1 method=POST> <TABLE height=280 cellSpacing=0 cellPadding=0 width="100%" borderColorLight=#ffffff border=0 id="table3"> <TBODY><INPUT type=hidden value=卖 name=change> <TR> <TD colSpan=4 height=17> <TABLE id=table4 style="BORDER-COLLAPSE: collapse" borderColor=#111111 cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width=770 height=17> <TABLE id=table5 style="BORDER-COLLAPSE: collapse" borderColor=#111111 cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="84%"><SPAN style="FONT-SIZE: 10.5pt"><B> 汽车出售</B></SPAN></TD> <TD width="16%"> <P align=right><FONT color=#ff6600> *</FONT><FONT color=#000080>为必填项 </FONT></P></TD></TR></TBODY></TABLE> <TABLE id=table6 style="BORDER-COLLAPSE: collapse" borderColor=#111111 cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD align=right width="15%" height=10> </TD> <TD width="58%" height=10> </TD> <TD width="27%" height=10> </TD></TR></TBODY></TABLE> <TABLE id=table7 style="BORDER-COLLAPSE: collapse" borderColor=#111111 cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD background="" height=1></TD> <TD background=""></TD></TR></TBODY></TABLE> <TABLE id=table8 style="BORDER-COLLAPSE: collapse" borderColor=#111111 cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD align=right width="15%" height=10> </TD> <TD width="58%" height=10> </TD> <TD width="27%" height=10> </TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR> <TR height=25> <TD align=right width=89 height=23><SPAN class=word9>汽车分类</SPAN>:</TD> <TD width=213 height=23><SELECT size=1 name=cartype> <OPTION value="" selected>全部车型</OPTION> <OPTION value=轿车>轿车</OPTION> <OPTION value=跑车>跑车</OPTION> <OPTION value=SUV及越野车>SUV及越野车</OPTION> <OPTION value=箱形车>箱形车</OPTION> <OPTION value=概念车>概念车</OPTION> <OPTION value=客车>客车</OPTION> <OPTION value=货车>货车</OPTION> <OPTION value=其它车型>其它车型</OPTION></SELECT> <FONT color=#ff6600>*</FONT></TD> <TD width=90 height=23> <P align=center><SPAN class=word9>汽车品牌:</SPAN></P></TD> <TD width=216 height=23><INPUT class=f11 title=例如:桑塔纳200、红旗CA7200、SVW7180CEI size=15 name=brand> <FONT color=#ff6600>*</FONT></TD></TR> <TR> <TD align=right width=89 height=24>现车牌照:</TD> <TD width=213 height=24><INPUT class=f11 title=例如:浙AT0385 size=15 name=paizhao> <FONT color=#ff6600>*</FONT></TD> <TD align=middle width=90 height=24><SPAN class=word9>汽车型号:</SPAN></TD> <TD width=216 height=24><INPUT class=f11 title=例如:桑塔纳200、红旗CA7200、SVW7180CEI size=15 name=type> <FONT color=#ff6600>*</FONT></TD></TR> <TR> <TD align=right width=89 height=25> 油耗量:</TD> <TD width=213 height=25><INPUT size=10 name=oil> c.c.</TD> <TD align=middle width=90 height=24> <SPAN class=word9>交易价格:</SPAN></TD> <TD width=216 height=24><INPUT class=f11 title=车价以人民币(元)为单位(填0表示面议) size=12 name=money> 元 <FONT color=#ff6600>*</FONT>(<span lang="zh-cn">只能填数字,填0为"价格面议")</span></TD></TR> <TR> <TD align=right width=89 height=21><SPAN class=word9>汽车颜色:</SPAN></TD> <TD width=213 height=21><SELECT style="FONT-SIZE: 13px" size=1 name=color> <OPTION selected>请选择</OPTION> <OPTION value=白色>白色</OPTION> <OPTION value=银色>银色</OPTION> <OPTION value=绿色>绿色</OPTION> <OPTION value=红色>红色</OPTION> <OPTION value=黄色>黄色</OPTION> <OPTION value=蓝色>蓝色</OPTION> <OPTION value=黑色>黑色</OPTION> <OPTION value=紫色>紫色</OPTION> <OPTION value=棕色>棕色</OPTION> <OPTION value=其他>其他</OPTION></SELECT> <FONT color=#ff6600>*</FONT></TD> <TD align=middle width=90 height=21>车牌过户:</TD> <TD width=216 height=21> <SPAN class=word9> <INPUT title=指牌照是否过户 type=radio CHECKED value=能 name=transfer> </SPAN>是<SPAN class=word9> <INPUT title=指牌照是否过户 type=radio value=目前不能 name=transfer> 否</SPAN> </TD></TR> <TR> <TD align=right width=89 height=25>购买日期:</TD> <TD width=213 height=25> <!--webbot bot="Validation" s-data-type="String" b-value-required="TRUE" i-maximum-length="10" --><INPUT title=请输入年份 maxLength=10 size=10 name=birthyear> 年 <FONT color=#ff6600>*</FONT>(<span lang="zh-cn">格式如:1982-02-21)</span></TD> <TD align=middle width=90 height=25><SPAN class=word9>行驶公里:</SPAN></TD> <TD width=216 height=25><INPUT title=已经行驶多少公里 size=12 name=journey> 公里<FONT color=#ff6600> *</FONT></TD></TR> <TR> <TD align=right width=89 height=1>原车用途:</TD> <TD width=213 height=1><SELECT name=foruse> <OPTION selected>--请选择--</OPTION> <OPTION value=私人用车>私人用车</OPTION> <OPTION value=出租车>出租车</OPTION> <OPTION value=租赁车>租赁车</OPTION> <OPTION value=机关用车>机关用车</OPTION> <OPTION value=公务用车>公务用车</OPTION> <OPTION value=运输用车>运输用车</OPTION> <OPTION value=地方车辆>地方车辆</OPTION> <OPTION value=驾校教练车>驾校教练车</OPTION> <OPTION value=外地迁京车辆>外地迁京车辆</OPTION> <OPTION value=其它>其它</OPTION></SELECT> <FONT color=#ff6600>*</FONT></TD> </TR> <TR> <TD align=right width=89 height=12> 刊登期限:</TD> <TD width=213 height=12><SELECT class=f11 style="BORDER-RIGHT: 1px solid; BORDER-TOP: 1px solid; BORDER-LEFT: 1px solid; BORDER-BOTTOM: 1px solid" size=1 name=kdqx> <OPTION value=一周 selected>一周</OPTION> <OPTION value=半月>半月</OPTION> <OPTION value=一个月>一个月</OPTION> <OPTION value=三个月>三个月</OPTION> <OPTION value=六个月>六个月</OPTION> <OPTION value=一年>一年</OPTION> <OPTION value=长期>长期</OPTION></SELECT> <FONT color=#ff6600>*</FONT></TD> <TD align=middle width=90 height=12> </TD> <TD width=216 height=12> </TD></TR> <TR> <TD align=right width=89 height=12></TD> <TD width=213 height=12></TD> <TD align=middle width=90 height=12> </TD> <TD width=216 height=12> </TD></TR> <TR> <TD align=right width=89 height=1>汽车图片1:</TD> <TD colSpan=3 height=1> <INPUT title=已经行驶多少公里 size=52 name=pic><FONT color=#ff6600> *</FONT></TD></TR> <TR> <TD align=right width=89 height=1>汽车图片2:</TD> <TD colSpan=3 height=1> <INPUT title=已经行驶多少公里 size=52 name=pic1><FONT color=#ff6600> *</FONT></TD></TR> <TR> <TD align=right width=89 height=1>汽车图片3:</TD> <TD colSpan=3 height=1> <INPUT title=已经行驶多少公里 size=52 name=pic2><FONT color=#ff6600> *</FONT></TD></TR> <TR> <TD align=right width=89 height=1>汽车图片4:</TD> <TD colSpan=3 height=1> <INPUT title=已经行驶多少公里 size=52 name=pic3><FONT color=#ff6600> *</FONT></TD></TR> <TR> <TD align=right width=89 height=57> 汽车备注:<BR> (最多500字)</TD> <TD align=left colSpan=3 height=57> <TEXTAREA class=f11 title=车况描述最多只能500个字 style="FONT-FAMILY: 宋体" name=meno rows=4 cols=46></TEXTAREA> <FONT color=#ff6600> *</FONT></TD></TR> <TR> <TD align=middle colSpan=4 height=21></TD></TR> <TR> <TD align=middle colSpan=4 height=21> <INPUT type=hidden value="<%=rs("address")%>" name=address> <INPUT type=hidden value="<%=rs("flag")%>" name=flag> <INPUT type=hidden value="<%=rs("company")%>" name=company> <INPUT type=hidden value="<%=rs("city")%>" name=city> <INPUT type=hidden value="<%=rs("sf")%>" name=province> <INPUT type=hidden value="<%=rs("phone")%>" name=phone> <INPUT type=hidden value="<%=rs("fax")%>" name=fax> <INPUT type=hidden value="<%=rs("post")%>" name=post> <INPUT type=hidden value="<%=rs("email")%>" name=email> <INPUT type=hidden value="<%=rs("name")%>" name=username> <INPUT onclick=CheckInput() type=submit value=提交 name=button> <INPUT type=reset value=取消 name=Submit3> </TD></TR> <TR height=25> <TD align=middle colSpan=4 height=12></TD></TR></TBODY></TABLE> <input type="hidden" name="MM_insert" value="true"> <input type="hidden" name="action" value="add"> <input type="hidden" name="mobile" value="<%=rs("mobile")%>"></FORM> </td> </tr> <tr> <td> <p align="center"><font color="#FF0000"> 使用方法:将下面上传的图片地址复制到上面的图片地址栏中</font></td> </tr> <tr> <td> <iframe name="I1" src="upload.asp" scrolling="no" width="557" height="53"> 浏览器不支持嵌入式框架,或被配置为不显示嵌入式框架。</iframe></td> </tr> </table> <%end if%> |
B4层 发表时间: 04-08-07 09:56 |
|
20CN网络安全小组版权所有
Copyright © 2000-2010 20CN Security Group. All Rights Reserved.
论坛程序编写:NetDemon
粤ICP备05087286号