<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<!--#Include File="Inc/Main.asp"-->
<%
htmlDefault = "news"
'----------------------------------------------------------------
Set Rs      = Server.Createobject("ADODB.recordset")
'----------------------------------------------------------------
keys        = Replace_Text(Request("keys"))
keyn        = Replace_Text(Request("keyn"))
'----------------------------------------------------------------
m_Parameter = "keys="&keys&"&keyn="&keyn
listcs      = 20
'----------------------------------------------------------------
if keyn="" then keyn=0
%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="title" content="<%=Shop_WebKey%>">
<meta name="keywords" content="<%=Shop_WebKey%>">
<meta name="description" content="<%=Shop_WebDes%>">
<title>动态公告 - <%=Shop_WebName%> - <%=Shop_WebKey%></title>
<link rel="stylesheet" type="text/css" href="Css/all.css" />
<script type="text/javascript" src="Js/All.js"></script>
<script type="text/javascript" src="Js/jquery-1.7.2.min.js"></script>
<script language="Javascript">	  
function searchall(){
var keys = document.newslist.keys.value;
var keyn = document.newslist.keyn.value;
document.newslist.action="News.asp?keys="+keys+"&keyn="+keyn;
document.newslist.submit();	  
}
</script>
</head>
<body>
<!--#include file="_Alert.asp" -->
<!--#include file="_Box.asp" -->
<!--#Include File="_Up.asp"-->

<form name="newslist" method="post">
<input type="hidden" name="keyn" value="<%=keyn%>" />
<div style="width:1200px; margin:0 auto; display:table;">

<div style="width:1198px; line-height:25px; font-size:12px; border:1px solid #E8E8E8; background:#F0EFEB; margin-top:10px; border-radius:3px 3px 0 0; display:table;">
  <div style="float:left; display:inline-block; padding:10px 20px; <%if keyn=0 then%>background:#FFF;<%end if%> border-right:1px solid #E0DED8;"><a href="News.asp?keyn=0" class="newsLinka">全部公告</a></div>
<%
Set Rsg = Server.Createobject("ADODB.recordset")
sqls="Select * From OUCCS_MenuAll where pid=9 and t=1 and flag=1 and www='"&Clsm_Domaine&"' Order By num Asc"
Rsg.open sqls,wConn,1,1
kall = Rsg.RecordCount
K1=0
while not Rsg.eof
%>
  <div style="float:left; display:inline-block; padding:10px 20px; <%if Clng(keyn)=Rsg("id") then%>background:#FFF;<%end if%> border-right:1px solid #E0DED8;"><a href="News.asp?keyn=<%=Rsg("id")%>" class="newsLinka"><%=Rsg("title")%></a></div>
<%
K1=K1+1
Rsg.movenext
wend
Rsg.Close
set Rsg=nothing
%>

  
  <div style="float:right; display:inline-block; padding:7px 20px 7px 0; color:#C81623;">
  <input type="button" name="button" value="查询" style=" padding:0 10px; height:31px; background:#5BBC5D; border:none; color:#FFF; font-size:12px; " onClick="searchall()" />
  </div>
  <div style="float:right; display:inline-block; padding:7px 0 7px 20px; border-left:1px solid #E0DED8; color:#C81623;">
  <input type="text" name="keys" value="<%=keys%>" style=" width:200px; height:29px; line-height:29px; background:#FFF; border:none; overflow:hidden; " />
  </div>
</div>
<div style="width:1178px; line-height:25px; font-size:12px; border-left:1px solid #E8E8E8; border-right:1px solid #E8E8E8; border-bottom:1px solid #E8E8E8; background:#FFFFFF; padding:10px; border-radius:0 0 3px 3px; display:table;">








<%
sqltext  = "select * from [OUCCS_NewsList] where n_pid=9 and n_distinction=1 and www='"&Clsm_Domaine&"' "

'分类
if Clng(keyn)>0 then
sqltext  = sqltext&" and n="&keyn&" "
end if

'标题
if keys<>"" then
sqltext  = sqltext&" and n_title like '%"&keys&"%' "
end if

sqltext  = sqltext&" order by n_time desc"


Rs.open sqltext,wConn,1,1


    m_RecordCount=0 : m_PageNo=0 : m_Page=0
	m_PageSize = listcs
    m_PageNo = Trim(Request.querystring("PageNo"))
	m_RecordCount = rs.RecordCount
    rs.PageSize = m_PageSize
    m_Page = rs.PageCount
	if m_PageNo = ""  then m_PageNo =1
    if cint(m_PageNo) < 1 or cint(m_PageNo) > m_Page then m_PageNo = 1
    rs.AbsolutePage = m_PageNo
    rc = m_PageSize
    re = 1
	m_Count = 1
	thePage = (m_PageNo-1)*m_PageSize+1
	N=0
	lastnum = 0
%>
<div style="width:1178px; display:table;" id="newsnewsList">
<%if not(Rs.bof and Rs.eof) then%>
<%
For i=1 to m_PageSize
If Rs.Eof Then Exit For
lastnum      = lastnum+1
N0           = Rs("n_id")
Ntitle       = Rs("n_title")
Npic1        = Rs("pic1")
Ncontent     = Rs("n_content")
Ntime        = Rs("n_time")
Nhit         = Rs("n_hit")
%>
<div style="width:1178px; display:table; padding:10px 0; border-bottom:1px solid #E8E8E8;">

<%if Npic1<>"" then%>
<div style="float:left; display:inline-block; width:120px; height:90px; overflow:hidden; border-radius:3px; background:url(<%=Npic1%>) center center no-repeat; background-size:100% 100%;"></div>
<div style="float:left; display:inline-block; width:918px; height:90px; margin:0 20px; overflow:hidden;">
<div style="width:100%; height:30px; font-size:18px;"><a href="News.S.asp?ID=<%=N0%>" target="_blank" class="newsLinka"><%=Ntitle%></a></div>
<div style="width:100%; height:60px; line-height:20px; color:#666666; font-size:12px;"><%=Removehtml(Ncontent)%></div>
</div>
<%else%>
<div style="float:left; display:inline-block; width:1048px; height:90px; margin:0 20px 0 10px; overflow:hidden;">
<div style="width:100%; height:30px; font-size:18px;"><a href="News.S.asp?ID=<%=N0%>" target="_blank" class="newsLinka"><%=Ntitle%></a></div>
<div style="width:100%; height:60px; line-height:20px; color:#666666; font-size:12px;"><%=Removehtml(Ncontent)%></div>
</div>
<%end if%>
<div style="float:left; display:inline-block; width:100px; height:50px; margin:20px 0; overflow:hidden; color:#999999;">
浏览：<%=Nhit%><br>
时间: <%=Ntime%>
</div>

</div>
<%
Rs.Movenext
N=N+1
Next
end if
Rs.close
set Rs=nothing
%>
</div>
<input type="hidden" name="lastid" value="<%=N0%>" />
<input type="hidden" name="lastnum" value="<%=lastnum%>" />
<div style="width:1178px; height:40px; line-height:40px; display:table; text-align:center; font-size:13px; color:#888888; cursor:pointer; margin-top:10px;" onClick="newsSearchMore()">加载更多</div>







</div>


</div>
</form>


<!--#Include File="_Dn.asp"-->
</body>
</html>
