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

📄 luzhuba.asp

📁 露珠网站是一个以文章类、下载类、图片类、动画类、视频类为主的综合网站。我们的目标:麻雀虽小(223kb)
💻 ASP
📖 第 1 页 / 共 5 页
字号:
<!--#include file="conn.asp"-->
<%
function chan_data(shijian) 
s_year=year(shijian)
if len(s_year)=2 then s_year="20"&s_year
s_month=month(shijian)
if s_month<10 then s_month="0"&s_month
s_day=day(shijian)
if s_day<10 then s_day="0"&s_day
chan_data=s_year & s_month & s_day
end function
function chan_datays(shijian) 
s_month=month(shijian)
if s_month<10 then s_month="0"&s_month
s_day=day(shijian)
if s_day<10 then s_day="0"&s_day
chan_datays= s_month &"-"& s_day
end function
function datelws(shijian) 
s_year=year(shijian)
if len(s_year)=2 then s_year="20"&s_year
s_month=month(shijian)
if s_month<10 then s_month="0"&s_month
s_day=day(shijian)
if s_day<10 then s_day="0"&s_day
datelws=s_year &"-"& s_month &"-"& s_day
end function
Public Function ChkFormStr(ByVal str)
		Dim fString
		fString = str
		If IsNull(fString) Then
			ChkFormStr = ""
			Exit Function
		End If
		fString = Replace(fString, "'", "&#39;")
		fString = Replace(fString, Chr(34), "&quot;")
		fString = Replace(fString, Chr(13), "")
		fString = Replace(fString, Chr(10), "")
		fString = Replace(fString, Chr(9), "")
		fString = Replace(fString, ">", "&gt;")
		fString = Replace(fString, "<", "&lt;")
		fString = Replace(fString, "&nbsp;", " ")
		ChkFormStr = Trim(fString)
	End Function
Public Function ChkBadWords(str)
		If IsNull(str) Then Exit Function
		Dim i,m_arrBadword,m_strlen
		m_arrBadword = Split(badwords & "","|")
		For i = 0 To UBound(m_arrBadword)
			m_strlen = Len(m_arrBadword(i))
			If InStr(str,m_arrBadword(i)) > 0 And m_strlen > 0 Then
				str = Replace(str,m_arrBadword(i),String(m_strlen, "*"))
			End If
		Next
		ChkBadWords = str
	End Function
Function GetPageCount(NowPage,CountPage,FileName)      
Dim ShowPageNum           
Dim PageUp                 
Dim PageDown            
Dim i                        
ShowPageNum = 5           
PageUp = ""
PageDown = ""
     if NowPage=1 then
           GetPageCount = GetPageCount & "<a href=""" & FileName & ".html""><font color=""#ff0000""><b>1</b></font></a> "
     else
           GetPageCount = GetPageCount & "<a href=""" & FileName & ".html"">1</a> "
     end if
     
     if CountPage <= ShowPageNum then
           For i = 2 to CountPage
                 GetPageCount = GetPageCount & "<a href=""" & FileName & "_" & i & ".html"">" & GetColor(i,NowPage) & "</a> "
           Next
     else            
           if (NowPage - 3) > 1 and (NowPage + 3) < CountPage then
                 GetPageCount = "... "
                 For i = NowPage - 3 to NowPage + 3
                       GetPageCount = GetPageCount & "<a href=""" & FileName & "_" & i & ".html"">" & GetColor(i,NowPage) & "</a> "
                 Next
                 GetPageCount = GetPageCount & "..."
           else
                 if (NowPage - 3) > 1 and (NowPage + 3) => CountPage then
                       GetPageCount = "... "
                       For i = CountPage - ShowPageNum to CountPage
                             GetPageCount = GetPageCount & "<a href=""" & FileName & "_" & i & ".html"">" & GetColor(i,NowPage) & "</a> "
                       Next
                 else
                       For i = 2 to ShowPageNum
                             GetPageCount = GetPageCount & "<a href=""" & FileName & "_" & i & ".html"">" & GetColor(i,NowPage) & "</a> "
                       Next
                       GetPageCount = GetPageCount & "..."
                 end if
           end if
     End if
          if NowPage > 1 then
           if NowPage > 2 then
                 PageUp = "<a href=""" & FileName & "_" & NowPage - 1 & ".html"">上页</a> "
           else
                 PageUp = "<a href=""" & FileName & ".html"">上页</a> "
           end if
     end if
     if NowPage < CountPage then
           PageDown = "<a href=""" & FileName & "_" & NowPage + 1 & ".html"">下页</a> "
     End if
   if CountPage=1 then
GetPageCount = ""
else
     GetPageCount = "<p align=""center""><a href=""" & FileName & ".html"">首页</a>  " & PageUp & GetPageCount & PageDown & "<a href=""" & FileName & "_" & CountPage & ".html"">末页</a>"
end if
End Function
Function GetColor(i,NowPage)      
     if i = NowPage then
           GetColor = "<font color=""#ff0000""><b>" & NowPage & "</b></font>"
     else
           GetColor = i
     end if
End Function
Private Function luzhuba_cn(Str):Print=Response.Write(Str):End Function
Private Function luzhuba():Die=Response.End:End Function
Private Function www_luzhuba_cn_jsq(Str):Redirect=Response.Redirect(Str):End Function
function qtxx(lr,lb)
Set rs2=Server.CreateObject("ADODB.RecordSet") 
sql="select d_id,lb,lbmz,lbqt,lbqtsz from qtxx where d_id="&lr&""
rs2.Open sql,conn,1,1
if rs2.eof and rs2.bof then
qtxx=""
else
if lb=1 then
qtxx=rs2("lbqt")
else
qtxx=rs2("lbmz")
end if
end if
rs2.close
end function
function gotTopic(str,strlen)
	if str="" then
		gotTopic=""
		exit function
	end if
	dim l,t,c, i
	str=replace(replace(replace(replace(str,"&nbsp;"," "),"&quot;",chr(34)),"&gt;",">"),"&lt;","<")
	str=replace(replace(replace(replace(replace(str,"<p>",""),"</p>",""),"br",""),"<",""),">","")
l=len(str)
	t=0
	for i=1 to l
		c=Abs(Asc(Mid(str,i,1)))
		if c>255 then
			t=t+2
		else
			t=t+1
		end if
		if t>=cint(strlen) then
			gotTopic=left(str,i) & "..."
			exit for
		else
			gotTopic=str
		end if
	next
gotTopic=gotTopic
end function
Function FlashNews(htmlsf,xz,wzxssf,num,fontnum,PicWidthStr,PicHeightStr,BGcolor,txtheight,zfl,wzxs)
if xz=2 then
FlashStr=FlashStr&"<SCRIPT language=JavaScript>"& Chr(13)
FlashStr=FlashStr&"<!--"& Chr(13)
FlashStr=FlashStr&"var PicWidthStr="&PicWidthStr& Chr(13)   
FlashStr=FlashStr&"var PicHeightStr="&PicHeightStr& Chr(13)
FlashStr=FlashStr&"var txtheight="&txtheight& Chr(13)
FlashStr=FlashStr&"function objSP_Photo() {this.ImgUrl=""""; this.LinkUrl=""""; this.Title="""";}"& Chr(13)
FlashStr=FlashStr&"function SlidePic_Photo(_id) {this.ID=_id; this.Width=0;this.Height=0; this.TimeOut=5000; this.Effect=23; this.TitleLen=0; this.PicNum=-1; this.Img=null; this.Url=null; this.Title=null; this.AllPic=new Array(); this.Add=SlidePic_Photo_Add; this.Show=SlidePic_Photo_Show; this.LoopShow=SlidePic_Photo_LoopShow;}"& Chr(13)
FlashStr=FlashStr&"function SlidePic_Photo_Add(_SP) {this.AllPic[this.AllPic.length] = _SP;}"& Chr(13)
FlashStr=FlashStr&"function SlidePic_Photo_Show() {"& Chr(13)
FlashStr=FlashStr&"  if(this.AllPic[0] == null) return false"& Chr(13)
FlashStr=FlashStr&"document.write(""<div align='center'><a id='Url_"" + this.ID + ""'  href='' ><img id='Img_"" + this.ID + ""' style='width:"" + this.Width + ""px; height:"" + this.Height + ""px; filter: revealTrans(duration=2,transition=23);' src='javascript:null' border='0'></a>"")"& Chr(13)
FlashStr=FlashStr&"  if(this.TitleLen != 0) document.write(""<br><span id='Title_"" + this.ID + ""'></span></div>"")"& Chr(13)
FlashStr=FlashStr&"  this.Img = document.getElementById(""Img_"" + this.ID)"& Chr(13)
FlashStr=FlashStr&"  this.Url = document.getElementById(""Url_"" + this.ID)"& Chr(13)
FlashStr=FlashStr&"  this.Title = document.getElementById(""Title_"" + this.ID)"& Chr(13)
FlashStr=FlashStr&"  this.LoopShow()"& Chr(13)
FlashStr=FlashStr&"}"& Chr(13)
FlashStr=FlashStr&"function SlidePic_Photo_LoopShow() {"& Chr(13)
FlashStr=FlashStr&"  if(this.PicNum<this.AllPic.length-1) this.PicNum++ ; "& Chr(13)
FlashStr=FlashStr&"  else this.PicNum=0; "& Chr(13)
FlashStr=FlashStr&"  this.Img.filters.revealTrans.Transition=this.Effect; "& Chr(13)
FlashStr=FlashStr&"  this.Img.filters.revealTrans.apply(); "& Chr(13)
FlashStr=FlashStr&" this.Img.src=this.AllPic[this.PicNum].ImgUrl"& Chr(13)
FlashStr=FlashStr&" this.Img.filters.revealTrans.play()"& Chr(13)
FlashStr=FlashStr&"  this.Url.href=this.AllPic[this.PicNum].LinkUrl"& Chr(13)
if wzxssf=1 then
FlashStr=FlashStr&"  if(this.Title) this.Title.innerHTML=""<a href=""+this.AllPic[this.PicNum].LinkUrl+"" target=_blank style='font-size: 14px;""+this.AllPic[this.PicNum].btzt+"";color:#""+this.AllPic[this.PicNum].btys+"";background-color:#"&BGcolor&"'>""+this.AllPic[this.PicNum].Title+""</a>"""& Chr(13)
end if
FlashStr=FlashStr&"  this.Img.timer=setTimeout(this.ID+"".LoopShow()"",this.TimeOut)"& Chr(13)
FlashStr=FlashStr&"}"& Chr(13)
FlashStr=FlashStr&"var SlidePic_187 = new SlidePic_Photo(""SlidePic_187"")"& Chr(13)
FlashStr=FlashStr&"SlidePic_187.Width    = PicWidthStr"& Chr(13)
FlashStr=FlashStr&"SlidePic_187.Height   = PicHeightStr"& Chr(13)
FlashStr=FlashStr&"SlidePic_187.TimeOut  = 5000"& Chr(13)
FlashStr=FlashStr&"SlidePic_187.Effect   = 23"& Chr(13)
FlashStr=FlashStr&"SlidePic_187.TitleLen = txtheight"& Chr(13)
Set rszfl=Server.CreateObject("ADODB.RecordSet") 
sql="select * from zfl where d_id="&zfl&" "
rszfl.Open sql,conn,1,1
zfllx=rszfl("zfllx")
zflwz=rszfl("zflmzxy")
rszfl.close
Dim RsFilterObj,FlashStr,ImagesStr,TxtStr,LinkStr,wztp,wzbt,wzsj,bm
if zfllx=1 then
bm="wz"
wztp="wztp"
wzbt="wzbt"
wzsj="wzsj"
btzt="btzt"
btys="btys"
wj="wzshow.asp"
end if
if zfllx=2 then
bm="rj"
wztp="rjst"
wzbt="rjmz"
wzsj="rjsj"
btzt="mzzt"
btys="mzys"
wj="rjshow.asp"
end if
if zfllx=3 then
bm="tp"
wztp="tp"
wzbt="bt"
wzsj="sj"
btzt="btzt"
btys="btys"
wj="tpshow.asp"
end if
if zfllx=4 then
bm="dh"
wztp="tp"
wzbt="bt"
wzsj="sj"
btzt="btzt"
btys="btys"
wj="dhshow.asp"
end if
if zfllx=5 then
bm="sp"
wztp="tp"
wzbt="bt"
wzsj="sj"
btzt="btzt"
btys="btys"
wj="spshow.asp"
end if
Sql = "SELECT top "&num&" * FROM "&bm&" where  zfl="&zfl&" and syhd=1 and "&wztp&"<>'' ORDER BY d_id DESC"
Set Rs= Conn.Execute(Sql)
do while not rs.eof
FlashStr=FlashStr&"var oSP = new objSP_Photo()"& Chr(13) 
FlashStr=FlashStr&"oSP.ImgUrl         = """&Rs(""&wztp&"")&""""& Chr(13) 
if rs("btlj")<>"" then
FlashStr=FlashStr&"oSP.LinkUrl        ="""&rs("btlj")&""""& Chr(13)
else
if htmlsf=1 then
FlashStr=FlashStr&"oSP.LinkUrl        = ""?"&bm&""&Rs("d_id")&".html"""& Chr(13)
else
if wzxs=1 then
FlashStr=FlashStr&"oSP.LinkUrl        ="""&zflwz&"/"&chan_data(Rs(""&wzsj&""))&"/"&md5(Trim(Rs("d_id")),16)&".html"""& Chr(13)
else
if wzxs=4 then
FlashStr=FlashStr&"oSP.LinkUrl        ="""&md5(Trim(Rs("d_id")),16)&".html"""& Chr(13)
else
FlashStr=FlashStr&"oSP.LinkUrl        ="""&chan_data(Rs(""&wzsj&""))&"/"&md5(Trim(Rs("d_id")),16)&".html"""& Chr(13)
end if
end if
end if
end if
if wzxssf=1 then 
FlashStr=FlashStr&"oSP.Title         = """&gotTopic(Rs(""&wzbt&""),fontnum)&""""& Chr(13) 
FlashStr=FlashStr&"oSP.btzt         = """&qtxx(rs(""&btzt&""),1)&""""& Chr(13) 
FlashStr=FlashStr&"oSP.btys         = """&rs(""&btys&"")&""""& Chr(13) 
end if
FlashStr=FlashStr&"SlidePic_187.Add(oSP)"& Chr(13)
rs.movenext
loop
if rs.eof and rs.bof then
FlashStr=FlashStr&"<font color=""#666666"">目前尚无任何信息!</font>"
else
FlashStr=FlashStr&"SlidePic_187.Show()"& Chr(13) & vbcrlf
FlashStr=FlashStr&"//-->"& Chr(13)
end if
FlashStr=FlashStr&"</SCRIPT>"& Chr(13)
rs.close
end if
if xz=1 then
Set rszfl=Server.CreateObject("ADODB.RecordSet") 
sql="select * from zfl where d_id="&zfl&" "
rszfl.Open sql,conn,1,1
zfllx=rszfl("zfllx")
zflwz=rszfl("zflmzxy")
rszfl.close
if zfllx=1 then
bm="wz"
wztp="wztp"
wzbt="wzbt"
wzsj="wzsj"
wj="wzshow.asp"
end if
if zfllx=2 then
bm="rj"
wztp="rjst"
wzbt="rjmz"
wzsj="rjsj"
wj="rjshow.asp"
end if
if zfllx=3 then
bm="tp"
wztp="tp"
wzbt="bt"
wzsj="sj"
wj="tpshow.asp"
end if
if zfllx=4 then
bm="dh"
wztp="tp"
wzbt="bt"
wzsj="sj"
wj="dhshow.asp"
end if
if zfllx=5 then
bm="sp"
wztp="tp"
wzbt="bt"
wzsj="sj"
wj="spshow.asp"
end if
FilterSql = "SELECT top "&num&" * FROM "&bm&" where  zfl="&zfl&" and syhd=1 and "&wztp&"<>'' ORDER BY d_id DESC"
Set RsFilterObj = Conn.Execute(FilterSql)
If not RsFilterObj.Eof then
  Dim Temp_Num
  Temp_Num = 0
  Do While Not RsFilterObj.Eof
  Temp_Num = Temp_Num + 1
  RsFilterObj.MoveNext
  Loop
  RsFilterObj.MoveFirst
  If Temp_Num <=1 then
  Set RsFilterObj = Nothing
  FlashNews = "至少需要两条幻灯新闻才能正确显示幻灯效果"
  Set RsFilterObj = Nothing
  Exit Function 
  End If
  do while Not RsFilterObj.Eof
   if ImagesStr = "" then
if htmlsf=1 then
     ImagesStr = RsFilterObj(""&wztp&"")
else
if wzxs=1 then
ImagesStr = "../"&RsFilterObj(""&wztp&"")
else
if wzxs=4 then
ImagesStr = "../../../"&RsFilterObj(""&wztp&"")
else
ImagesStr = "../../"&RsFilterObj(""&wztp&"")
end if
end if
end if
TxtStr = gotTopic(RsFilterObj(""&wzbt&""),fontnum)
if RsFilterObj("btlj")<>"" then
LinkStr =RsFilterObj("btlj")
else
if htmlsf=1 then

⌨️ 快捷键说明

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