img.asp
资源名称:gov_1.0.rar [点击查看]
上传用户:yjkj1008
上传日期:2020-10-17
资源大小:1496k
文件大小:2k
源码类别:
电子政务应用
开发平台:
HTML/CSS
- <%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
- <!--#include file="Connections/conn_news.asp" -->
- <%
- '请尊重作者劳动成果不要删除以上信息
- '业一新闻系统3.0正式版
- '主页:http://yeyi.net
- '论坛:http://bbs.yeyi.net
- '业一网络 承接各种网站制作
- '程序开发 软件开发业务
- '业务联系
- '电话: 13007310512
- '联系人:郝亚平
- 'QQ:24344842 (只谈业务,技术问题请访问论坛)
- '请尊重作者劳动成果不要删除以上信息
- %>
- <%
- dim style
- style = request("s")
- %>
- <%
- Dim rs__MMColParam
- rs__MMColParam = "0"
- If (Request.QueryString("n_tid") <> "") Then
- rs__MMColParam = Request.QueryString("n_tid")
- End If
- %>
- <%
- Dim rs
- Dim rs_numRows
- Set rs = Server.CreateObject("ADODB.Recordset")
- rs.ActiveConnection = MM_conn_news_STRING
- if rs__MMColParam = "0" then
- rs.Source = "SELECT * FROM t_news WHERE n_index = true and n_check = true ORDER BY n_id DESC"
- else
- rs.Source = "SELECT * FROM t_news WHERE n_tid = " + Replace(rs__MMColParam, "'", "''") + " and n_check = true and n_index = true ORDER BY n_date DESC"
- end if
- rs.CursorType = 0
- rs.CursorLocation = 2
- rs.LockType = 1
- rs.Open()
- rs_numRows = 0
- %>
- <SCRIPT RUNAT=SERVER LANGUAGE=VBSCRIPT>
- function DoTrimProperly(str, nNamedFormat, properly, pointed, points)
- dim strRet
- strRet = Server.HTMLEncode(str)
- strRet = replace(strRet, vbcrlf,"")
- strRet = replace(strRet, vbtab,"")
- If (LEN(strRet) > nNamedFormat) Then
- strRet = LEFT(strRet, nNamedFormat)
- If (properly = 1) Then
- Dim TempArray
- TempArray = split(strRet, " ")
- Dim n
- strRet = ""
- for n = 0 to Ubound(TempArray) - 1
- strRet = strRet & " " & TempArray(n)
- next
- End If
- If (pointed = 1) Then
- strRet = strRet & points
- End If
- End If
- DoTrimProperly = strRet
- End Function
- </SCRIPT>
- document.write('<table width="100%" border="0" cellspacing="0" cellpadding="0"><tr><td width="35%" rowspan="2" align="center"><a href="news/<%=(rs.Fields.Item("n_tid").Value)%>/<%=(rs.Fields.Item("n_fname").Value)%>" target="_blank"><img src="news/upload/<%=(rs.Fields.Item("n_mpic").Value)%>" border="0"></a><% if style=1 then %></td></tr></table><% else %><td width="65%" height="33" > <%=DoTrimProperly((rs.Fields.Item("n_content").Value), 100, 0, 1, "...")%></td></tr><tr><td align="right"> </td></tr></table><% end if %>');
- <%
- rs.Close()
- Set rs = Nothing
- %>
English
