📄 piccode.asp
字号:
<!--#include file = edit/Include/DeCode.asp -->
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<style>
<!--
a:link { font-size: 9pt; font-family: 宋体; color: #000000;text-decoration: none; }
a:visited { color: #000000; font-family: 宋体; font-size: 9pt;text-decoration: none; }
a:hover { font-size: 9pt; font-family: 宋体; color: #000000;TEXT-DECORATION: underline; }
body { font-family: 宋体; color: #000000; font-size: 9pt }
p { color: #000000; font-family: 宋体; font-size: 9pt }
td { font-size: 9pt; font-family: 宋体; color: #000000 }
input { font-size: 9pt; font-family: 宋体; color: #000000 }
-->
</style>
</head>
<%
lmid=trim(request("lm"))
lm2=trim(request("lm2"))
if lmid="" then lmid=lm2
if lm2="" then lm2=lmid
open=trim(request("open"))
bg=trim(request("bg"))
w=trim(request("w"))
h=trim(request("h"))
nr=trim(request("nr"))
nrtop=trim(request("nrtop"))
n=trim(request("n"))
pic=trim(request("pic"))
if bg="" then bg="ffffff"
%>
<Body bgcolor=<%=bg%>>
<%
if lmid="" then
response.write "调用代码不正确"
response.end
end if
if lmname="" then lmname=0
if w="" then w=150
if nr="" then nr=0
if h="" then h=150
if nrtop="" then nrtop=100
if n="" then n=20
if open="" then open=1
if pic="" then pic=1
pic=clng(pic)
if pic<1 then pic=1
%>
<!--#include file = admin_conn.asp -->
<%
Function glhtml(title)
set reg=new regexp
reg.IgnoreCase=true
reg.Global=true
reg.Pattern="<(.+?)>"
glhtml=reg.Replace(title,"")
set reg=nothing
End Function
sql = "select top "&pic&" * from news where (lm='"&lmid&"' or lm2='"&lmid&"') and pic<>' ' order by ontop , id desc"
Set rs = Server.CreateObject("ADODB.RecordSet")
rs.Open sql,conn,1,1
if rs.recordcount=0 then response.write "<center><BR><BR>暂无图片"
while not rs.eof
%><center>
<table border="0" width="100%" id="table1">
<tr>
<td align=center><a href="news_view.asp?newsid=<%=rs("id")%>"
<%
if open=1 then
response.write "target=_blank"
else
response.write "target=_top"
end if
%>>
<img src=<%=rs("pic")%> width=<%=w%> height=<%=h%> border=0><br>
<font color="<%=rs("titlecolor")%>">
<%=left(rs("title"),n)%><%if len(rs("title"))>=n then response.write "…"%></font></a></td>
<%
if nr="1" then
%>
<td valign=top>
<%
bbbb=rs("content")
bbbb=replace(bbbb,chr(32),"")
bbbb=replace(bbbb,chr(13),"")
bbbb=replace(bbbb,chr(10),"")
bbbb=replace(bbbb,chr(9),"")
bbbb=replace(bbbb," ","")
bbbb=glhtml(bbbb)
bbbb=trim(bbbb)
response.write left(bbbb,nrtop)
%>
</td>
<%end if%>
</tr>
</table></center>
<%
rs.movenext
wend
%>
</body>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -