📄 news_manage.asp
字号:
Response.Write "</td>"
obj_news_rs.MoveNext
icNum = icNum + 1
if icNum mod 4 = 0 then
Response.Write("</tr><tr>")
End if
loop
Response.Write("</tr></table></td></tr></table>")
End if
If Request.Form("Action") = "SetUp" then
Call GetSetUp()
ElseIf Request.Form("Action") = "move" then
Call GetMove()
Elseif Request.Form("Action") = "copy" then
Call GetCopy()
Elseif Request.Form("Action") = "replace" then
Call Getreplace()
Else
Call Main()
End if
Sub Main()
Call GetFunctionstr
if Request("NewsTyp") = "recTF" Then:str_Rec=" and "& CharIndexStr &"(NewsProperty,1,1)='1'":Else:str_Rec="":End if
if Request("NewsTyp") = "isTop" Then:str_isTop=" and PopID=4 or PoPID=5":Else:str_isTop="":End if
if Request("NewsTyp") = "hot" Then:str_hot=" and "& CharIndexStr &"(NewsProperty,13,1)='1'":Else:str_hot="":End if
if Request("NewsTyp") = "pic" Then:str_pic=" and isPicNews=1":Else:str_pic="":End if
if Request("NewsTyp") = "highlight" Then:str_highlight=" and "& CharIndexStr &"(NewsProperty,15,1)='1'":Else:str_highlight="":End if
if Request("NewsTyp") = "bignews" Then:str_bignews=" and "& CharIndexStr &"(NewsProperty,11,1)='1'":Else:str_bignews="":End if
if Request("NewsTyp") = "filt" Then:str_filt=" and "& CharIndexStr &"(NewsProperty,21,1)='1'":Else:str_filt="":End if
if Request("NewsTyp") = "Constr" Then:str_Constr=" and "& CharIndexStr &"(NewsProperty,7,1)='1'":Else:str_Constr="":End if
if Trim(Request("Editor")) <>"" then:str_Editor = " and Editor = '"& Request("Editor")&"'":Else:str_Editor = "":End if
if str_ClassID<>"" and len(str_ClassID)<=15 then str_ClassID_1 = " and ClassID='"& str_ClassID &"'":Else:str_ClassID_1 = "":End if
if str_SpecialEname<>"" and not isnull(str_SpecialEname) then
if G_IS_SQL_DB=0 then
SQL_SpecialEname = " and instr(1,SpecialEName,'"&str_SpecialEname&"',1)>0"
else
SQL_SpecialEname = " and charindex('"&str_SpecialEname&"',SpecialEName)>0"
end if
Else
SQL_SpecialEname=""
End if
if Request("isCheck") = "1" then
str_check = " and islock=0"
elseif Request("isCheck") = "0" then
str_check = " and islock=1"
Else
str_Check = ""
End if
str_Keyword = Trim(Request("keyword"))
str_ktype = Trim(Request("ktype"))
if Trim(str_Keyword) <>"" then
if str_ktype = "title" then
str_GetKeyword = " and NewsTitle like '%"& str_Keyword &"%'"
Elseif str_ktype = "content" then
str_GetKeyword = " and content like '%"& str_Keyword &"%'"
Elseif str_ktype = "author" then
str_GetKeyword = " and author like '%"& str_Keyword &"%'"
Elseif str_ktype = "editor" then
str_GetKeyword = " and editor like '%"& str_Keyword &"%'"
End if
Else
str_GetKeyword = ""
End if
strpage=request("page")
if isnull(strpage) or strpage="" or not isnumeric(strpage) Then:strpage=1:end if
if cbool(strpage)<1 then strpage=1
newslist_sql = "Select ID,NewsID,PopID,ClassID,NewsTitle,SpecialEName,IsURL,isPicNews,URLAddress,Editor,Hits,NewsProperty,isLock,isRecyle,addtime,author,source from FS_NS_News where isRecyle=0 and isdraft=0 "& str_Editor & str_Rec & str_isTop & str_hot & str_pic & str_highlight & str_bignews & str_filt & str_Constr & str_ClassID_1 & str_check & SQL_SpecialEname & str_GetKeyword &" Order by PopID desc,addtime desc,ID desc"
Set obj_newslist_rs = Server.CreateObject(G_FS_RS)
obj_newslist_rs.Open newslist_sql,Conn,1,1
%>
<table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
<form name="myForm" method="post" action="">
<tr class="xingmu">
<td colspan="3" class="xingmu"><div align="center"> </div>
<div align="center">
<% = Fs_news.allInfotitle %>
标题</div></td>
<td width="12%" class="xingmu"><div align="center">录入者/编辑</div></td>
<td width="9%" class="xingmu"><div align="center">点击</div></td>
<td width="5%" class="xingmu"><div align="center">审核</div></td>
<td width="22%" class="xingmu"><div align="center">操作</div></td>
</tr>
<%
if obj_newslist_rs.eof then
obj_newslist_rs.close
set obj_newslist_rs=nothing
Response.Write"<TR class=""hback""><TD colspan=""7"" class=""hback"" height=""40"">没有"& Fs_news.allInfotitle &"。</TD></TR>"
else
str_showTF = 1
obj_newslist_rs.PageSize=int_RPP
cPageNo=NoSqlHack(Request.QueryString("Page"))
If cPageNo="" Then cPageNo = 1
If not isnumeric(cPageNo) Then cPageNo = 1
cPageNo = Clng(cPageNo)
If cPageNo<=0 Then cPageNo=1
If cPageNo>obj_newslist_rs.PageCount Then cPageNo=obj_newslist_rs.PageCount
obj_newslist_rs.AbsolutePage=cPageNo
for i=1 to obj_newslist_rs.pagesize
if obj_newslist_rs.eof Then exit For
if Get_SubPop_TF(obj_newslist_rs("ClassID"),"NS013","NS","news") then
Str_GetPopID = obj_newslist_rs("PopID")
if Str_GetPopID = 5 then
Str_PopID = "<IMG Src=""images/newstype/5.gif"" border=""0"" alt=""总置顶"& Fs_news.allInfotitle &",点击查看简洁内容"">"
str_Top = "<a href=News_Manage.asp?NewsID="& obj_newslist_rs("NewsID")&"&ClassId="& obj_newslist_rs("ClassId") &"&Action=signUnTop onClick=""{if(confirm('确定解除总固顶吗?')){return true;}return false;}"">解固</a>"
Elseif Str_GetPopID = 4 then
Str_PopID = "<IMG Src=""images/newstype/4.gif"" border=""0"" alt=""栏目置顶"& Fs_news.allInfotitle &",点击查看简洁内容"">"
str_Top = "<a href=News_Manage.asp?NewsID="& obj_newslist_rs("NewsID")&"&ClassId="& obj_newslist_rs("ClassId") &"&Action=signUnTop onClick=""{if(confirm('确定解除栏目固顶吗?')){return true;}return false;}"">解固</a>"
Elseif Str_GetPopID = 3 then
Str_PopID = "<IMG Src=""images/newstype/3.gif"" border=""0"" alt=""总推荐"& Fs_news.allInfotitle &",点击查看简洁内容"">"
str_Top = "<a href=News_Manage.asp?NewsID="& obj_newslist_rs("NewsID")&"&ClassId="& obj_newslist_rs("ClassId") &"&Action=signTop onClick=""{if(confirm('确定固顶吗?')){return true;}return false;}"">固顶</a>"
Elseif Str_GetPopID = 2 then
Str_PopID = "<IMG Src=""images/newstype/2.gif"" border=""0"" alt=""栏目推荐"& Fs_news.allInfotitle &",点击查看简洁内容"">"
str_Top = "<a href=News_Manage.asp?NewsID="& obj_newslist_rs("NewsID")&"&ClassId="& obj_newslist_rs("ClassId") &"&Action=signTop onClick=""{if(confirm('确定固顶吗?')){return true;}return false;}"">固顶</a>"
Elseif Str_GetPopID = 0 then
Str_PopID = "<IMG Src=""images/newstype/0.gif"" border=""0"" alt=""一般"& Fs_news.allInfotitle &",点击查看简洁内容"">"
str_Top = "<a href=News_Manage.asp?NewsID="& obj_newslist_rs("NewsID")&"&ClassId="& obj_newslist_rs("ClassId") &"&Action=signTop onClick=""{if(confirm('确定固顶吗?')){return true;}return false;}"">固顶</a>"
End if
if obj_newslist_rs("isUrl") = 1 then
str_UrlTitle = "<a href="""& obj_newslist_rs("URLAddress") &""" target=""_blank""><Img src=""../images/folder/url.gif"" border=""0"" alt=""标题新闻,点击转到标题地址""></img></a>"
Else
str_UrlTitle = ""
if obj_newslist_rs("isPicNews") = 1 then
tmp_pictf="<a href=""javascript:m_PicUrl('News_Pic_Modify.asp?NewsID="&obj_newslist_rs("NewsID")&"&ClassId="& obj_newslist_rs("ClassId") &"')""><Img src=""../images/folder/img.gif"" alt=""图片新闻,点击更改图片"" border=""0""></img></a>"
else
tmp_pictf="<Img src=""../images/folder/folder_1.gif"" alt=""文字新闻""></img>"
end if
end if
%>
<tr onMouseOver=overColor(this) onMouseOut=outColor(this)>
<td width="3%" class="hback"><div align="center">
<input name="C_NewsID" type="checkbox" id="C_NewsID" value="<% = obj_newslist_rs("ID")%>">
</div></td>
<td width="3%" height="18" class="hback" id=item$pval[CatID]) style="CURSOR: hand" onmouseup="opencat(M_Newsid<% = obj_newslist_rs("ID")%>);" language=javascript><% = Str_PopID %>
</td>
<td width="46%" class="hback"><% = str_UrlTitle %>
<% = tmp_pictf %>
<a href="News_edit.asp?NewsID=<% = obj_newslist_rs("NewsID")%>&ClassID=<% = obj_newslist_rs("ClassID")%>" title="添加日期:<% = obj_newslist_rs("addtime")%>">
<% = GotTopic(obj_newslist_rs("Newstitle"),50)%>
</a></td>
<td class="hback"><div align="center"> <a href="News_Manage.asp?ClassID=<% = Request.QueryString("ClassID")%>&Editor=<% = obj_newslist_rs("Editor")%>">
<% = obj_newslist_rs("Editor")%>
</a> </div></td>
<td class="hback"><div align="center"> <font style="font-size:10px">
<% = obj_newslist_rs("hits")%>
</font> </div></td>
<td class="hback"><div align="center">
<%if obj_newslist_rs("isLock")=1 then response.Write"<a href=""News_Manage.asp?NewsID="& obj_newslist_rs("NewsId") &"&Action=singleCheck"" onClick=""{if(confirm('确定通过审核吗?')){return true;}return false;}""><span class=""tx""><b>×</b></span></a>":else response.Write"<a href=""News_Manage.asp?NewsID="& obj_newslist_rs("NewsId") &"&Action=singleUnCheck"" onClick=""{if(confirm('确定锁定吗?')){return true;}return false;}""><b>√</b></a>"%>
</div></td>
<td class="hback"><div align="center"><a href="News_Review.asp?NewsID=<% = obj_newslist_rs("NewsID")%>&ClassID=<% = obj_newslist_rs("ClassID")%>" target="_blank">预览</a>|
<% = str_Top%>
|<a href="javascript:OpenWindow('lib/Frame.asp?FileName=NewsToJs.asp&Types=PicJs&PageTitle=添加到JS&NewsID=<% = obj_newslist_rs("ID")%>',350,135,window)">加入JS</a> |<a href="News_Manage.asp?NewsID=<% = obj_newslist_rs("NewsID")%>&Action=signDel&ClassId=<% = obj_newslist_rs("ClassId")%>" onClick="{if(confirm('确定要删除吗?\n\n如果你在系统参数设置中设置删除<% = Fs_news.allInfotitle %>到回收站\n<% = Fs_news.allInfotitle %>将删除到回收站中!\n必要时候可还原')){return true;}return false;}">删除</a></div></td>
</tr>
<tr id="M_Newsid<% = obj_newslist_rs("ID")%>" style="display:none">
<td height="35" colspan="7" class="hback"><table width="100%" border="0" cellspacing="0" cellpadding="5">
<tr class="hback_1">
<td width="45%" height="20" class="hback_1"><font style="font-size:12px">
<% = Fs_news.allInfotitle %>
类型:
<%
if trim(obj_newslist_rs("NewsProperty")) <>"" then
if split(obj_newslist_rs("NewsProperty"),",")(0) then Response.Write("荐|")
if split(obj_newslist_rs("NewsProperty"),",")(1) then Response.Write("滚|")
if split(obj_newslist_rs("NewsProperty"),",")(2) then Response.Write("评|")
if split(obj_newslist_rs("NewsProperty"),",")(3) then Response.Write("稿|")
if split(obj_newslist_rs("NewsProperty"),",")(4) then Response.Write("远图|")
if split(obj_newslist_rs("NewsProperty"),",")(5) then Response.Write("头|")
if split(obj_newslist_rs("NewsProperty"),",")(6) then Response.Write("热|")
if split(obj_newslist_rs("NewsProperty"),",")(7) then Response.Write("精|")
if split(obj_newslist_rs("NewsProperty"),",")(8) then Response.Write("规|")
if split(obj_newslist_rs("NewsProperty"),",")(9) then Response.Write("公|")
if split(obj_newslist_rs("NewsProperty"),",")(10) then Response.Write("幻|")
else
response.Write("--")
End if
if trim(obj_newslist_rs("SpecialEName"))<>"" then
str_Get_Special = ""
for sp_i = 0 to Ubound(split(obj_newslist_rs("SpecialEName"),","))
dim rs_speical
set rs_speical = Conn.execute("select SpecialCName,SpecialEName From FS_NS_Special where SpecialEName='"& split(obj_newslist_rs("SpecialEName"),",")(sp_i)&"'")
if not rs_speical.eof then
str_Get_Special = str_Get_Special & "<a href=""News_Manage.asp?SpecialEName="&rs_speical("SpecialEName")&"&SpecialCName="&server.URLEncode(rs_speical("SpecialCName"))&""">" &rs_speical("SpecialCName") &"</a>┆"
rs_speical.close:set rs_speical=nothing
else
str_Get_Special = "无专题"
rs_speical.close:set rs_speical=nothing
end if
next
str_Get_Special = str_Get_Special
else
str_Get_Special = "无专题"
end if
%>
</font></td>
<td width="22%" class="hback_1"><font style="font-size:12px">日期:
<% = obj_newslist_rs("addtime")%>
</font></td>
<td width="14%" class="hback_1"><font style="font-size:12px">作者: <a href="../../<%=G_USER_DIR%>/showuser.asp?UserName=<% = obj_newslist_rs("author")%>" target="_blank">
<% = obj_newslist_rs("author")%>
</a>
<%
Dim username
username=Fs_News.GetUserNumber(obj_newslist_rs("author"))
if username<>"" then
%>
(<%=Fs_News.newsStat(username,0)%>/<font color="#FF0000"><%=Fs_News.newsStat(username,1)%></font>)
<%End if%>
</font></td>
<td width="19%" class="hback_1"><font style="font-size:12px">来源:
<% = obj_newslist_rs("source")%>
</font></td>
</tr>
<tr class="hback_1">
<td height="20" class="hback_1"><font style="font-size:12px">所属专题:
<% = str_Get_Special %>
</font></td>
<td class="hback_1"> </td>
<td class="hback_1"> </td>
<td class="hback_1"> </td>
</tr>
</table></td>
</tr>
<%
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -