| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 554 人关注过本帖
标题:[求助]怎么显示信息的点击率那??
只看楼主 加入收藏
flyingding520
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2006-7-17
收藏
 问题点数:0 回复次数:1 
[求助]怎么显示信息的点击率那??

http://*****.com.cn 中间我添加的信息,但点击后始终是/,没有记数,

hangxj:
下次不要乱贴网址上来



相关代码是
<!--#include file="conn1.asp"--><!--#include file="config.asp"-->
<%
dim rs,sql,cnmai,ThisPage
cnmai=HTMLEncode(request("cnmai"))
if request("page")="" then
ThisPage=1
else
ThisPage=request("page")
end if
function HTMLEncode(fString)
if not isnull(fString) then
fString = replace(fString, ">", "&gt;")
fString = replace(fString, "<", "&lt;")
fString = Replace(fString, CHR(32), "&nbsp;")
fString = Replace(fString, CHR(9), "&nbsp;")
fString = Replace(fString, CHR(34), "&quot;")
fString = Replace(fString, CHR(39), "&#39;")
fString = Replace(fString, CHR(13), "")
fString = Replace(fString, CHR(10) & CHR(10), "</P><P> ")
fString = Replace(fString, CHR(10), "<BR> ")
HTMLEncode = fString
end if
end function
%> <script LANGUAGE="JavaScript">
function checkMobile(){
var sMobile = document.mobileform.mobile.value
if(!(/^13[0-9]\d{4,8}$/.test(sMobile))){
alert("不是完整的11位手机号或者正确的手机号前七位");
document.mobileform.mobile.focus();
return false;}
window.open('', 'mobilewindow', 'height=197,width=350,status=yes,toolbar=no,menubar=no,location=no')
}</script>
<html><body topmargin="0"><%

sqlrenqi="update xinxi set llcs=llcs+1 where id="&cstr(cnmai)
conn.execute(sqlrenqi)

set rs=server.createobject("adodb.recordset")
sql = "select * from xinxi where id="&cstr(cnmai)
rs.open sql,conn,1,3
if rs.eof then
response.write "参数错误、记录已经删除或该信息没有通过管理员认证!"
response.write "<meta http-equiv=refresh content=""2;URL=index.asp"">"
response.end
end if
'rs("llcs")=rs("llcs")+1
'rs.update
%> <head><title><%=rs("biaoti")%>-信息内容-<%=title%></title>
<link href="inc_style.css" rel="stylesheet" type="text/css"></head><!--#include file=top.asp--><!--#include file=bar.asp--><table cellSpacing="0" cellPadding="0" width="760" align="center" bgColor="#ffffff" border="0" height="456"><td width="707" height="1" colspan="2" bgcolor="#FFF3E8"><tr><td width="213" valign="top" height="0">
<img border="0" src="images/a8.gif" width="170" height="45"></td><td height="455" width="547" valign="top" rowspan="4"><div align="center"><table border="1" width="545" bordercolor="#FFE9D2" cellspacing="1" style="border-collapse: collapse" height="635"><tr><td height="40" colspan="3" align="center"><font size="4"><b><%=rs("biaoti")%></b></font></td></tr><tr><td height="26" colspan="3" bgcolor="#F3F3F3"><font color="#008080"><b>●-基本信息----</b></font></td></tr><tr><td width="84" align="right" height="23">交易地区:</td><td width="218" height="26"><%=rs("diqu")%></td><td width="215" rowspan="7"><%if rs("tupian")<>"0" then%><p align="center">&nbsp;&nbsp;<a target=_blank href="uptupian/<%=rs("tupian")%>"><img src="uptupian/<%=rs("tupian")%>" border=1 width="160" style="border: 1px solid #C0C0C0; " alt="查看图片" height="160"></a><%else%>&nbsp;&nbsp;<a title="广告招租,029-83732767" href="http://www.xa2s.com"> </a><a href="http://www.cnmai.com">
<img src="images/pic.gif" border=1 style="border: 1px solid #C0C0C0; " width="160" height="160"></a> <%end if%></td></tr><tr><td width="84" align="right" height="23">物品类别:</td><td width="218" height="26"><%
dim rs1,sql1,id_1
set rs1=server.createobject("adodb.recordset")
sql1 = "select id,class1 from class1 where id="&cstr(rs("class1"))
rs1.open sql1,conn,1,1
id_1=rs1("id")
On Error Resume Next
%> <a href="info.asp?class1=<%=rs1("id")%>&cnmai=1"><%=rs1("class1")%></a> -->> <%
rs1.close
sql1 = "select id,class2 from class2 where id="&cstr(rs("class2"))
rs1.open sql1,conn,1,1
On Error Resume Next
%> <a href="info.asp?class1=<%=id_1%>&class2=<%=rs1("id")%>&cnmai=2"><%=rs1("class2")%></td></tr><tr><td width="84" align="right" height="23">交易方式:</td><td width="218" height="26"><%
rs1.close
set rs1=nothing
dim leixing
leixing=rs("leixing")
Select Case leixing
Case "1"
response.write "<font color=""#008000"">"&leixing1&"</font>"
Case "2"
response.write "<font color=""#FF00FF"">"&leixing2&"</font>"
Case "3"
response.write "<font color=""#008000"">"&leixing3&"</font>"
Case "4"
response.write "<font color=""#FF00FF"">"&leixing4&"</font>"
Case "5"
response.write "<font color=""#ff0000"">"&leixing5&"</font>"
Case "6"
response.write "<font color=""#ff0000"">"&leixing6&"</font>"
Case "7"
response.write "<font color=""#ff0000"">"&leixing7&"</font>"
Case "8"
response.write "<font color=""#ff0000"">"&leixing8&"</font>"
Case Else
response.write "<font color=""#FF00FF"">"&leixing9&"</font>"
End Select
%></td></tr><tr><td width="84" align="right" height="23">物品价格:</td><td width="218" height="26"><%if rs("jiage")=0 then%>面议<%else%><%=rs("jiage")%> 元<%end if%></td></tr><tr><td width="84" align="right" height="23">浏览回复:</td><td width="218" height="26"><%=rs("llcs")%>次/<%=rs("hfcs")%>次</td></tr><tr><td width="84" align="right" height="23">信息发布时间:</td><td width="218" height="26"><%=rs("fbsj")%></td></tr><tr><td width="84" align="right" height="23">信息结束时间:</td><td width="218" height="26"><%dim sj
sj=DateDiff("d",now(),""&rs("dqsj")&"")
if sj>0 then %><font color="#FF0000">还有<b><%=sj%></b>天结束<%else%>信息已经过期了<%end if%></font></td></tr><tr><td width="535" colspan="3" bgcolor="#F3F3F3" height="26"><font color="#008080"><b>●-详细信息-----</b></font></td></tr><tr><td width="535" colspan="3" height="9"><%=HTMLEncode(rs("memo"))%></td></tr><tr><td width="535" colspan="3" bgcolor="#F3F3F3" height="26"><font color="#008080"><b>●-联系方式-----</b></font></td></tr><tr><td width="84" align="right" height="23">联系人:</td><td width="218"><%=rs("name")%></td>
<td width="215" rowspan="5"><font color="#ff0000">&nbsp;&nbsp;&nbsp; 信息的真实性与合法性由信息提供者负责,请谨慎审核,理性抉择。<br>&nbsp;&nbsp;&nbsp;&nbsp;本网站对用户所提供的信息的真实性及准确性不承担任何责任,如果因信息真实性或冒发他人信息所引起的纠纷及责任乃至法律责任,均由原信息发布人自行承担,本站不承担任何责任。</font><br>*可以通过查看<font color="#FF0000">手机归属地</font>、<font color="#FF0000">发布人IP</font>,判断信息的可信度</td></tr><tr><td width="84" align="right" height="23">联系电话:</td><td width="218"><form action="http://www.ip138.com:8080/search.asp" method="post" onSubmit="return checkMobile();" target="mobilewindow" name="mobileform"><input type="hidden" name="action" value="mobile"><input class="TextBoxStyle" maxLength="11" name="mobile" size="15" value="<%=rs("dianhua")%>"><input class="ButtonStyle" type="submit" value="手机查询" style="border:1px solid #C0C0C0; color: #FF0000" title="通过查看手机归属地,可以判断信息的可信度"></td></form></td></tr><tr><td width="84" align="right" height="23">电子邮件:</td><td width="218"><%=rs("email")%></td></tr><tr><td width="84" align="right" height="23">QQ或MSN:</td><td width="218"><%=rs("qq")%></td></tr><tr><td width="84" align="right" height="23">发布人IP地址:</td><td width="218"><FORM METHOD=POST ACTION="http://www.ip138.com/ips.asp" target="_blank" name="ipform" onSubmit="return checkIP();" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><input type="text" name="ip" size="15" value="<%=rs("ip")%>" style="border: 1px solid #FFFFFF; background-color: #FFFFFF"><input type="submit" value=" 查看ip " title="通过查看发布人IP,可以判断信息的可信度" style="background-color: #FFFFFF"> <INPUT TYPE="hidden" name="action" value="2"></FORM></td></tr><tr><td width="535" align="right" colspan="3" height="26"><table border="0" width="100%" cellspacing="0" cellpadding="0" id="table1"><tr><td width="117" valign="bottom"><p align="left"><a href="xinxi_hf.asp?id=<%=rs("id")%>">
<img border="0" src="images/hf.jpg"></a>&nbsp;  </td><td> </td></tr></table></td></tr><tr><td width="535" align="right" colspan="3"><table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" height="1"><%
if rs("hfcs")>=1 then
rs.close
dim k
k=1
sql = "select * from hf where xxid='"&cnmai&"'"
rs.open sql,conn,1,1
%> <%do while not rs.eof%> <tr><td width="3%" height="25" bgcolor="#F9F9F9" style="border-bottom-style: solid; border-bottom-width: 1" bordercolor="#999999"></td><td width="5%" height="25" bgcolor="#F9F9F9" style="border-bottom-style: solid; border-bottom-width: 1" bordercolor="#999999"><b><%=k%></b></td><td width="90%" height="25" bgcolor="#F9F9F9" style="border-bottom-style: solid; border-bottom-width: 1" bordercolor="#999999">该信息由<b><font color="#CC0000"><%=trim(rs("username"))%></font></b>在<font color="#CC0000"><%=trim(rs("hfsj"))%></font>回复</td><td width="2%" height="25" bgcolor="#F9F9F9" style="border-bottom-style: solid; border-bottom-width: 1" bordercolor="#999999"></td></tr><tr><td width="3%" height="1" style="border-top-style: solid; border-top-width: 1"></td><td width="5%" height="1" style="border-top-style: solid; border-top-width: 1"></td><td width="90%" height="1" style="border-top-style: solid; border-top-width: 1"><%=HTMLEncode(rs("neirong"))%></td><td width="2%" height="1" style="border-top-style: solid; border-top-width: 1"></td></tr><%
rs.movenext
k=k+1
loop
end if
%> <tr><td width="100%" height="1" colspan="4"></td></tr></table></td></tr></table></div></td></tr><tr><td width="213" height="630" valign="top"><%
dim re_rs,re_sql
set re_rs=server.createobject("adodb.recordset")
re_sql="select top 10 * from xinxi order by llcs desc"
re_rs.open re_sql,conn,1,1
if re_rs.eof and re_rs.bof then
response.write "<p align=""center"">没有此类信息</p>"
else
do while not re_rs.eof
response.write "·"
if re_rs("tupian")<>0 then
response.write "<img src=""images/num/pic.gif"" alt=""有图片"">"
end if
response.write "<a href=""xinximemo.asp?cnmai="& re_rs("id")&""" title="""&re_rs("name")&"-发布于"&datevalue(re_rs("fbsj"))&" 浏览:"&re_rs("llcs")&"次"">"& mid(re_rs("biaoti"),1,30) & "</a><font color=""#008080"">["&re_rs("llcs")&"]</font><br>"
re_rs.movenext
loop
end if
re_rs.close
%> </td></tr></table><!--#include file=end.htm--></body></html><%
rs.close
set rs=nothing
closedb
%>


其中“LLCS”是点击数,


就高手帮忙

搜索更多相关主题的帖子: 点击率 
2006-07-17 17:17
hangxj
Rank: 6Rank: 6
等 级:贵宾
威 望:29
帖 子:2045
专家分:0
注 册:2006-4-10
收藏
得分:0 
在内容显示页面对LLCS进行加1操作,
老问题,在站内搜索一下相关贴子

http://www./
2006-07-18 12:52
快速回复:[求助]怎么显示信息的点击率那??
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.017458 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved