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

📄 picid.asp

📁 asp
💻 ASP
字号:
<%response.expires=0%>
<!--#include file="inc/conn.asp"-->
<!--#include file="inc/code.asp"-->
<%
id=strFilter(request("id"),10)
sql="select top 1 id,title,pic,content,filenum from news where pic=true order by id DESC"
if id><"" then
  if isnumeric(id) then
    sql="select top 1 id,title,pic,content,filenum from news where pic=true and categoryid like '%."&id&".%' order by id DESC"
  end if
end if
rs.open sql,conn,1,1
if not rs.eof then
  id		=rs(0)
  title		=rs(1)
  pic		=rs(2)
  content	=rs(3)
  filenum	=rs(4)
end if
rs.close
sql="select top 1 id from newsphoto where filenum like "&CCur(filenum)
rs.open sql,conn,1,1
if not rs.eof then
  picid=rs(0)
end if
rs.close

nsize=strFilter(request("size"),2)

if content><"" then
  set re = New RegExp
  re.Global = True
  re.IgnoreCase = True
  re.Pattern="\[img(.[^\]]*)\](.[^\[]*)\[\/img]"
  content=re.Replace(content,"")
  re.Pattern="\[img(.[^\]]*)\]"
  content=re.Replace(content,"")
  csize=100
  if nsize><"" then
    if isnumeric(nsize) then
      csize=nsize
    end if
  end if
  content=GetWord(UBBCode(content),100,"......")
end if

response.write "var pichtml='<table border=0 cellPadding=0 cellSpacing=0 width=90% align=center bgcolor=f7f7f7><tbody>' +"
response.write "	'  <tr><td style=""line-height:16pt"" title="""&title&""">' +"
response.write "	'<font style=""font:10pt""><b>"&GetWord(title,39,"...")&"</b></font><br><br>' +"
response.write "	'"&replace(content,"'","\'")&"' +"
response.write "	'<div align=right><a href=""/news/news.asp?id="&id&""">详细 >> </a>&nbsp;&nbsp;&nbsp;&nbsp;</div>' +"
response.write "	'  </td><td style=""border:2 solid #eaeaea"" width=160 height=160 align=middle><img src=""/news/pic.asp?id="&picid&""" width=120 height=120 title="""&title&"""></td></tr>' +"
response.write "	'</table>';"
response.write "document.write(pichtml);"
%>

⌨️ 快捷键说明

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