账号通
    

账号  

密码  

3008

查看

0

回复
主题:Wap/Wap_Cls/Wap.RCls乱码如何改呀! [收藏主题]  
饭好香 当前离线

281

主题

0

广播

0

粉丝
添加关注
级别:二年级

用户积分:1557 分
登录次数:56 次
注册时间:2007/8/17
最后登录:2016/12/22
饭好香 发表于:2009/2/17 12:24:00   | 显示全部帖子 查看该作者主题 楼主 
科汛在线商城系统(NET)

<!--#include file="Wap.BlogCls.asp"-->
<!--#include file="Wap.SQLCls.asp"-->
<%


        '**************************************************
  '鍑芥暟鍚嶏细LoadTemplate
  '浣? 鐢细鍙栧嚭妯℃澘鍐呭
  '鍙? 鏁帮细TemplateFname妯℃澘鍦板潃
  '杩斿洖链硷细妯℃澘鍐呭
  '**************************************************
  Function LoadTemplate(TemplateFname)
      on error resume next
    dim str,stm
    set stm=server.CreateObject("adodb.stream")
    stm.Type=2 '浠ユ湰妯″纺璇诲彇
    stm.mode=3
    stm.chaRset="utf-8"
    stm.open
    stm.loadfromfile server.MapPath(TemplateFname)
    str=stm.readtext
    stm.Close
    set stm=nothing
    If err Then
       Response.redirect GetDomain&"Wap_Err.asp?id=4"
       Response.End
    Else
       LoadTemplate=str
    End If
     LoadTemplate=LoadTemplate & Published
  End Function
  
  '**************************************************
  '鍑芥暟鍚嶏细Channel
  '浣? 鐢细鍙栧嚭妯℃澘甯哥敤鏁版嵁
  '**************************************************
  Function Channel(Str)
    If ChannelID="" then
    Set Rs=Conn.Execute("select ChannelID from ks_Class where ClassID="&ClassID&"")
    If Rs.eof then
       ChannelID=0
    Else
       ChannelID=Rs(0)
    End if
    Rs.Close:set Rs=nothing
    End if
       Set Rs1=Conn.Execute("select "&Str&" from KS_Channel where ChannelID="&ChannelID&" and ChannelStatus=1 and WapSwitch=1")
       If Rs1.eof then
       Response.Redirect ""&GetDomain&"wap_Err.asp?id=14"
    Else
       Channel = Rs1(0)
    End if
    Rs1.Close:set Rs1=nothing
  End Function
 
 '**************************************************
 '鍑芥暟鍚嶏细GetTopUserLogin
 '浣? 鐢细鏄剧ず浼氩憳鐧诲綍鍏ュ彛(妯帓)
 '**************************************************
 Function GetTopUserLogin()
      If Cbool(UserLoginChecked)=True Then
      Dim MyMailTotal:MyMailTotal=Conn.Execute("Select Count(ID) From KS_Message Where Incept='" &User("UserName") &"' And Flag=0 and IsSend=1 and delR=0")(0)
      TempStr = TempStr &"<a href="""&GetDomain&"User/User_Message.asp?action=inbox&wap="&wap&""">鏀朵俊绠?"&MyMailTotal&"</a> <a href="""&GetDomain&"User/User_Main.asp?wap="&wap&""">浼氩憳涓绩</a> "
       Else
   TempStr = TempStr &"<a href="""&GetDomain&"User/Userlogin.asp"">浼氩憳鐧婚檰</a> <a href="""&GetDomain&"User/UserReg.asp"">浼氩憳娉ㄥ唽</a>"
    End if
  GetTopUserLogin = TempStr
    End Function
 
 '**************************************************
 '鍑芥暟鍚嶏细GetUserLogin
 '浣? 鐢细鏄剧ず浼氩憳鐧诲綍鍏ュ彛(绔栨帓)
 '**************************************************
 Function GetUserLogin()
      If Cbool(UserLoginChecked)=True Then
      Dim MyMailTotal:MyMailTotal=Conn.Execute("Select Count(ID) From KS_Message Where Incept='" &User("UserName") &"' And Flag=0 and IsSend=1 and delR=0")(0)
      TempStr = TempStr & User("UserName")
   If (Hour(Now) < 6) Then
                TempStr = TempStr & "鍑屾櫒濂?<br/>"
   ElseIf (Hour(Now) < 9) Then
    TempStr = TempStr & "镞╀笂濂?<br/>"
   ElseIf (Hour(Now) < 12) Then
    TempStr = TempStr & "涓婂崃濂?<br/>"
   ElseIf (Hour(Now) < 14) Then
    TempStr = TempStr &"涓崃濂?<br/>"
   ElseIf (Hour(Now) < 17) Then
    TempStr = TempStr & "涓嫔崃濂?<br/>"
   ElseIf (Hour(Now) < 18) Then
    TempStr = TempStr & "鍌嶆櫄濂?<br/>"
   Else
    TempStr = TempStr & "鏅氢笂濂?<br/>"
   End If
   TempStr = TempStr &"<a href="""&GetDomain&"User/User_Message.asp?action=inbox&wap="&wap&""">鏀朵俊绠?"&MyMailTotal&"</a> <a href="""&GetDomain&"User/User_Main.asp?wap="&wap&""">浼氩憳涓绩</a> "
       Else
   TempStr = TempStr &"<a href="""&GetDomain&"User/Userlogin.asp"">浼氩憳鐧婚檰</a> <a href="""&GetDomain&"User/UserReg.asp"">浼氩憳娉ㄥ唽</a>"
    End if
  GetUserLogin = TempStr
    End Function
       
  '*********************************************************************************************************
  '鍑芥暟鍚嶏细GetSiteCountAll
  '浣? 鐢细镟挎崲缃戠珯缁熻镙囩涓哄唴瀹?
  '鍙? 鏁帮细Flag-0镐荤粺璁★紝1-鏂囩珷缁熻 2-锲剧墖缁熻
  '*********************************************************************************************************
  Function GetSiteCountAll()
     Dim ChannelTotal: ChannelTotal = Conn.Execute("Select Count(*) From KS_Class Where TN='0'")(0)
     Dim MemberTotal:MemberTotal=Conn.Execute("Select Count(*) From KS_User")(0)
     Dim CommentTotal: CommentTotal = Conn.Execute("Select Count(*) From KS_Comment")(0)
     Dim GuestBookTotal:GuestBookTotal=Conn.Execute("Select Count(ID) From KS_GuestBook")(0)
    
     GetSiteCountAll = GetSiteCountAll & "棰戦亾镐绘暟锛?" & ChannelTotal & " 涓?br/>"
     dim rsc:set rsc=conn.execute("select channelid,ItemName,Itemunit,channeltable from ks_channel where channelstatus=1 and channelid<>6 And ChannelID<>9")
     dim k,sql:sql=rsc.getrows(-1)
     rsc.close:set rsc=nothing
     for k=0 to ubound(sql,2)
     GetSiteCountAll = GetSiteCountAll & sql(1,k) & "镐绘暟锛?" & Conn.Execute("Select Count(id) From " & sql(3,k))(0) & " " & sql(2,k)&"<br/>"
     next
     GetSiteCountAll = GetSiteCountAll & "娉ㄥ唽浼氩憳锛?" & MemberTotal & " 浣?br/>"
     GetSiteCountAll = GetSiteCountAll & "鐣***█镐绘暟锛?" & GuestBookTotal &" 鏉?br/>"
     GetSiteCountAll = GetSiteCountAll & "璇勮镐绘暟锛?" & CommentTotal & " 鏉?br/>"
     GetSiteCountAll = GetSiteCountAll
  End Function
  
  
 '**************************************************
 '鍑芥暟鍚嶏细PindaoDaohang
 '浣? 鐢细鍙栧嚭棣栭〉棰戦亾瀵艰埅
 '鍙? 鏁帮细num--涓€琛屾爮鐩暟閲?Fenge--鍒嗛殧绗﹀佛(鏀寔WML璇█)
 '**************************************************
 Function PindaoDaohang(num,Fenge)
        Set Rs=Conn.Execute("select ChannelID from KS_Channel where ChannelStatus=1 and WapSwitch=1")
    If Rs.eof then  ChannelID="0":Rs.Close:Set Rs=Nothing
       SQL=Rs.GetRows(-1):Rs.Close:Set Rs = Nothing
             For I=0 To Ubound(SQL,2)
      ChannelID = ChannelID & Trim(SQL(0,I)) & ","
    Next
       ChannelID = Left(Trim(ChannelID), Len(Trim(ChannelID)) - 1) '铡绘帀链€鍚庝竴涓€楀佛
  Set Rs=Conn.Execute("select ClassID,FolderName,ChannelID from KS_Class where TN='0' and ChannelID In (" & ChannelID & ") and WapSwitch=1 order by FolderOrder asc")
  If Rs.eof then
     TempStr = "镇ㄨ缮娌℃湁棰戦亾镙忕洰锛?br/>"
  Else
        o=1
     do while not Rs.eof
        TempStr = TempStr &"<a href="""&GetDomain&"Wap_ShowClass.asp?id="&Rs("ClassID")&"&ChannelID="&Rs("ChannelID")&"&wap="&wap&""">"&Rs("FolderName")&"</a>"
     if o Mod num=0 or o=Rs.recordcount then
           TempStr = TempStr &"<br/>"
     else
           TempStr = TempStr &Fenge
     end if
     o=o+1
     Rs.movenext
     loop
  End if
      PindaoDaohang=TempStr
   End Function


'**************************************************
'鍑芥暟鍚嶏细Sousuolanmu
'浣? 鐢细鍙栧嚭棣栭〉鎼灭储
'鍙? 鏁帮细num--涓€琛屾爮鐩暟閲?Fenge--鍒嗛殧绗﹀佛(鏀寔WML璇█)
'**************************************************
Function Sousuolanmu(num,Fenge)
    TempStr = "<input name=""keyword"" type=""text"" size=""20"" value=""""/><br/>"
    Set Rs=Server.CreateObject("ADODB.RECORDSET")
        Rs.open "select ChannelID,ItemName from KS_Channel where ChannelStatus=1 and WapSwitch=1 order by ChannelID desc",conn,1,1
    If Not Rs.EOF Then
     o=1
     Do While Not Rs.Eof
     TempStr = TempStr &"<anchor>"&Rs("ItemName")&"<go href="""&GetDomain&"Wap_Search.asp?searchtype=1&wap="&wap&""" method=""post""><postfield name=""keyword"" value=""$(keyword)""/><postfield name=""ChannelID"" value="""&Rs("ChannelID")&"""/></go></anchor>"
             If o Mod num=0 or o=Rs.recordcount Then
             TempStr = TempStr &"<br/>"
       Else
                         TempStr = TempStr &Fenge
                   End If
     o=o+1
     Rs.MoveNext
     Loop
    End If
  Rs.Close:Set Rs=Nothing
 Sousuolanmu=TempStr
End Function



'**************************************************
'鍑芥暟鍚嶏细GetHomepageRowform
'浣? 鐢细鍙栧嚭棣栭〉"鐑棬,链€鏂?鎺ㄨ崘,闅忔満"鍒楄〃
'鍙? 鏁帮细ChannelID--妯″瀷ID,Liebiao--鐑棬"1"链€鏂?2"鎺ㄨ崘"3"闅忔満"4",daohang--瀵艰埅绫诲瀷(鏀寔WML璇█),num--鏄剧ず璁板綍鏁?lennum--阈炬帴镙囬瀛楃)
'**************************************************
Function GetHomepageRowform(ChannelID,Liebiao,Daohang,num,lennum)
    on error resume next
 Set Rs=Conn.Execute("select ChannelTable From KS_Channel Where ChannelID="&ChannelID&" and WapSwitch=1 order by ChannelID")
 
 Set Rs1=Conn.Execute("Select ID From KS_Class Where DelTF=0 AND WapSwitch=1 AND ChannelID="&ChannelID&"")
 If Rs1.EOF Then Tid="'0'"
 SQL=Rs1.GetRows(-1)
 Rs1.Close:Set Rs1 = Nothing
 For I=0 To Ubound(SQL,2)
        Tid = Tid & "'" & Trim(SQL(0,I)) & "',"
    Next
    Tid = Left(Trim(Tid), Len(Trim(Tid)) - 1) '铡绘帀链€鍚庝竴涓€楀佛
 
 Select Case Liebiao
 Case 1'鐑棬
 SqlStr="select top "&num&" id,Title,Hits from "&Rs("ChannelTable")&" Where Tid In ("&Tid&") And Verific=1 And DelTF=0 order by Hits Desc"
 Case 2'链€鏂?
 SqlStr="select top "&num&" id,Title,Hits from "&Rs("ChannelTable")&" where Tid In ("&Tid&") And Verific=1 order by AddDate desc"
 Case 3'鎺ㄨ崘
 SqlStr="select top "&num&" id,Title,Hits from "&Rs("ChannelTable")&" where Tid In ("&Tid&") And Verific=1 And Recommend=1 order by ID desc"
 Case 4'闅忔満
 If DataBaseType=0 then
    Randomize()
    SqlStr="select top "&num&" id,Title,Hits from "&Rs("ChannelTable")&" where Tid In ("&Tid&") And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
 Else
    SqlStr="select top "&num&" id,Title,Hits from "&Rs("ChannelTable")&" where Tid In ("&Tid&") And Verific=1 order by newid()"
 End if
 End Select 
 set Rsc=Conn.Execute(SqlStr)
 If Rsc.bof and Rsc.eof then
    TempStr = "娌℃湁鍐呭锛?br/>"
 Else
 do while not Rsc.eof
     TempStr = TempStr &""&daohang&"<a href="""&Setting(109)&"Wap_ShowInfo.asp?id="&Rsc("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rsc("Title"),lennum)&"</a>("&Rsc("Hits")&")<br/>"
 Rsc.MoveNext
 Loop
 End if
 Rsc.Close:set Rsc=nothing
 Rs.Close:set Rs=nothing


 GetHomepageRowform=TempStr
End Function


        'Tags阃氱敤镙囩
  Function GetTags(TagType,Num)
    If not isnumeric(num) Then Exit Function
    dim sqlstr,sql,i,n,str
    select case cint(tagtype)
     case 1:sqlstr="select top 500 keytext,channelid,hits from ks_keywords order by hits desc"
     case 2:sqlstr="select top 500 keytext,channelid,hits from ks_keywords order by lastusetime desc,id desc"
     case 3:sqlstr="select top 500 keytext,channelid,hits from ks_keywords order by Adddate desc,id desc"
     case else
      GetTags="":Exit Function
    end select
   
    dim Rs:set Rs=Conn.Execute(sqlstr)
    If Rs.eof Then Rs.close:set Rs=nothing:Exit Function
    sql=Rs.getrows(-1)
    Rs.close:set Rs=nothing
    For i=0 To ubound(sql,2)
     If FoundInArr(str,sql(0,i),",")=False Then
      n=n+1
      str=str & "," & sql(0,i)
      gettags=gettags & "<a href="""&Setting(3) & Setting(109)&"Wap_Search.asp?searchtype=5&channelid=" & sql(1,i) & "&tags=" & sql(0,i)& "&wap"&wap&""">" & sql(0,i) & "</a> "
     End If
     If n>=cint(num) Then Exit For
    Next
   
  End Function
    
  'Tags阃氱敤镙囩 
  Function ReplaceKeyTags(ChannelID,KeyStr)
    On error resume next
    Dim I,K_Arr:K_Arr=Split(KeyStr,"|")
    For I=0 To Ubound(K_Arr)
      ReplaceKeyTags=ReplaceKeyTags & "<a href=""" & Setting(3) & Setting(109) & "Wap_Search.asp?searchtype=5&channelid=" & channelid & "&tags=" & K_Arr(i) & "&wap="&wap&""">" & K_Arr(i) & "</a> "
    Next
    If Err Then ReplaceKeyTags="":Err.Clear
  End Function
  
  '=================================================
  '鍑芥暟鍚嶏细GetPourWhileaccount
  '浣? 鐢细鏄剧ず链掕镞?
  '鍙? 鏁帮细StrExplain--璇存槑锛孲trTime--镞堕棿
  '=================================================
  Function GetPourWhileaccount(StrExplain,StrTime)
      GetPourWhileaccount = StrExplain&Datediff("d",Date(),StrTime)&"澶?
  End Function
  
  '=================================================
  '鍑芥暟鍚嶏细GetVote
  '浣? 鐢细鏄剧ず缃戠珯璋冩煡
  '鍙? 鏁帮细镞?
  '=================================================
  Function GetVote(VoteID)
      On Error Resume Next
   dim sqlVote,rsVote
   sqlVote="select Title from KS_Vote where ID=" & VoteID & ""
   Set rsVote= conn.execute(sqlvote)
   if rsVote.bof and rsVote.eof then
    GetVote="娌℃湁浠讳綍璋冩煡!"
   else
    GetVote="<a href="""&GetDomain&"Wap_Vote.asp?Action=Show&ID=" & VoteID &"&wap=" & wap & """>"&rsVote("Title")&"</a>"
   end if
   rsVote.close:set rsVote=nothing
  End Function
  
  '鏄剧ず浼氩憳鎺掕
  Function GetTopUser(Num,MoreStr)
   Dim Sql,I
   Dim RSObj:Set RSObj=Conn.execute("Select Top " & Num &" UserID,UserName,LoginTimes From KS_User Order BY LoginTimes Desc,UserID Desc")
    SQL = RSObj.GetRows(-1)
   RSObj.Close : Set RSObj = Nothing
   For i = 0 to UBound(SQL,2)
    GetTopUser = GetTopUser & i+1 & ".<a href=""" & GetDomain & "User/ShowUser.asp?Keyword=" & SQL(1,I) & "&wap="&wap&""">" & SQL(1,i) & "</a>" & SQL(2,I) & "<br/>"
   Next
   GetTopUser=GetTopUser & "<a href=""" & GetDomain & "User/UserList.asp?wap="&wap&""">" & MoreStr & "</a>"
  End Function
  '=================================================
  '鍑芥暟鍚嶏细GetAnnounce
  '浣? 鐢细鏄剧ず缃戠珯鍏憡
  '鍙? 鏁帮细镞?
  '=================================================
  Function GetAnnounce(AnnounceID)
      On Error Resume Next
   dim sqlAnnounce,rsAnnounce
   sqlAnnounce="select Title from KS_Announce where ID=" & AnnounceID & ""
   Set rsAnnounce= conn.execute(sqlAnnounce)
   if rsAnnounce.bof and rsAnnounce.eof then
    GetAnnounce="娌℃湁浠讳綍鍏憡!"
   else
    GetAnnounce="<a href="""&GetDomain&"Wap_Announce.asp?AnnounceID=" & AnnounceID &"&wap=" & wap & """>"&rsAnnounce("Title")&"</a>"
   end if
   rsAnnounce.close:set rsAnnounce=nothing
  End Function
  '=================================================
  '鍑芥暟鍚嶏细GetWenhouyu
  '浣? 鐢细鏄剧ず涓嶅悓镞舵涓嶅悓镄勯棶链***
  '鍙? 鏁帮细镞?
  '=================================================
  Function GetWenhouyu(str1,str2,str3,str4,str5,str6,str7,str8)
      mytime=now
   myhour=hour(mytime)
   If myhour<6 or myhour>=22 Then GetWenhouyu = str1
   If myhour>=6 And myhour<=9 Then GetWenhouyu = str2
   If myhour>=9 And myhour<=12 Then GetWenhouyu = str3
   If myhour>=12 And myhour<=14 Then GetWenhouyu = str4
   If myhour>=14 And myhour<=17 Then GetWenhouyu = str5
   If myhour>=17 And myhour<=18 Then GetWenhouyu = str6
   If myhour>=18 And myhour<=19 Then GetWenhouyu = str7
   If myhour>=19 And myhour<=22 Then GetWenhouyu = str8
  End Function
  
'**************************************************
'鍑芥暟鍚嶏细Folder
'浣? 鐢细鍙栧嚭镙忕洰鍚岖О
'杩斿洖链硷细镙忕洰鍚岖О
'**************************************************
Function Folder()
      On Error Resume Next
   Folder=Conn.Execute("select FolderName from ks_Class where ClassID="&ClassID&"")(0)
   If Err Then Folder=""
End Function


'**************************************************
'鍑芥暟鍚? FolderID
'锷?鑳?鍙栧缑鐩綍ID
'**************************************************
Function FolderID()
     On Error Resume Next
     FolderID=Conn.Execute("select ID from ks_Class where ClassID="&ClassID&"")(0)
  If Err Then FolderID=""
End Function
'**************************************************
'鍑芥暟鍚嶏细FanhuiLanmu
'浣? 鐢细鏄剧ず镙忕洰鍒楄〃椤佃繑锲为阆挞椤?
'**************************************************
Function FanhuiLanmu()
    On Error Resume Next
    ID=conn.execute("select TN from ks_Class where ClassID="&ClassID&"")(0)
    Set Rs=conn.execute("select ClassID,FolderName,ChannelID from ks_Class where ID='"&ID&"'")
 If not(Rs.bof and Rs.eof) Then
    TempStr = "<a href=""Wap_ShowClass.asp?id="&Rs("ClassID")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&Rs("FolderName")&"</a> "
    End If
 Rs.close:Set Rs=Nothing
 FanhuiLanmu = TempStr
End Function


'**************************************************
'鍑芥暟鍚嶏细ReturnRowform
'浣? 鐢细鏄剧ず鍐呭椤佃繑锲炴爮鐩垪琛ㄩ〉
'**************************************************
Function ReturnRowform()
    On Error Resume Next
    Tid=Conn.Execute("select Tid from "&Channel("ChannelTable")&" where id="&ClassID&"")(0)
 Set Rs=conn.execute("select ClassID,FolderName from ks_Class where ID='"&Tid&"'")
 If not(Rs.bof and Rs.eof) Then
       ReturnRowform="<a href=""wap_ShowClass.asp?id="&Rs("ClassID")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&Rs("FolderName")&"</a>"
 End If
 Rs.close:Set Rs=Nothing
End Function
'**************************************************
'鍑芥暟鍚嶏细Categorize
'浣? 鐢细鍙栧嚭棰戦亾镙忕洰鍒楄〃
'鍙? 鏁帮细num--涓€琛屾爮鐩暟閲?Fenge--鍒嗛殧绗﹀佛(鏀寔WML璇█)
'**************************************************
Function Categorize(num,Fenge)
   set Rs=server.createobject("ADODB.Recordset")
   Rs.open "select * from ks_Class where TN='"&FolderID&"' and WapSwitch=1 order by FolderOrder asc",Conn
   If Rs.eof Then
      TempStr = "娌℃湁棰戦亾鍒嗙被锛?br/>"
   Else
      o=1
   Do while not Rs.eof
      TempStr = TempStr &"<a href=""wap_ShowClass.asp?id="&Rs("ClassID")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&Rs("FolderName")&"</a>"
   If o Mod num=0 or o=Rs.recordcount Then
      TempStr = TempStr &"<br/>"
   Else
      TempStr = TempStr &Fenge
   End If
   o=o+1
   Rs.movenext
   Loop
   End If
   Rs.Close:set Rs=nothing
   Categorize = TempStr
End Function


'**************************************************
'鍑芥暟鍚?GetFolderTid
'锷?鑳?鍙栧缑瀛愮洰褰旷殑ID板嗗悎
'鍙?鏁?  FolderID鐖剁洰褰旾D
'杩斿洖链? 褰㈠ 111111,222222,333333镄処D板嗗悎
'**************************************************
Function GetFolderTid(FolderID)
   On Error Resume Next
   Dim I,Tid,SQL
   Dim Rs:Set Rs=Conn.Execute("Select ID From KS_Class Where DelTF=0 AND WapSwitch=1 AND TS LIKE '%" & FolderID & "%'")
   If Rs.EOF Then GetFolderTid="'0'":Rs.Close:Set Rs=Nothing:Exit Function
   SQL=Rs.GetRows(-1):Rs.Close:Set Rs = Nothing
   For I=0 To Ubound(SQL,2)
       Tid = Tid & "'" & Trim(SQL(0,I)) & "',"
   Next
   Tid = Left(Trim(Tid), Len(Trim(Tid)) - 1) '铡绘帀链€鍚庝竴涓€楀佛
   GetFolderTid = Tid
End Function


'**************************************************
'鍑芥暟鍚嶏细GetContentsRowform
'浣? 鐢细鍙栧嚭"鐑棬,链€鏂?鎺ㄨ崘,闅忔満"鍒楄〃
'鍙? 鏁帮细Liebiao--鐑棬"1"链€鏂?2"鎺ㄨ崘"3"闅忔満"4",daohang--瀵艰埅绫诲瀷(鏀寔WML璇█),num--鏄剧ず璁板綍鏁?lennum--阈炬帴镙囬瀛楃)
'**************************************************
Function GetContentsRowform(Liebiao,daohang,num,lennum)
    On Error Resume Next   
 Select Case Liebiao
 Case 1'鐑棬
 SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" Where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 And DelTF=0 order by Hits Desc"
 Case 2'链€鏂?
 SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by AddDate desc"
 Case 3'鎺ㄨ崘
 SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 And Recommend=1 order by ID desc"
 Case 4'闅忔満
 If DataBaseType=0 then
    Randomize()
    SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
 Else
    SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by newid()"
 End if
 End Select
 set Rs=Conn.Execute(SqlStr)
 If Rs.bof and Rs.eof then
    TempStr = "娌℃湁鍐呭锛?br/>"
 Else
 do while not Rs.eof
     TempStr = TempStr &""&daohang&"<a href=""wap_ShowInfo.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("Title"),lennum)&"</a>("&Rs("Hits")&")<br/>"
 Rs.MoveNext
 Loop
 End if
 Rs.Close:set Rs=nothing
 GetContentsRowform = TempStr
End Function


'**************************************************
'鍑芥暟鍚嶏细GetRandomDiagramText
'浣? 鐢细鍙栧嚭闅忔満锲炬枃
'鍙? 鏁帮细lennum--阈炬帴镙囬瀛楃)
'**************************************************
Function GetRandomDiagramText(lennum)
    On Error Resume Next
 Randomize()
 set Rs=server.createobject("adodb.recordset")
 Select Case Channel("BasicType")
      Case 1  
   If DataBaseType=0 then
      sql="select top 1 id,Title,PicUrl,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
   Else
      sql="select top 1 id,Title,PicUrl,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by newid()"
   End if
   Case 2  
   If DataBaseType=0 then
      sql="select top 1 id,Title,PhotoUrl,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
   Else
      sql="select top 1 id,Title,PhotoUrl,Hits from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by newid()"
   End if
   Case 3
   If DataBaseType=0 then
   sql="select top 1 id,Title,PhotoUrl,Hits,DownPT from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
   Else
      sql="select top 1 id,Title,PhotoUrl,Hits,DownPT from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by newid()"
   End if
   Case 5
   If DataBaseType=0 then
   sql="select top 1 id,Title,PhotoUrl,Unit,Price_Market,Price,Price_Member,Point from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
   Else
      sql="select top 1 id,Title,PhotoUrl,Unit,Price_Market,Price,Price_Member,Point from "&Channel("ChannelTable")&" where Tid In ("&GetFolderTid(FolderID)&") And Verific=1 order by newid()"
   End if
   End Select
   set Rs=Conn.Execute(Sql)
   If Rs.bof And Rs.eof Then
      TempStr = "娌℃湁鍐呭锛?br/>"
   Else
     Select Case Channel("BasicType")
         Case 1
         TempStr = "<img src="""&Rs("PicUrl")&""" width=""100"" height=""100""/><br/>"
      TempStr = TempStr & "<a href=""wap_ShowInfo.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("Title"),lennum)&"</a>("&Rs("Hits")&")<br/>"
      Case 2
      TempStr = "<img src="""&Rs("PhotoUrl")&""" width=""100"" height=""100""/><br/>"
      TempStr = TempStr & "<a href=""wap_ShowInfo.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("Title"),lennum)&"</a>("&Rs("Hits")&")<br/>"
      Case 3
      TempStr = "<img src="""&Rs("PhotoUrl")&""" width=""100"" height=""100""/><br/>"
      TempStr = TempStr &"<a href=""wap_ShowInfo.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("Title"),lennum)&"</a>("&Rs("Hits")&")<br/>"
      If Rs("DownPT")<>"" Then TempStr = TempStr & ""&GotTopic(Rs("DownPT"),lennum)&"<br/>"
      Case 5
      TempStr = "<img src="""&Rs("PhotoUrl")&""" width=""100"" height=""100""/><br/>"
      TempStr = TempStr &"<a href=""wap_ShowInfo.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("Title"),lennum)&"</a><br/>"
      TempStr = TempStr & "<a href=""ShoppingCart.asp?ProductList="&Rs("id")&"&wap="&wap&""">锷犲叆璐墿杞?/a> <a href=""wap_Favorite.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">锷犲叆鏀惰棌澶?/a><br/>"
      TempStr = TempStr & "甯傚満:"&Rs("Price_Market")&"/"&Rs("Unit")&" 浼氩憳:"&Rs("Price_Member")&"/"&Rs("Unit")&" 璐墿绉垎:"&Rs("Point")&"/"&Rs("Unit")&"<br/>"
   End Select
 End IF
 Rs.Close:set Rs=nothing
 GetRandomDiagramText = TempStr
End Function


'**************************************************
'鍑芥暟鍚嶏细Commentary
'浣? 鐢细鍙栧嚭璇勮
'杩斿洖链硷细璇勮
'**************************************************
Function Commentary(num,lennum)
   On Error Resume Next
   Comment=Conn.Execute("select Comment from "&Channel("ChannelTable")&" where id="&ClassID&"")(0)
   If Comment=1 Then
      Dim k,str:str="鎯婅|鎾囧槾|鑹瞸鍙戝憜|寰楁剰|娴佹唱|瀹崇緸|闂槾|镌澶у摥|灏村艾|鍙戞€抾璋幂毊|锻茬堕|寰瑧|闅捐绷|閰穦闱炲吀|鎶撶妫|鍚恷"
   Dim strArr:strArr=Split(str,"|")
   TempStr = TempStr &"<select name=""insertface"">"
   TempStr = TempStr &"<option value="""">镞?/option>"
   For K=0 to 19
       TempStr = TempStr &"<option value=""[e"&K&"]"">" & strArr(k) & "</option>"
   Next
   TempStr = TempStr &"</select>"
      TempStr = TempStr &"<input name=""C_Content"&minute(now)&second(now)&""" type=""text"" size=""20"" value=""涓嶉敊!椤?""/>"
   TempStr = TempStr &"<anchor>鍙戣〃璇勮<go href=""wap_Comment.asp?Action=WriteSave&ChannelID="&ChannelID&"&InfoID="&ClassID&"&wap="&wap&""" method=""post"">"
   TempStr = TempStr &"<postfield name=""insertface"" value=""$(insertface)""/><postfield name=""C_Content"" value=""$(C_Content"&minute(now)&second(now)&")""/>"
   TempStr = TempStr &"</go></anchor><br/>"
   Set Rs = Server.CreateObject("ADODB.Recordset")
   Rs.open "Select top "&num&" Content from KS_Comment where Verific=1 And ChannelID="&ChannelID&" And InfoID="&ClassID&" order by ID desc",Conn,1,2
   If not Rs.EOF Then
      j=0
   do while ((not Rs.EOF) and j<=clng(num))
      TempStr = TempStr &""&j+1&"."&ReplaceFace(GotTopic(Rs("Content"),lennum))&"<br/>"
   Rs.MoveNext
   j=j+1
   loop
   End If
   TempStr = TempStr &"<a href=""wap_Comment.asp?Action=CommentMain&ChannelID="&ChannelID&"&InfoID="&ClassID&"&wap="&wap&""">镟村璇勮("&Conn.Execute("Select Count(ID) From KS_Comment Where Verific=1 And ChannelID="&ChannelID&" And InfoID="&ClassID&"")(0)&"鏉?</a><br/>"
   End If
   Commentary = TempStr
End Function


Function ReplaceFace(c)
 Dim K
 For K=0 To 19
     c=Replace(c,"[e"&K &"]","<img src=""" & Setting(3) & "images/emot/" & K & ".gif"" />")
 Next
 ReplaceFace=C
End Function



'**************************************************
'鍑芥暟鍚嶏细GetContentsRandom
'浣? 鐢细鏄剧ず鍐呭椤甸殢链哄垪琛?
'鍙? 鏁帮细daohang--瀵艰埅绫诲瀷(鏀寔WML璇█),num--鏄剧ず璁板綍鏁?lennum--阈炬帴镙囬瀛楃)
'**************************************************
Function GetContentsRandom(daohang,num,lennum)
    On Error Resume Next
 If DataBaseType=0 then
    Randomize()
    SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" where Tid='"&WapStr("Tid")&"' And Verific=1 order by Rnd("&-1*(Int(1000*Rnd)+1)&"*ID)"
 Else
    SqlStr="select top "&num&" id,Title,Hits from "&Channel("ChannelTable")&" where Tid='"&WapStr("Tid")&"' And Verific=1 order by newid()"
 End if
 set Rs=Conn.Execute(SqlStr)
 If Rs.bof and Rs.eof then
    TempStr = "娌℃湁鍐呭锛?br/>"
 Else
 do while not Rs.eof
     TempStr = TempStr &""&daohang&"<a href=""wap_ShowInfo.asp?id="&Rs("id")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("Title"),lennum)&"</a>("&Rs("Hits")&")<br/>"
 Rs.MoveNext
 Loop
 End if
 Rs.Close:set Rs=nothing
 GetContentsRandom = TempStr
End Function



'**************************************************
'鍑芥暟鍚嶏细TopAndBottom
'浣? 鐢细涓娄竴绡囥€佷笅涓€绡?
'鍙? 鏁帮细lennum阈炬帴镙囬瀛楃
'**************************************************
Function TopAndBottom(lennum)
   On Error Resume Next
   Tid=Conn.Execute("select Tid from "&Channel("ChannelTable")&" where id="&ClassID&"")(0)
   set Rs=Server.CreateObject("ADODB.Recordset")
   sql = "select ID,title from "&Channel("ChannelTable")&" where id<"&ClassID&" and Tid='"&Tid&"' order by id DESC"
   Rs.open sql,Conn,1,2
   If not Rs.eof Then
      TempStr = "涓?<a href=""wap_ShowInfo.asp?id="&Rs("ID")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&Rs("title")&"</a><br/>"
   Else
      TempStr = "涓?娌℃湁浜?br/>"
   End If
   Rs.Close:set Rs=nothing
   set Rs=Server.CreateObject("ADODB.Recordset")
   sql = "select ID,title from "&Channel("ChannelTable")&" where id>"&ClassID&" and Tid='"&Tid&"' order by id ASC"
   Rs.open sql,Conn,1,2
   If not Rs.eof Then
      TempStr = TempStr &"涓?<a href=""wap_ShowInfo.asp?id="&Rs("ID")&"&ChannelID="&ChannelID&"&wap="&wap&""">"&GotTopic(Rs("title"),lennum)&"</a><br/>"
   Else
      TempStr = TempStr&"涓?娌℃湁浜?br/>"
   End If
   Rs.Close:set Rs=nothing
   TopAndBottom = TempStr
End Function


'**************************************************
'鍑芥暟鍚嶏细WapStr
'浣? 鐢细鍙栧嚭琛ㄥ瓧娈典腑鍐呭
'鍙? 鏁帮细Command--镆ヨ鏁版嵁浠g爜,WordSegment--琛ㄥ瓧娈靛悕绉?
'**************************************************
Function WapStr(Byval str)
    On Error Resume Next
    WapStr=Conn.Execute("select "&str&" from "&Channel("ChannelTable")&" where id="&ClassID&"")(0)
 If Err Then WapStr=""
End Function


'锲剧墖====================================================================================================
'**************************************************
'鍑芥暟鍚嶏细GetPictureByPage
'浣? 鐢细鍙栧嚭镆ョ湅锲剧墖鍐呭锛堜笂涓€椤点€佷笅涓€椤垫柟寮忥级
'**************************************************
Function GetPictureByPage()
   On Error Resume Next
   CurrPage=ChkClng(S("Page"))
   If CurrPage<=0 Then CurrPage=1
   PhotoContent=WapStr("PicUrls")
   PicUrlsArr = Split(PhotoContent, "|||")
   TotalPage = Cint(UBound(PicUrlsArr) + 1)


   Cols=ChkClng(S("Cols"))
   If Cols<=0 Then Cols=2
  
   if ((ubound(PicUrlsArr)+1) mod cols)=0 then
   Tpage=(ubound(PicUrlsArr)+1)\cols
   else
   Tpage=(ubound(PicUrlsArr)+1)\cols + 1
   end if 
   If TPage<>1 Then
   If CurrPage=1 Then
      PageStr = PageStr & "姣忛〉鏄?"
   If Cols=2 Then
      PageStr = PageStr & "2 "
   Else
      PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols=2&wap="&wap&""" >2</a> "
   End If
   If Cols=4 Then
      PageStr = PageStr & "4 "
   Else
      PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols=4&wap="&wap&""" >4</a> "
   End If
   If Cols=6 Then
      PageStr = PageStr & "6"
   Else
      PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols=6&wap="&wap&""" >6</a>"
   End If
   PageStr = PageStr & Channel("ItemUnit")&"<br/>"
   End If
   End If
  
   If TotalPage > 2 Then
   If BusinessVersion = 0 Then
      PageStr = PageStr & ""
   Else
      PageStr = PageStr & "<a href=""Wap_PhotoBroadcast.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&""">镊姩鎾斁</a><br/>"
   End if
   End if
  
   If ChkCLng(S("Page"))<=1 Then
      n=0
   Else
      n=cols*(CurrPage-1)
   End If
  
   For c=1 To Cols
       dim thumbsphoto
    if n<=ubound(PicUrlsArr) Then
       PageStr = PageStr & "<img src="""&Split(PicUrlsArr(n),"|")(1)&""" width=""100"" height=""100"" alt=""璇风◢链?.."" /><br/>"
    If BusinessVersion = 0 Then
       PageStr = PageStr & "<a href="""&Split(PicUrlsArr(n),"|")(2)&""">涓嬭浇"&Split(PicUrlsArr(n),"|")(0)&"</a><br/>"
    Else
       ImgUrl = Split(PicUrlsArr(n),"|")(2)
       If left(Split(PicUrlsArr(n),"|")(2),7)="http://" Then
       PageStr = PageStr & "<a href=""Wap_PhotoFile.asp?Action=PhotoMore&ImgUrl="&ImgUrl&""">涓嬭浇</a> "
    PageStr = PageStr & "<a href=""Wap_PhotoFile.asp?Action=PhotoShow&ImgUrl="&ImgUrl&""">缂╂斁</a> "
    PageStr = PageStr & "<a href=""Wap_PhotoFile.asp?Action=PhotoImg&ImgUrl="&ImgUrl&""">楂樼骇</a><br/>"  
       Else 
       PageStr = PageStr & "<a href=""Wap_PhotoMore.asp?ImgUrl="&ImgUrl&"&wap="&wap&""">涓嬭浇</a> "
    PageStr = PageStr & "<a href=""Wap_PhotoShow.asp?ImgUrl="&ImgUrl&"&wap="&wap&""">缂╂斁</a> "
    PageStr = PageStr & "<a href=""Wap_PhotoImg.asp?ImgUrl="&ImgUrl&"&wap="&wap&""">楂樼骇</a><br/>"  
       End if
    End if
    else
       PageStr = PageStr & ""
    end if
    n=n+1
    Next


    startpage=1:k=0
 if TPage<>1 then
 if (CurrPage>=10) then startpage=(CurrPage\10-1)*10+CurrPage mod 10+2
    PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols="&Cols&"&wap="&wap&""" >棣栭〉</a> "
    if CurrPage<>1 then
       PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols="&Cols&"&Page="&CurrPage-1&"&wap="&wap&""">涓娄竴椤?/a> "
    end if
    If CurrPage <>tpage Then
       PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols="&Cols&"&Page="&currpage+1&"&wap="&wap&""">涓嬩竴椤?/a> "
    end if
       PageStr = PageStr & "<a href=""Wap_ShowInfo.asp?ID="&ClassID&"&ChannelID="&ChannelID&"&Cols="&Cols&"&page="&tpage&"&wap="&wap&""" >链〉</a> "
       PageStr = PageStr & "<br/>链?&Channel("ItemName")&"鍏?"&TPage&"/"&CurrPage&"椤?
  end if
 GetPictureByPage = PageStr
End Function


'**************************************************
'鍑芥暟鍚?ContentGengduo
'锷?鑳?鍙栧缑浠嬬粛
'鍙?鏁?strContent--鍐呭,stLennum--浠嬬粛瀛楃,strUrl--鎴浘鍦板潃
'**************************************************
Function ContentGengduo(Byval strContent,Byval stLennum,Byval strUrl)
    On Error Resume Next
    stLennum=CLng(stLennum)
    strContent = LoseHtml(HTMLCode(strContent))
    If len(strContent)<stLennum then
       TempStr = strContent
 Else
       strContent=mid(strContent,1,stLennum)
    TempStr = strContent &"...<a href=""Wap_Gengduo.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&""">镟村>></a> "
    End if
 If strUrl<>"" then
    TempStr = TempStr &"<a href=""wap_DownPic.asp?url="&strUrl&"&wap="&wap&""">鎴浘</a>"
 End if
  ContentGengduo = TempStr
End Function



'涓嬭浇====================================================================================================


'鏅€氢笅杞藉湴鍧€
Function GetDownAddress()
 UrlArr = Split(WapStr("DownUrls"), "|||")
 TotalNum = UBound(UrlArr)
 For I = 0 To TotalNum
        N=N+1
  AUrl = Split(UrlArr(I), "|")
 If AUrl(0)=0 Then
 UrlStr=UrlStr&"<a href=""Wap_DownLoad.asp?ChannelID="&ChannelID&"&ID="&ClassID&"&DownID="&N&"&wap="&wap&""">"&AUrl(1)&"</a><br/>"
 End If
 Next
 GetDownAddress=UrlStr
End Function


 


 



  '**************************************************
  '鍑芥暟鍚嶏细KSLabelReplaceAll
  '浣? 鐢细镟挎崲阃氱敤镙囩涓哄唴瀹?
  '鍙? 鏁帮细FileContent铡熸枃浠?
  '**************************************************
  Function KSLabelReplaceAll(F_C)
      On Error Resume Next  '瀹归敊浠g爜
   '镟挎崲镊畾涔夊嚱鏁版爣绛?
   F_C = ReplaceUserFunctionLabel(F_C)
   '===============缃戠珯甯哥敤镙囩===============
   If InStr(F_C, "{$ClassID}") <> 0 Then F_C = Replace(F_C,"{$ClassID}",ClassID)
   If InStr(F_C, "{$ChannelID}") <> 0 Then F_C = Replace(F_C,"{$ChannelID}",ChannelID)
   If InStr(F_C, "{$wap}") <> 0 Then F_C = Replace(F_C,"{$wap}",wap)''鍙栧嚭WAP链?
   If InStr(F_C, "{$GetCopyRight}") <> 0 Then F_C = Replace(F_C,"{$GetCopyRight}",CopyRight)'鏄剧ず鐗堟潈淇℃伅
   If InStr(F_C, "{$GetRuntime}") <> 0 Then F_C = Replace(F_C,"{$GetRuntime}",Runtime)'鏄剧ず椤甸溃镓ц镞堕棿
   If InStr(F_C, "{$GetInstallDir}") <> 0 Then F_C = Replace(F_C,"{$GetInstallDir}",Setting(109))'WAP瀹夎鐩綍
   If InStr(F_C, "{$GetTopUserLogin}") <> 0 Then F_C = Replace(F_C,"{$GetTopUserLogin}",GetTopUserLogin)'鏄剧ず浼氩憳鐧诲綍鍏ュ彛(妯帓)
   If InStr(F_C, "{$GetUserLogin}") <> 0 Then F_C = Replace(F_C,"{$GetUserLogin}",GetUserLogin)'鏄剧ず浼氩憳鐧诲綍鍏ュ彛(绔栨帓)
   '骞垮憡浣嶉€氱敤镙囩
   If InStr(F_C, "{=GetAdvertise") <> 0 Then
      HtmlLabel = GetFunctionLabel(F_C, "{=GetAdvertise")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetAdvertise"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),GetAdvertise(Param(0)))
      Next
         End If
  
   'WAP镊畾涔夐〉闱?
   If InStr(F_C, "{=GetArticle") <> 0 Then
     HtmlLabel = GetFunctionLabel(F_C, "{=GetArticle")
     HtmlLabelArr=Split(HtmlLabel,"@@@")
     For I=0 To Ubound(HtmlLabelArr)
      Param = Split(GetFunctionLabelParam(HtmlLabelArr(I), "{=GetArticle"),",")
      F_C = Replace(F_C, HtmlLabelArr(I), "<a href="""&GetDomain&"Article.asp?id="&Param(0)&"&wap="&wap&""">"&Param(1)&"</a>")
     Next
   End If
   'Tags阃氱敤镙囩
   If InStr(F_C, "{=GetTags") <> 0 Then
     HtmlLabel = GetFunctionLabel(F_C, "{=GetTags")
     HtmlLabelArr=Split(HtmlLabel,"@@@")
     For I=0 To Ubound(HtmlLabelArr)
      Param = Split(GetFunctionLabelParam(HtmlLabelArr(I), "{=GetTags"),",")
      F_C = Replace(F_C, HtmlLabelArr(I), GetTags(Param(0),Param(1)))
     Next
   End If
   '鏄剧ず链掕镞?
   If InStr(F_C, "{=GetPourWhileaccount") <> 0 Then
     HtmlLabel = GetFunctionLabel(F_C, "{=GetPourWhileaccount")
     HtmlLabelArr=Split(HtmlLabel,"@@@")
     For I=0 To Ubound(HtmlLabelArr)
      Param = Split(GetFunctionLabelParam(HtmlLabelArr(I), "{=GetPourWhileaccount"),",")
      F_C = Replace(F_C, HtmlLabelArr(I), GetPourWhileaccount(Param(0),Param(1)))
     Next
   End If
   
   '鏄剧ず缃戠珯璋冩煡
   If InStr(F_C, "{=GetVote") <> 0 Then
      HtmlLabel = GetFunctionLabel(F_C, "{=GetVote")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetVote"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),GetVote(Param(0)))
      Next
         End If
   '鏄剧ず浼氩憳鎺掕
   If InStr(F_C, "{=GetTopUser") <> 0 Then
      HtmlLabel = GetFunctionLabel(F_C, "{=GetTopUser")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetTopUser"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),GetTopUser(Param(0),Param(1)))
      Next
         End If
   '鏄剧ず缃戠珯鍏憡
   If InStr(F_C, "{=GetAnnounce") <> 0 Then
      HtmlLabel = GetFunctionLabel(F_C, "{=GetAnnounce")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetAnnounce"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),GetAnnounce(Param(0)))
      Next
         End If
   
         If InStr(F_C, "{$GetSiteName}") <> 0 Then F_C = Replace(F_C, "{$GetSiteName}", Setting(0))'鏄剧ず缃戠珯鍚岖О
   If InStr(F_C, "{$GetSiteTitle}") <> 0 Then F_C = Replace(F_C, "{$GetSiteTitle}", Setting(1))'鏄剧ず缃戠珯镙囬
   '鏄剧ず褰揿墠镞堕棿
   If InStr(F_C, "{=GetAddDate") <> 0 Then
      HtmlLabel = GetFunctionLabel(F_C, "{=GetAddDate")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
       F_C = Replace(F_C, HtmlLabelArr(I),DateFormat(Now(),Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetAddDate"),",")(0)))
      Next
         End If
   
   If InStr(F_C, "{$GetSiteLogo}") <> 0 Then F_C = Replace(F_C,"{$GetSiteLogo}","<img src="""&Setting(106)&""" alt=""Logo...""/>")'鏄剧ず缃戠珯LOGO涓嶅甫鍙傛暟
   '镟挎崲缃戠珯Logo(甯﹀弬鏁?
   If InStr(F_C,"{=GetLogo")<>0 Then
      HtmlLabel = GetFunctionLabel(F_C,"{=GetLogo")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetLogo"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),"<img src="""&Setting(106)&""" width="""&Param(0)&""" height="""&Param(1)&""" alt=""Logo...""/>")
      Next
   End If
   If InStr(F_C, "{$GetSiteCountAll}") <> 0 Then F_C = Replace(F_C, "{$GetSiteCountAll}", GetSiteCountAll())'绔欑偣缁熻
   If InStr(F_C, "{$WeiduDuanxiaoxi}") <> 0 Then F_C = Replace(F_C, "{$WeiduDuanxiaoxi}", WeiduDuanxiaoxi)'鏄剧ず链鐭秷鎭?
   If InStr(F_C, "{$GetSiteOnline}") <> 0 Then F_C = Replace(F_C, "{$GetSiteOnline}", GetSiteOnline)'鏄剧ず鍦ㄧ嚎浜烘暟(镐诲湪绾匡细1浜?鐢ㄦ埛锛?浜?娓稿锛?浜?
   If InStr(F_C, "{$GetSiteUrl}") <> 0 Then F_C = Replace(F_C, "{$GetSiteUrl}", GetDomain)'鏄剧ず缃戠珯URL
   If InStr(F_C, "{$GetWebmaster}") <> 0 Then F_C = Replace(F_C, "{$GetWebmaster}", Setting(10))'鏄剧ず绔欓昵
   If InStr(F_C, "{$GetWebmasterEmail}") <> 0 Then F_C = Replace(F_C, "{$GetWebmasterEmail}", Setting(11))'鏄剧ず绔欓昵EMail
   If InStr(F_C, "{$GoBack}") <> 0 Then F_C = Replace(F_C,"{$GoBack}", "<anchor>杩斿洖涓婄骇<prev/></anchor>")'杩斿洖涓婄骇
   If InStr(F_C, "{$Fanhuishouye}") <> 0 Then F_C = Replace(F_C,"{$Fanhuishouye}", "<a href="""&Fanhuishouye&""">杩斿洖棣栭〉</a>")'鏄剧ず杩斿洖棣栭〉
   If InStr(F_C, "{$FanhuiLanmu}") <> 0 Then F_C = Replace(F_C,"{$FanhuiLanmu}", FanhuiLanmu)'鏄剧ず镙忕洰鍒楄〃椤佃繑锲为阆挞椤?
   If InStr(F_C, "{$ReturnRowform}") <> 0 Then F_C = Replace(F_C,"{$ReturnRowform}", ReturnRowform)'鏄剧ず鍐呭椤佃繑锲炴爮鐩垪琛ㄩ〉
  '===============绌洪棿阃氱敤镙囩===============
   If InStr(F_C, "{$GetBlogTotal}") <> 0 Then F_C = Replace(F_C,"{$GetBlogTotal}",GetBlogTotal)'缁熻淇℃伅
   If InStr(F_C, "{$ShowSearch}") <> 0 Then F_C = Replace(F_C,"{$ShowSearch}",GetSearch(UserName))'镞ヨ鎼灭储
   If InStr(F_C, "{$ShowUserInfo}") <> 0 Then F_C = Replace(F_C,"{$ShowUserInfo}",GetUserInfo(UserName))'鐢ㄦ埛淇℃伅
   '鏄剧ず鎴戠殑鍦扮洏阈炬帴鍦板潃
   If Cbool(UserLoginChecked)=False Then
      F_C = Replace(F_C,"{$WodeDipan}","")
   Else
      F_C = Replace(F_C,"{$WodeDipan}","<a href="""&GetDomain&"/User/User_Main.asp?wap="&wap&""">鎴戠殑鍦扮洏</a>")  
   End If
   If InStr(F_C, "{$Blog_User}") <> 0 Then F_C = Replace(F_C,"{$Blog_User}",Blog_User)'鏄剧ず涓汉缃戠珯鍐呭瀵艰埅阈炬帴鍦板潃
  '===============鍐呭阃氱敤镙囩===============
   '鍙戣〃璇勮
   If InStr(F_C,"{=Commentary")<>0 Then
      HtmlLabel = GetFunctionLabel(F_C,"{=Commentary")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=Commentary"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),Commentary(Param(0),Param(1)))
      Next
   End If
   '鏄剧ず涓娄竴绡囥€佷笅涓€绡?
   If InStr(F_C,"{=TopAndBottom")<>0 Then
      HtmlLabel = GetFunctionLabel(F_C,"{=TopAndBottom")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=TopAndBottom"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),TopAndBottom(Param(0)))
      Next
   End If
  '===============鏂囩珷鍐呭椤垫爣绛?==============
        If InStr(ItemUrl,"showinfo")<>0 or InStr(ItemUrl,"gengduo")<>0 Then
   If Channel("BasicType")=1 Then
      F_C = Replace(F_C,"{$GetArticleID}",WapStr("NewsID"))'褰揿墠鏂囩珷ID
   F_C = Replace(F_C,"{$InfoID}",WapStr("ID"))'褰揿墠鏂囩珷灏廔D
   F_C = Replace(F_C,"{$ItemName}",Channel("ItemName"))'褰揿墠椤圭洰鍚岖О
   F_C = Replace(F_C,"{$ItemUnit}",Channel("ItemUnit"))'褰揿墠椤圭洰鍗曚綅
   F_C = Replace(F_C,"{$GetArticleShortTitle}",WapStr("Title"))'绠€鐭爣棰?
   F_C = Replace(F_C, "{$GetKeyTags}",ReplaceKeyTags(ChannelID,WapStr("Keywords")))
   '鍐呭椤靛浘鐗?
   If InStr(F_C, "{=GetPhoto") <> 0 Then
      HtmlLabel = GetFunctionLabel(F_C, "{=GetPhoto")
      Param = Split(GetFunctionLabelParam(HtmlLabel, "{=GetPhoto"),",")
      PhotoUrl=WapStr("PicUrl")
      If s("page")=1 or s("page")="" Then
         If Not (IsNull(PhotoUrl) Or PhotoUrl = "") Then
      F_C = Replace(F_C,HtmlLabel, "<a href=""Wap_DownPic.asp?Url="&PhotoUrl&"&wap="&wap&"""><img src="""&PhotoUrl&"""  width="""&Param(0)&""" height="""&Param(1)&"""/></a><br/>")
      Else
      F_C = Replace(F_C, HtmlLabel, "")
      End If
       Else
         F_C = Replace(F_C, HtmlLabel, "")
       End If
   End If
   F_C = Replace(F_C, "{$GetArticleIntro}", WapStr("Intro"))
   '鏂囩珷鍐呭
   If InStr(F_C,"{=GetArticleContent")<>0 Then
      HtmlLabel = GetFunctionLabel(F_C,"{=GetArticleContent")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetArticleContent"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),ContentPagination(UbbToHtml(LoseHtml(HtmlToUbb(Transform(WapStr("ArticleContent"))))),Param(0),"wap_ShowInfo.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&"",True))
      Next
   End If
   F_C = Replace(F_C,"{$GetArticleAuthor}",WapStr("Author"))'鏂囩珷浣滆€?
   F_C = Replace(F_C,"{$GetArticleOrigin}",WapStr("Origin"))'鏂囩珷鏉ユ簮
   F_C = Replace(F_C,"{$GetArticleDate}",WapStr("AddDate"))'娣诲姞镞ユ湡
   F_C = Replace(F_C,"{$GetArticleHits}",WapStr("Hits"))'镣瑰向鏁?
   F_C = Replace(F_C,"{$GetArticleInput}",WapStr("ArticleInput"))'鏂囩珷褰曞叆
   F_C = Replace(F_C, "{$Collect}","<a href=""wap_Favorite.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&""">锷犲叆鏀惰棌澶?/a>")'锷犲叆鏀惰棌澶?
    End If
   '===============锲剧墖鍐呭椤垫爣绛?==============
   If Channel("BasicType")=2 Then
      F_C = Replace(F_C,"{$GetPictureID}",WapStr("PicID"))'褰揿墠锲剧墖ID
   F_C = Replace(F_C,"{$InfoID}",WapStr("ID"))'褰揿墠鏂囩珷灏廔D
   F_C = Replace(F_C,"{$ItemName}",Channel("ItemName"))'褰揿墠椤圭洰鍚岖О
   F_C = Replace(F_C,"{$ItemUnit}",Channel("ItemUnit"))'褰揿墠椤圭洰鍗曚綅
   F_C = Replace(F_C,"{$GetPictureName}",WapStr("Title"))'锲剧墖鍚岖О
   F_C = Replace(F_C,"{$GetPictureKeyWord}",WapStr("KeyWords"))'鍏抽敭瀛?
   F_C = Replace(F_C, "{$GetKeyTags}",ReplaceKeyTags(ChannelID,WapStr("Keywords")))
   F_C = Replace(F_C,"{$GetPictureByPage}",GetPictureByPage)'镆ョ湅锲剧墖鍐呭锛堜笂涓€椤点€佷笅涓€椤垫柟寮忥级
   F_C = Replace(F_C,"{$GetPictureIntro}",WapStr("PictureContent"))'锲剧墖浠嬬粛
   F_C = Replace(F_C,"{$GetPictureAuthor}",WapStr("Author"))'锲剧墖浣滆€?
   F_C = Replace(F_C,"{$GetPictureOrigin}",WapStr("Origin"))'锲剧墖鏉ユ簮
   F_C = Replace(F_C,"{$GetPictureRank}",WapStr("Rank"))'锲剧墖绛夌骇
   F_C = Replace(F_C,"{$GetPictureDate}",WapStr("AddDate"))'娣诲姞镞ユ湡
   F_C = Replace(F_C,"{$GetPictureHits}",WapStr("Hits"))'锲剧墖浜烘皵锛堟€绘祻瑙堟暟锛?
   F_C = Replace(F_C,"{$GetPictureHitsByDay}",WapStr("HitsByDay"))'锲剧墖链棩娴忚鏁?
   F_C = Replace(F_C,"{$GetPictureHitsByWeek}",WapStr("HitsByWeek"))'锲剧墖链懆娴忚鏁?
   F_C = Replace(F_C,"{$GetPictureHitsByMonth}",WapStr("HitsByMonth"))'锲剧墖链湀娴忚鏁?
   F_C = Replace(F_C,"{$GetPictureInput}",WapStr("PictureInput"))'锲剧墖褰曞叆
   F_C = Replace(F_C,"{$GetPictureVote}",WapStr("Score"))'缃戝弸鎶旷エ鏁?
   F_C = Replace(F_C, "{$Collect}","<a href=""wap_Favorite.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&""">锷犲叆鏀惰棌澶?/a>")'锷犲叆鏀惰棌澶?
   'F_C = Replace(F_C,"{$GetPictureVoteScore}",WapStr("PictureInput"))'鏄剧ず锲剧墖寰楃エ鏁?
    End If
    '===============杞欢鍐呭椤垫爣绛?==============
    If Channel("BasicType")=3 Then
      F_C = Replace(F_C,"{$GetDownID}",WapStr("DownID"))'褰揿墠杞欢ID
   F_C = Replace(F_C,"{$ItemName}",Channel("ItemName"))'褰揿墠椤圭洰鍚岖О
   F_C = Replace(F_C,"{$ItemUnit}",Channel("ItemUnit"))'褰揿墠椤圭洰鍗曚綅
   F_C = Replace(F_C,"{$GetDownTitle}",WapStr("Title")&" "&WapStr("DownVeRsion"))'杞欢鍚岖О+鐗堟湰鍙?
   F_C = Replace(F_C, "{$GetKeyTags}",ReplaceKeyTags(ChannelID,WapStr("Keywords")))
   F_C = Replace(F_C,"{$GetDownFenji}",GetDownFenji)'鍒嗘満鍨嬩笅杞藉湴鍧€
   
   F_C = Replace(F_C,"{$GetDownAddress}",GetDownAddress)'鏅€氢笅杞藉湴鍧€
   
         '涓嬭浇缂╃暐锲?甯﹀弬鏁?
    If InStr(F_C, "{=GetDownPhoto") <> 0 Then
     HtmlLabel = GetFunctionLabel(F_C, "{=GetDownPhoto")
     HtmlLabelArr=Split(HtmlLabel,"@@@")
     For I=0 To Ubound(HtmlLabelArr)
      Param = GetFunctionLabelParam(HtmlLabelArr(I), "{=GetDownPhoto")
      LogoWidth = Split(Param, ",")(0)
      LogoHeight = Split(Param, ",")(1)
      PhotoUrl=WapStr("PhotoUrl")
      If Not (IsNull(PhotoUrl) Or PhotoUrl = "") Then
       F_C = Replace(F_C,HtmlLabelArr(I), "<img src=""" & PhotoUrl & """  width=""" & LogoWidth & """ height=""" & LogoHeight & """ />")
      Else
       F_C = Replace(F_C, HtmlLabelArr(I), "<img src=""/images/nopic.gif""  width=""" & LogoWidth & """ height=""" & LogoHeight & """ />")
      End If
       Next
      End If
     '涓嬭浇灞炴€?
     If InStr(F_C, "{$GetDownProperty}") <> 0 Then
     If CInt(WapStr("Recommend")) = 1 Then
     TempStr = "[钻怾"
     End If
     If CInt(WapStr("Popular")) = 1 Then
     TempStr = "[鐑璢"
     End If
    F_C = Replace(F_C, "{$GetDownProperty}", TempStr)
     End If
   F_C = Replace(F_C,"{$GetDownSize}",WapStr("DownSize")&"MB")'鏂囦欢澶у皬+MB锛圞B锛?
   F_C = Replace(F_C,"{$GetDownLanguage}",WapStr("DownYY"))'杞欢璇█
   F_C = Replace(F_C,"{$GetDownType}",WapStr("DownLB"))'杞欢绫诲埆
   F_C = Replace(F_C,"{$GetDownSystem}",WapStr("DownPT"))'绯荤粺骞冲彴
   F_C = Replace(F_C,"{$GetDownPower}",WapStr("DownSQ"))'鎺堟潈鏂瑰纺
   
   '杞欢浠嬬粛
   If InStr(F_C,"{=GetDownIntro")<>0 Then
      HtmlLabel = GetFunctionLabel(F_C,"{=GetDownIntro")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetDownIntro"),",")
       F_C = Replace(F_C, HtmlLabelArr(I),ContentGengduo(WapStr("DownContent"),Param(0),WapStr("BigPhoto")))
      Next
   End If
   F_C = Replace(F_C,"{$GetDownAuthor}",WapStr("Author"))'涓嬭浇浣滆€?
   F_C = Replace(F_C,"{$GetDownDate}",WapStr("AddDate"))'娣诲姞锛堟洿鏂帮级镞ユ湡
   F_C = Replace(F_C,"{$GetDownHits}",WapStr("Hits"))'镐讳笅杞界偣鍑绘暟
   F_C = Replace(F_C,"{$GetDownHitsByDay}",WapStr("HitsByDay"))'链棩镣瑰向鏁?
   F_C = Replace(F_C,"{$GetDownPower}",WapStr("HitsByWeek"))'链懆镣瑰向鏁?
   F_C = Replace(F_C,"{$GetDownPower}",WapStr("HitsByWeek"))'链懆镣瑰向鏁?
   F_C = Replace(F_C,"{$GetDownHitsByMonth}",WapStr("HitsByMonth"))'链湀镣瑰向鏁?
   'F_C = Replace(F_C,"{$GetDownYSDZ}",WapStr("YSDZ"))'婕旗ず鍦板潃
   F_C = Replace(F_C, "{$GetDownStar}", Replace(WapStr("Rank"),"钸?,"钸?))'鏄剧ず鎺ㄨ崘鏄熺骇
   F_C = Replace(F_C, "{$Collect}","<a href=""wap_Favorite.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&""">锷犲叆鏀惰棌澶?/a>")'锷犲叆鏀惰棌澶?
    End If
    '===============鍟嗗搧鍐呭椤垫爣绛?==============
    If Channel("BasicType")=5 Then
       F_C = Replace(F_C,"{$GetProductID}",WapStr("ProID"))'褰揿墠妯″瀷ID
    F_C = Replace(F_C,"{$ItemName}",Channel("ItemName"))'褰揿墠椤圭洰鍚岖О
    F_C = Replace(F_C,"{$ItemUnit}",Channel("ItemUnit"))'褰揿墠椤圭洰鍗曚綅
    F_C = Replace(F_C,"{$GetProductName}",WapStr("Title"))'鍟嗗搧鍚岖О
    F_C = Replace(F_C, "{$GetKeyTags}",ReplaceKeyTags(ChannelID,WapStr("Keywords")))
    '鍟嗗搧锲剧墖
    If InStr(F_C, "{=GetProductPhoto") <> 0 Then
     Dim I,HtmlLabel: HtmlLabel = GetFunctionLabel(F_C, "{=GetProductPhoto")
     Dim HtmlLabelArr:HtmlLabelArr=Split(HtmlLabel,"@@@")
     Dim PhotoUrl:PhotoUrl=WapStr("BigPhoto")
     For I=0 To Ubound(HtmlLabelArr)
      Dim Param: Param = GetFunctionLabelParam(HtmlLabelArr(I), "{=GetProductPhoto")
      Dim LogoWidth: LogoWidth = Split(Param, ",")(0)
      Dim LogoHeight: LogoHeight = Split(Param, ",")(1)
      If Not (IsNull(PhotoUrl) Or PhotoUrl = "") Then
       Dim TempBigPhoto:TempBigPhoto=PhotoUrl
       If lcase(left(TempBigPhoto,4))<>"http" Then
       if left(TempBigPhoto,1)="/" then TempBigPhoto=right(TempBigPhoto,len(TempBigPhoto)-1)
       TempBigPhoto=DomainStr & TempBigPhoto
       end if
       If InStr(TempBigPhoto, "http://") = 0 Then TempBigPhoto = "/"&TempBigPhoto
       F_C = Replace(F_C,HtmlLabelArr(I), "<img src=""" & TempBigPhoto & """  width=""" & LogoWidth & """ height=""" & LogoHeight & """ />")
      Else
       F_C = Replace(F_C, HtmlLabelArr(I), "<img src=""/images/nopic.gif""  width=""" & LogoWidth & """ height=""" & LogoHeight & """ />")
      End If
       Next
      End If
   '鍟嗗搧绠€浠?
   If InStr(F_C,"{=GetProductIntro")<>0 Then
      HtmlLabel = GetFunctionLabel(F_C,"{=GetProductIntro")
      HtmlLabelArr=Split(HtmlLabel,"@@@")
      For I=0 To Ubound(HtmlLabelArr)
          Param = Split(GetFunctionLabelParam(HtmlLabelArr(I),"{=GetProductIntro"),",")
       Conn.Execute("UPDATE "&Channel("ChannelTable")&" SET Hits=Hits+1 WHERE ID=" & ClassID)'澧炲姞鐢ㄦ埛镆ョ湅娆℃暟
       F_C = Replace(F_C, HtmlLabelArr(I),ContentGengduo(WapStr("ProIntro"),Param(0),WapStr("BigPhoto")))
      Next
   End If
   F_C = Replace(F_C,"{$GetProducerName}",WapStr("ProducerName"))'鍟嗗搧鐢熶骇鍟?
   F_C = Replace(F_C,"{$GetTrademarkName}",WapStr("TrademarkName"))'鍝佺墝鍟嗘爣
   F_C = Replace(F_C,"{$GetProductModel}", WapStr("ProModel"))'鍟嗗搧鍨嫔佛
   F_C = Replace(F_C,"{$GetProductSpecificat}",WapStr("ProSpecificat"))'鍟嗗搧瑙勬牸
   F_C = Replace(F_C, "{$GetProductDate}",DateFormat(WapStr("AddDate"), 6))'涓婃灦镞堕棿
   F_C = Replace(F_C,"{$GetServiceTerm}",WapStr("ServiceTerm"))'链嶅姟链熼檺
   F_C = Replace(F_C,"{$GetTotalNum}",WapStr("TotalNum"))'搴揿瓨鏁伴噺
   F_C = Replace(F_C,"{$GetProductUnit}",WapStr("Unit"))'鍟嗗搧鍗曚綅
   F_C = Replace(F_C,"{$GetProductHits}",WapStr("Hits"))'娴忚娆℃暟
   F_C = Replace(F_C,"{$GetProductType}",GetProductType(WapStr("ProductType")))'阌€鍞被鍨?
   F_C = Replace(F_C,"{$GetRank}",Replace(WapStr("Rank"),"钸?,"钸?))'鎺ㄨ崘绛夌骇
   '鏄剧ず鍟嗗搧灞炴€?鐑岽銆佺壒浠枫€佹帹钻愮瓑)
   If InStr(F_C, "{$GetProductProperty}") <> 0 Then
      TempStr = ""
      If CInt(WapStr("Recommend")) = 1 Then TempStr = TempStr & ("钻?)
      If CInt(WapStr("Popular")) = 1 Then TempStr = TempStr & ("鐑?)
      If CInt(WapStr("IsSpecial")) = 1 Then TempStr = TempStr & ("鐗?)
      F_C = Replace(F_C, "{$GetProductProperty}", TempStr)
   End If
   F_C = Replace(F_C,"{$GetPrice_Original}",WapStr("Price_Original"))'鏄剧ず铡熷板跺敭浠?
   F_C = Replace(F_C,"{$GetPrice}", WapStr("Price"))'鏄剧ず褰揿墠板跺敭浠?
   F_C = Replace(F_C,"{$GetPrice_Member}",WapStr("Price_Member"))'鏄剧ず浼氩憳浠?
   F_C = Replace(F_C,"{$GetPrice_Market}",WapStr("Price_Market"))'鏄剧ず甯傚満浠?
   '鏄剧ず鎶樻墸鐜?
   If WapStr("ProductType")=3 Then
      F_C = Replace(F_C, "{$GetDiscount}", WapStr("Discount"))
   Else
      F_C = Replace(F_C, "{$GetDiscount}", "")
   End If
   F_C = Replace(F_C, "{$GetScore}", WapStr("Point"))'鏄剧ず璐墿绉垎
   F_C = Replace(F_C, "{$GetAddCar}", "<a href=""ShoppingCart.asp?ProductList=" & WapStr("id")& "&wap="&wap&""">锷犲叆璐墿杞?/a>")'锷犲叆璐墿杞?
   F_C = Replace(F_C, "{$Collect}","<a href=""wap_Favorite.asp?id="&ClassID&"&ChannelID="&ChannelID&"&wap="&wap&""">锷犲叆鏀惰棌澶?/a>")'锷犲叆鏀惰棌澶?
    
    End If
  End If
   '鍑芥暟鍚嶏细ReplaceLableFlag铡婚櫎镙囩{=},骞跺垎缁勪互灏嗘爣绛惧弬鏁扮敤","闅斿紑
   F_C = ReplaceLableFlag(F_C)
   KSLabelReplaceAll = F_C
  End Function
   
  Function GetProductType(TypeID)
   Select Case TypeID
    Case 1:GetProductType="姝e父阌€鍞?
    Case 2:GetProductType="娑ㄤ环阌€鍞?
    Case 3:GetProductType="闄崭环阌€鍞?
  End Select
  End Function
        '**************************************************
  '鍑芥暟鍚嶏细ChangeLableToFunction
  '浣? 鐢细灏嗘爣绛捐浆鎹负鍑芥暟镓ц
  '鍙? 鏁帮细 LabelContent  ----镙囩鍙傛暟
  '杩斿洖链硷细鍑芥暟镓ц缁撴灉
  '**************************************************
  Function ChangeLableToFunction(LabelContent)
     Dim L_Arr:L_Arr = Split(LabelContent, ",")
     If L_Arr(0) = "" Then
      ChangeLableToFunction = ""
      Exit Function
   End If
   Select Case UCase(L_Arr(0))'灏忓啓杞崲鎴愬ぇ鍐?
   Case "GETWENHOUYU"'鏄剧ず镙规嵁褰揿墠镄勬椂闂翠笉鍚岀殑闂€***
      ChangeLableToFunction=GetWenhouyu(L_Arr(1), L_Arr(2), L_Arr(3), L_Arr(4), L_Arr(5), L_Arr(6), L_Arr(7), L_Arr(8))
   '===============棣栭〉镙囩===============
   Case "PINDAODAOHANG"'鏄剧ず棣栭〉棰戦亾瀵艰埅
      ChangeLableToFunction=PindaoDaohang(L_Arr(1), L_Arr(2))
   Case "SOUSUOLANMU"'鏄剧ず棣栭〉鎼灭储镙忕洰
      ChangeLableToFunction=Sousuolanmu(L_Arr(1), L_Arr(2))
   Case "GETHOMEPAGEROWFORM"'鏄剧ず棣栭〉链€鏂版枃绔?
      ChangeLableToFunction=GetHomepageRowform(L_Arr(1), L_Arr(2), L_Arr(3), L_Arr(4), L_Arr(5))
   '===============镙忕洰镙囩===============
   Case "GETCONTENTSROWFORM"'镙忕洰灞炴€э纸鐑棬銆佹渶鏂般€佹帹钻愶级
      ChangeLableToFunction=GetContentsRowform(L_Arr(1), L_Arr(2), L_Arr(3), L_Arr(4))
   Case "GETRANDOMDIAGRAMTEXT"'闅忔満锲炬枃
      ChangeLableToFunction=GetRandomDiagramText(L_Arr(1))
   Case "CATEGORIZE"'镙忕洰鍒嗙被
      ChangeLableToFunction=Categorize(L_Arr(1), L_Arr(2))
   Case "LANMUSOUSUO"'镙忕洰鎼灭储
      ChangeLableToFunction=LanmuSousuo(L_Arr(1))
   Case "GETSHOWCLASS"'镙忕洰缁堢骇鍒楄〃鍒嗛〉
      ChangeLableToFunction=GetShowClass(L_Arr(1), L_Arr(2), L_Arr(2)) 
   Case "GETCONTENTSRANDOM"'鏄剧ず鍐呭椤甸殢链哄垪琛?
      ChangeLableToFunction=GetContentsRandom(L_Arr(1), L_Arr(2), L_Arr(3)) 
   '===============绌洪棿镙囩===============
   Case "GETNAVIGATION"'鏄剧ず鍒嗙被
      ChangeLableToFunction=GetNavigation(L_Arr(1), L_Arr(2), L_Arr(3))


   Case "TUIJIANKONGJIAN"'鏄剧ず鎺ㄨ崘绌洪棿
      ChangeLableToFunction=TuijianKongjian(L_Arr(1), L_Arr(2), L_Arr(3))
   Case "ZUIXINXIANGCE"'鏄剧ず链€鏂扮浉鍐?
      ChangeLableToFunction=ZuixinXiangce(L_Arr(1), L_Arr(2))
   Case "ZUIXINRIZHI"'鏄剧ず链€鏂版棩蹇?
      ChangeLableToFunction=ZuixinRizhi(L_Arr(1), L_Arr(2), L_Arr(3))
   Case "ZUIXINPINGLUN"'鏄剧ず链€鏂拌瘎璁?
      ChangeLableToFunction=ZuixinPinglun(L_Arr(1), L_Arr(2), L_Arr(3))
   Case Else
      ChangeLableToFunction = ""
      Exit Function
   End Select
  End Function


%>

 
  支持(0) | 反对(0) 回到顶部顶端 回到底部底部
<上一主题 | 下一主题 >
Powered By KesionCMS Version X1
厦门科汛软件有限公司 © 2006-2016 页面执行0.91406秒 powered by KesionCMS 9.0