WEB开发网
开发学院CMS教程dvbbs 动网论坛教程:最后回复显示为贴子内容而不是主题... 阅读

动网论坛教程:最后回复显示为贴子内容而不是主题的修改方法

 2010-07-22 18:58:51 来源:WEB开发网   
核心提示:想把首面各版面最后回复的主题改为贴子主题而不是贴子内容的:savepost.asp中,如下的If Action = 6 Then topic=Replace(Replace(cutStr(toptopic,14),chr(10),""),"'","")

想把首面各版面最后回复的主题改为贴子主题而不是贴子内容的:


savepost.asp中,如下的


 If Action = 6 Then
  topic=Replace(Replace(cutStr(toptopic,14),chr(10),""),"'","")
  If topic="" Then
  topic=Replace(cutStr(Content,14),chr(10),"")
  Else
  topic=Replace(cutStr(topic,14),chr(10),"")
  End If
  If ihaveupfile=1 Then Dvbbs.Execute("update dv_upfile set F_AnnounceID='"&RootID&"|"&AnnounceID&"',F_Readme='"&Replace(toptopic,"'","")&"',F_flag=0 where F_ID in ("&upfileinfo&")")
 Else
  If ihaveupfile=1 Then Dvbbs.Execute("update dv_upfile set F_AnnounceID='"&RootID&"|"&AnnounceID&"',F_Readme='"&Topic&"',F_flag=0  where F_ID in ("&upfileinfo&")")
 End If
 LastPost=Replace(username,"$","") & "$" & AnnounceID & "$" & DateTimeStr & "$" & Replace(cutStr(Content,20),"$","") & "$" & uploadpic_n & "$" & Dvbbs.UserID & "$" & RootID & "$" & Dvbbs.BoardID
 LastPost=reubbcode(Replace(LastPost,"'",""))


改成:


 If Action = 6 Then
  topic=Replace(Replace(cutStr(toptopic,14),chr(10),""),"'","")
  If topic="" Then
  topic=Replace(cutStr(Content,14),chr(10),"")
  Else
  topic=Replace(cutStr(topic,14),chr(10),"")
  End If
  If ihaveupfile=1 Then Dvbbs.Execute("update dv_upfile set F_AnnounceID='"&RootID&"|"&AnnounceID&"',F_Readme='"&Replace(toptopic,"'","")&"',F_flag=0 where F_ID in ("&upfileinfo&")")

1 2  下一页

Tags:论坛 教程 最后

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接