<!--#include file="conn.asp"-->
<!--#include file="config.asp"-->
<!--#include file="function.asp"-->
<!--'#include file="char.inc"-->
        <%
		Function getcode1()
			Dim test
			On Error Resume Next
			Set test=Server.CreateObject("Adodb.Stream")
			Set test=Nothing
			If Err Then
				Dim zNum
				Randomize timer
				zNum = cint(8999*Rnd+1000)
				Session("verifycode") = zNum
				getcode1= Session("verifycode")		
			Else
				getcode1= "<img src=""getcode.asp"">"		
			End If
		End Function
		
IF request.cookies(echsys)("KEY")="" THEN

else
	usernamecookie=CheckStr(request.cookies(echsys)("UserName"))
	passwdcookie=CheckStr(trim(Request.cookies(echsys)("passwd")))
	KEYcookie=CheckStr(trim(request.cookies(echsys)("KEY")))
	if usernamecookie="" or passwdcookie="" then
		response.cookies(echsys)("UserName")=""
		response.cookies(echsys)("KEY")=""
		response.cookies(echsys)("purview")=""
		response.cookies(echsys)("fullname")=""
		response.cookies(echsys)("reglevel")=""
	else
		'判断用户的合法性
		set rs=server.createobject("adodb.recordset")
		sql="select * from "& db_User_Table &" where "& db_User_Name &"='"&usernamecookie&"'"
		rs.open sql,ConnUser,1,1
		if rs.eof and rs.bof then
			response.cookies(echsys)("UserName")=""
			response.cookies(echsys)("KEY")=""
			response.cookies(echsys)("purview")=""
			response.cookies(echsys)("fullname")=""
			response.cookies(echsys)("reglevel")=""
		end if
		IF passwdcookie<>rs(db_User_Password) THEN
			response.cookies(echsys)("UserName")=""
			response.cookies(echsys)("KEY")=""
			response.cookies(echsys)("purview")=""
			response.cookies(echsys)("fullname")=""
			response.cookies(echsys)("reglevel")=""
		END IF
		'下面判断用户级别实际在有用户级别是都应该判断
		if KEYcookie<>rs("OSKEY") then
			response.cookies(echsys)("UserName")=""
			response.cookies(echsys)("KEY")=""
			response.cookies(echsys)("purview")=""
			response.cookies(echsys)("fullname")=""
			response.cookies(echsys)("reglevel")=""
		end if
		rs.close
		set rs=nothing
	END IF
END IF



'该文件需要进行调整和设置
dim E_typename
EC_ArticleID=ChkRequest(Request.QueryString("EC_ArticleID"),1) '防SQL注入
Page=Request.QueryString("page")

if page="" then
	page=1
	elseif not IsNumeric(page) then
		Show_Err("非法参数！<br><br><a href='javascript:history.back()'>返回</a>")
		response.end
	end if
	page=int(page)
	if EC_ArticleID="" then
		Show_Err("未指定参数！<br><br><a href='javascript:history.back()'>返回</a>")
		response.end
	elseif not IsNumeric(EC_ArticleID) then
		Show_Err("非法参数！<br><br><a href='javascript:history.back()'>返回</a>")
		response.end
	else
		'判断该篇文章是否审核
		set rs=server.createobject("adodb.recordset")
		sql="select * from "& db_wygkcn_Article_Table &" where EC_ArticleID="&EC_ArticleID
		rs.open sql,conn,3,3
		if rs.eof and rs.bof then
			rs.close
			set rs=nothing
			Show_Err("指定的文章不存在！<br><br><a href='javascript:history.back()'>返回</a>")
			response.end
		else
			Checked=rs("Checked")
			if checked=1 or Request.cookies(echsys)("key")="super" or Request.cookies(echsys)("key")="typemaster" or Request.cookies(echsys)("key")="bigmaster" or Request.cookies(echsys)("key")="smallmaster" then	'文章已审核并且是相关管理员
				Click=rs("Click")
				if isnull(rs("Click"))  then
					conn.execute("update "& db_wygkcn_Article_Table &" Set Click=1 where EC_ArticleID=" & EC_ArticleID )
				else 
					conn.execute("update "& db_wygkcn_Article_Table &" Set Click=click+1 where EC_ArticleID=" & EC_ArticleID )
				end if
			end if
		
			rs.close
			set rs=nothing
		end if

		set rs=server.CreateObject("ADODB.RecordSet")
		if uselevel=1 then
			if Request.cookies(echsys)("key")="" then
				rs.Source="select * from "& db_wygkcn_Article_Table &" where Checked=1 and newslevel=0 and EC_ArticleID="&EC_ArticleID
			end if
			if Request.cookies(echsys)("key")="selfreg" then
				if Request.cookies(echsys)("reglevel")=3 then
					rs.Source="select * from "& db_wygkcn_Article_Table &" where Checked=1 and newslevel<=3 and EC_ArticleID="&EC_ArticleID
				end if
				if Request.cookies(echsys)("reglevel")=2 then
					rs.Source="select * from "& db_wygkcn_Article_Table &" where Checked=1 and newslevel<=2 and EC_ArticleID="&EC_ArticleID
				end if
				if Request.cookies(echsys)("reglevel")=1 then
					rs.Source="select * from "& db_wygkcn_Article_Table &" where Checked=1 and newslevel<=1 and EC_ArticleID="&EC_ArticleID
				end if
			end if
		end if
			if Request.cookies(echsys)("key")="super" or Request.cookies(echsys)("key")="typemaster" or Request.cookies(echsys)("key")="bigmaster" or Request.cookies(echsys)("key")="smallmaster" or Request.cookies(echsys)("key")="check" then
				rs.Source="select * from "& db_wygkcn_Article_Table &" where EC_ArticleID="&EC_ArticleID
			else
				rs.Source="select * from "& db_wygkcn_Article_Table &" where EC_ArticleID="&EC_ArticleID
			end if
			rs.Open rs.Source,conn,1,1
			E_BigClassID=rs("E_BigClassID")
			E_SmallClassID=rs("E_SmallClassID")
			title=htmlencode4(trim(rs("title")))
			title1=htmlencode4(trim(rs("title")))
			about=htmlencode4(trim(rs("about")))
			Author=htmlencode4(trim(rs("Author")))
			editor=htmlencode4(trim(rs("editor")))
			Original=htmlencode4(trim(rs("Original")))
			image=rs("image")
			UpdateTime=trim(rs("UpdateTime"))
			News_Content=rs("Content")
			EC_SpecialID=rs("EC_SpecialID")
			EC_SpecialID2=rs("EC_SpecialID2")
			click=rs("click")
			EnCode=trim(rs("EnCode"))
			E_typeid=rs("E_typeid")
			titletype=rs("titletype")
			titlecolor=rs("titlecolor")
			titleface=rs("titleface")
			editor=rs("editor")
			wzdj=rs("newslevel")
			backtype=rs("backtype")
			backtype1=rs("backtype1")
			rs.Close
			set rs=nothing

			set rs=server.CreateObject("ADODB.RecordSet")
			rs.Source="select * from "& db_wygkcn_Type_Table &" where E_typeid=" & E_typeid
			rs.Open rs.Source,conn,1,1
			E_typename=rs("E_typename")
			rs.Close
			set rs=nothing

			set rs=server.CreateObject("ADODB.RecordSet")
			If(isnull(E_BigClassID)) Then
				E_BigClassName=" "
				E_BigClassID = 0
			Else
				rsSource="select * from "& db_wygkcn_BigClass_Table &" Where E_BigClassID="& E_BigClassID
				rs.Open rsSource,conn,1,3
				If (rs.eof or rs.bof) Then
					E_BigClassName=" "
				else
					E_BigClassName=rs("E_BigClassName")
				End if
				rs.close
				set rs=nothing
			End if
			
			if E_SmallClassID<>"" then
				set rs=server.CreateObject("ADODB.RecordSet")
				rs.Source="select * from "& db_wygkcn_SmallClass_Table &" Where E_SmallClassID=" & E_SmallClassID
				rs.Open rs.Source,conn,1,1
				E_smallclassname=rs("E_smallclassname")
				rs.close
				set rs=nothing
			end if%>
<%
'文章ip限制
	if cINT(backtype1)=1 then
	dim byte2
	byte2=split(newsipType,"|")
	for i=0 to ubound(byte2)
		if Request.serverVariables("REMOTE_ADDR")<>byte2(i) then
		Show_Err("对不起，此篇文章只供内部浏览，请联系管理员！。<br><br><a href='javascript:history.back()'>返回</a>")
		Response.End
		end if
	next
	end if
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="gb2312">
<head>
<!--版权所有@天琪高科 www.tqgk.net Powered By www.tqgk.net-->
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="Description" content="<%=SiteDescription%>">
<meta name="keywords" content="<%=SiteKeywords%>">
<title><%=title%><%if E_SmallClassID<>"" then%>_<%=E_smallclassname%><%end if%>_<%=E_BigClassName%>_<%=E_typename%>_<%=eChSys_Com%></title>
<LINK href="CSS/Wygkcn_Home.css" rel="stylesheet">
<LINK href="CSS/Wygkcn_News.css" rel="stylesheet">
<noscript><iframe scr="*"></iframe></noscript>
<script language="JavaScript" type="text/JavaScript">
function validateMode()
{
  if (!bTextMode) return true;
  alert("请先取消查看HTML源代码，进入“编辑”状态，然后再使用系统编辑功能!");
  message.focus();
  return false;
}
function validateModea()
{
  if (!bTextMode) return true;
  alert("请先取消查看HTML源代码!");
  message.focus();
  return false;
}

function sign()
{if (!validateMode()) return;
message.focus();

var range =message.document.selection.createRange();
str1="<font color='red'><b>|签收|</b>文件已经阅读</font>"
   range.pasteHTML(str1);
}

function img_zoom(e, o)		//图片鼠标滚轮缩放
{
	var zoom = parseInt(o.style.zoom, 10) || 100;
	zoom += event.wheelDelta / 12;
	if (zoom > 0) o.style.zoom = zoom + '%';
		return false;
}
</script>

<script language=javascript>
function user_login()
{
	document.UserLogin.UserName.focus();
	return false;
}
</script>

<script language="JavaScript" type="text/JavaScript">
<!--
function MM_preloadImages() { //v3.0
	var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
	var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
	if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
//-->
</script>

<SCRIPT language=JavaScript>

//========================= 设置字体大中小 start =============
	function doZoom(size){
		var zw_content = document.getElementById('zw_content');
		if(!zw_content){
			return;
		}
		var zw_contentChild = zw_content.childNodes;
		zw_content.style.fontSize = size + 'px';
		//再对zw_content div内的直接html节点设置fontSize属性
		for(var i = 0; i < zw_contentChild.length; i++){
			if(zw_contentChild[i].nodeType == 1){
				zw_contentChild[i].style.fontSize = size + 'px';
			}
		}		
	}
//========================= 设置字体大中小 end =============

</SCRIPT>

<script language="javascript">
<!--
function changedata() {
	if ( document.AddReview.none.checked ) {
		document.AddReview.Author.value = "游客";
	} 
}
function changedata1() {
	if ( document.AddReview.none1.checked ) {
		document.AddReview.email.value = "58728@tqgk.net";
	} 
}

//-->
</script>

<script language=javascript>
function CheckFormAddReview()	//检测评论发表栏填写项目是否为空
{
	if(document.AddReview.Author.value=="")
	{
		alert("请输入用户名！");
		document.AddReview.Author.focus();
		return false;
	}
	if(document.AddReview.email.value == "")
	{
		alert("请输入您的EMAIL！");
		document.AddReview.email.focus();
		return false;
	}
	if(document.AddReview.verifycode.value == "")
	{
		alert("请输入验证码！");
		return false;
	}
	if(document.AddReview.content.value == "")
	{
		alert("请输入评论内容！");
		return false;
	}
}
</script>
</head>
<%if ScrollClick = "double" then%>
	<SCRIPT language=JavaScript>
	//双击滚屏代码
	var currentpos,timer;
	
	function initialize()
	{
	timer=setInterval("scrollwindow()",50);
	}
	
	function sc(){
	clearInterval(timer);
	}
	
	function scrollwindow()
	{
	currentpos=document.body.scrollTop;
	window.scroll(0,++currentpos);
	if (currentpos != document.body.scrollTop)
		sc();
	}
	document.onmousedown=sc
	document.ondblclick=initialize
	</script>
<%else%>
	<SCRIPT>
	//单击拖动屏幕方式
	var old_y=0;  //记录鼠标按下时的Ｙ轴位置
	var yn=0;  //用于记录鼠标状态
	function moveit()
	{
	if(yn==1 &&  event.button==1)  //如果鼠标左键按下就移动页面
	document.body.scrollTop=(old_y-event.clientY); //移动页面
	}
	function downit()
	{old_y=event.clientY+document.body.scrollTop; //记住鼠标按下时的Ｙ轴位置
	yn=1; //用于记住鼠标已按下
	}
	
	function upit()
	{yn=0;}  //记住鼠标已放开
	
	document.onmouseup=upit; //鼠标放开时执行upit()函数
	document.onmousedown=downit; //鼠标按下时执行downit()函数
	document.onmousemove =moveit; //鼠标移动时执行moveit()函数
	</SCRIPT>
<%end if%>
<body>
<!--内容部分开始-->
<div id="EC_Content">
<SCRIPT language=javascript>
<!--
  function do_color(vobject,vvar)
  { document.getElementById(vobject).style.color=vvar; }
  function do_zooms(vobject,vvar)
  { document.getElementById(vobject).style.fontsize=vvar+'px'; }
-->
</SCRIPT>
<!--#include file="Top.asp"-->


<!--中间内容部分开始-->
<div id="EC_Cnt_center">
<!--左边部分开始-->

<div class="EC_Cnt_Left float_left">


<!--正文部分开始-->
<DIV class=EC_Content_Left>
<!--位置导航部分开始-->
<div class="position">
<img src="Images/lm_dot.gif" width="11" height="11">&nbsp;&nbsp;您的位置&nbsp;&nbsp;<a href="./" >首页</a> >> <a href="wygkcn_Type.asp?E_typeid=<%=E_typeid%>"><%=E_typename%></a>
        <%if E_BigClassID<>"" then%>
        >> <a href="wygkcn_BigClass.asp?E_typeid=<%=E_typeid%>&E_BigClassID=<%=E_BigClassID%>"><%=E_BigClassName%></a>
        <%if E_SmallClassID<>"" then%>
        >> <a href='wygkcn_SmallClass.asp?E_typeid=<%=E_typeid%>&E_BigClassID=<%=E_BigClassID%>&E_SmallClassID=<%=E_SmallClassID%>'><%=E_smallclassname%></a>
        <%end if%>
        <%end if%>
        >> 正文
</div>
<!--位置导航部分结束-->

<div class=EC_News_Title><font color="<%=titlecolor%>"><%=title1%></font></div>


<div class=art_info>
[来源：<%if Original="" then%>本站<%else%><%=Original%><%end if%> | 作者：<%if Author="" then%>中国天琪高科<%else%><%=Author%><%end if%> | 日期：<%=year(updateTime)%>年<%=month(updateTime)%>月<%=day(updateTime)%>日 |  浏览<font color=red><%=click%></font> 次] 

字体:[<A href="javascript:doZoom(16)">大</A> <A href="javascript:doZoom(14)">中</A> <A href="javascript:doZoom(12)">小</A>]
</div>
<div id=zw_content>
      <%
set rs=server.CreateObject("ADODB.RecordSet")
rs.Source="select * from "& db_wygkcn_Article_Table &" where EC_ArticleID=" & EC_ArticleID
rs.Open rs.source,conn,1,1
E_typeid=rs("E_typeid")
Title=trim(rs("Title"))
image=rs("image")

dim mode
    
set rs11=server.CreateObject("ADODB.RecordSet")
rs11.Source="select * from "& db_wygkcn_Type_Table &" where E_typeid="&E_typeid&" order by E_typeid"
rs11.Open rs11.Source,conn,1,1
mode=rs11("mode")
rs11.close
set rs11=nothing

''添加图片鼠标滚轮缩放效果
if mouse_wheel_zoom="on" then
	News_Content=replace(News_Content,"<IMG","<IMG onmousewheel='return img_zoom(event,this)' onload='javascript:if(this.width>screen.width-333)this.width=screen.width-333'",1,-1,1) 
end if
''图片上传路径还原为 config.asp 中设定的 [FileUploadPath] 值
News_Content=replace(News_Content,"="&chr(34)&"uploadfile/","="&chr(34)&FileUploadPath,1,-1,1)

arr_Content=split(News_Content,"[---分页---]")
MaxPages=ubound(arr_Content)
%>


<%if (checked<>1) and ((Request.cookies(echsys)("key")<>"super") and (Request.cookies(echsys)("key")<>"typemaster") and (Request.cookies(echsys)("key")<>"bigmaster") and (Request.cookies(echsys)("key")<>"smallmaster")) then	'文章未审核,并且是非相关管理员
	response.write "<P><CENTER><strong><font color='ff0000' size='+2' face='隶书'>文章还未经过审核<br>请等待或者通知管理员审核才能阅览！</font></strong></CENTER>"
	response.write "<P><CENTER><IMG SRC='" &ReadNews_CopyRight_Logo& "' BORDER='0' ALT=''></CENTER>"
else	'文章已审核
	if checked<>1 then
		response.write "<P><CENTER><strong><font color='ff0000' size='+2' face='隶书'>提醒：该文章还未通过审核</font></strong></CENTER>"
	end if



if uselevel=1 then

	if cINT(wzdj)<1 then
		Response.Write arr_Content(Page-1)%>
                  <% else %>
                  <%if Request.cookies(echsys)("key")="super" or Request.cookies(echsys)("key")="typemaster" or Request.cookies(echsys)("key")="bigmaster" or Request.cookies(echsys)("key")="smallmaster" or Request.cookies(echsys)("key")="check" then %>
                  <%Response.Write arr_Content(Page-1)%>
                  <% else %>
                  <%if  Request.cookies(echsys)("key")="" then%>
                  <br>
                  <font color="#cc0000"><b>内容简介：</b></font><br>
                  <br>
                  <%=CutStr(nohtml(rs("Content")),10)%>... <br>
                  <br>
                  <br>
                  <font color="#cc0000"><b>友情提醒：</b></font><br>
                  <br>
                你还没注册？或者没有登录？或者权限不够？这篇文章要求是本站符合权限要求的注册用户才能阅读！<br>
                <br>
                <%
				response.write "文章级别："
				response.write cINT(wzdj)
				response.write "级"
				%>
                <br>
                <%
				response.write "您的权限："
				response.write "未注册"
				%>
                <br>
                <br>
                如果你还没注册，请赶紧点此<a href="#" OnClick="adduser()"  class=bottom><font color="#cc0000">注册</font></a>吧！<br>
                <br>
                如果你已经注册但还没登录，请赶紧点此<a href="#" OnClick="user_login()"  class=bottom><font color="#cc0000">登录</font></a>吧！<br>
                <% else %>
                <%if  Request.cookies(echsys)("key")="selfreg" then
					if cINT(Request.cookies(echsys)("reglevel"))>=cINT(wzdj) then%>
                <%Response.Write arr_Content(Page-1)%>
                <% else %>
                <br>
                <font color="#cc0000"><b>内容简介：</b></font> <br>
                <br>
                <%=CutStr(nohtml(rs("Content")),10)%>... <br>
                <br>
                <br>
                <font color="#cc0000"><b>友情提醒：</b></font><br>
                <br>
                你还没注册？或者没有登录？或者权限不够？这篇文章要求是本站符合权限要求的注册用户才能阅读！<br>
                <br>
                <%
						response.write "文章级别："
						response.write cINT(wzdj)
						response.write "级"
						%>
                <br>
                <%
						response.write "您的权限："
						response.write (Request.cookies(echsys)("reglevel"))
						response.write "级"
						%>
                <br>
                <br>
                如果你还没注册，请赶紧点此<a href="#" OnClick="adduser()" class=bottom><font color="#cc0000">注册</font></a>吧！<br>
                <br>
                如果你已经注册但还没登录，请赶紧点此<a href="#" OnClick="user_login()"  class=bottom><font color="#cc0000">登录</font></a>吧！<br>
                <br>
                <%end if%>
                <%end if%>
                <%end if%>
                <%end if%>
                <%end if%>
                <%else%>
                <%Response.Write arr_Content(Page-1)%>
                <%end if%>
                <%end if%>
                <br>
<%
url="wygkcn_ShowArticle.asp?EC_ArticleID="&EC_ArticleID
if MaxPages >0 then
	Response.write "<a  href='"& Url &"&page=1' title='第1页'>首页</a> "
	if Page-1 > 0 then
		Prev_Page = Page - 1
		Response.write "<a  href='"& Url &"&page="& Prev_Page &"' title='第"& Prev_Page &"页'>上一页</a> "
	end if

	for PageCounter=0 to MaxPages
		PageLink = PageCounter+1
		if PageLink <> Page Then
			Response.write "<a  href='"& Url &"&page="& PageLink &"'>["& PageLink &"]</a> "
		else
			Response.Write "<font color='#FF0000'><B>["& PageLink &"]</B></font> "
		end if
		If PageLink = MaxPages+1 Then Exit for
	Next
	if page <= Maxpages then
		bdd_Page = Page + 1
		Response.write "<a href='" & Url & "&page=" & bdd_Page & "' title='第" & bdd_Page & "页'>下一页</A>"
	end if
	Response.write " <A href='" & Url & "&page=" & Maxpages+1 & "' title='第"& Maxpages+1 &"页'>尾页</A>"
end if
%>

<!--#include file="attach.asp" -->
<div class=editor>责任编辑：<%=editor%></div>
</div>
<div class=pages>
上一篇：<%if getSideEC_ArticleID(E_TypeID,EC_ArticleID,-1)<>0 then %><a href="wygkcn_ShowArticle.asp?EC_ArticleID=<%=getSideEC_ArticleID(E_TypeID,EC_ArticleID,-1)%>"><%=getnewstitle(getSideEC_ArticleID(E_TypeID,EC_ArticleID,-1))%></a>
<%else%>
<%=getnewstitle(getSideEC_ArticleID(E_TypeID,EC_ArticleID,-1))%>		  
<%end if%><br>
下一篇：<%if getSideEC_ArticleID(E_TypeID,EC_ArticleID,1)<>0 then %><a href="wygkcn_ShowArticle.asp?EC_ArticleID=<%=getSideEC_ArticleID(E_TypeID,EC_ArticleID,1)%>"><%=getnewstitle(getSideEC_ArticleID(E_TypeID,EC_ArticleID,1))%></a>
<%else%>
<%=getnewstitle(getSideEC_ArticleID(E_TypeID,EC_ArticleID,1))%>		  
<%end if%>
</div>
<div class="about_news">

<div class="float_left about_art">
<H3>相关文章</H3>
<div>
<ul class="list">
<%
Response.Write ""
Response.Write ""
if about<>""  then
	sql="select top 6 * from "& db_wygkcn_Article_Table &" where (about like '%" & about & "%' or title like '%" & about & "%') and Checked=1 order by EC_ArticleID desc"
	set rs=conn.execute(sql)
	do while not rs.eof
	title=htmlencode4(trim(rs("title")))
%>
<li><span class=float_right>[<%=rs("click")%>]</span>·<a target="_blank" href="wygkcn_ShowArticle.asp?EC_ArticleID=<%=rs("EC_ArticleID")%>"><%=Title%></a></li>
<% 
rs.movenext
loop
	rs.close   
	set rs=nothing  
else
	Response.write "<li>·没有相关文章</li>"
end if
%>
</ul>
</div>
</div>

<div class="float_right about_spec">
<H3>相关专题</H3>
<div>
<ul class=list>
<%
set rs4=server.CreateObject("ADODB.RecordSet")
if EC_SpecialID<>0 then
	rs4.Source="select * from "& db_wygkcn_Special_Table &" where EC_SpecialID=" & EC_SpecialID
	rs4.Open,conn,1,3
	if not rs4.eof then
%>

<li><a href='Special_News.asp?EC_SpecialID=<%=EC_SpecialID%>'>·<%=CutStr(trim(rs4("E_SpecialName")),26)%></a></li>
<%			
    end if
	rs4.Close
	set rs4=nothing
else
	Response.Write "<li>·专题1信息无</li>"
end if
%>
<%
set rs4=server.CreateObject("ADODB.RecordSet")
if EC_SpecialID2<>0 then
rs4.Source="select * from "& db_wygkcn_Special_Table &" where EC_SpecialID=" & EC_SpecialID2
rs4.Open,conn,1,3
if not rs4.eof then 
%>
<li><a href='Special_News.asp?EC_SpecialID=<%=EC_SpecialID2%>'>·<%=CutStr(trim(rs4("E_SpecialName")),26)%></a></li>
<%
end if
rs4.Close
set rs4=nothing
else
Response.Write "<li>·专题2信息无</li>"
end if
%>
</ul>
</div>
</div>
<div class="clear_float"></div>
</div>
<!--评论部分开始-->
<%if reviewable="1" then%>
<div class="comment">
<div class=comment_title><SPAN class=float_right><a href=Review.asp?EC_ArticleID=<%=EC_ArticleID%> target="_blank">更多..</a></SPAN>·相关评论</div>
<div class=comment_cnt>
<ul>
<%
set rs1=server.CreateObject("ADODB.RecordSet")
rs1.Source="select top "&reviewnum&" * from "& db_wygkcn_Review_Table &" where EC_ArticleID=" & EC_ArticleID & " and passed=1 order by reviewid desc"
rs1.Open rs1.Source,conn,1,1
if rs1.EOF then  NoReview=1
%>

<%
if NoReview then 						
  Response.Write "·暂无相关评论"
end if
%>

<%
if not NoReview then
	while not rs1.EOF
	author=server.HTMLEncode(trim(rs1("author")))
	email=server.HTMLEncode(trim(rs1("email")))
	reviewip=rs1("reviewip")
	content=trim(rs1("content"))
    content=replace(content,"table","ｔａｂｌｅ")
	content=replace(content,"TABLE","ｔａｂｌｅ")
	ContentLen=len(Content)
%>

<li class=comment_list>
发表人：<%=author%>&nbsp;&nbsp;
发表人邮件：<a href='mailto:<%=email%>'><%=email%></a>&nbsp;&nbsp;
发表时间：<%=rs1("updatetime")%>&nbsp;&nbsp;
<%if Request.cookies(echsys)("key")="super" or showip="1" then%>IP：<%=reviewip%><%end if%>
</li>
<li>
<%
If ContentLen=<50  then	
DisplayContent=Content
Response.Write "&nbsp;&nbsp;&nbsp;&nbsp;" & displaycontent
%>
<%else%>
<%
DisplayContent=replace(nohtml(trim(Content)),"&nbsp;","",1,-1,1) '获取表格中留言字段内容并替换格式符
DisplayContent=replace(DisplayContent,vbcrlf,"",1,-1,1)
Response.Write "&nbsp;&nbsp;&nbsp;&nbsp;"& CutStr(displaycontent,50) &"<a href='ReadView.asp?ReviewID=" & rs1("ReviewID") &"&EC_ArticleID=" & EC_ArticleID &"' target=_blank>详细内容</a>"
end if
%>
</li>
<%
rs1.MoveNext
wend
end if

rs1.Close
set rs1=nothing	
%>
</ul>
</div>
<div class=comment_tab>

<form method="POST" action="AddReview.asp" name=AddReview  onSubmit="return CheckFormAddReview();">
<%if Request.cookies(echsys)("username")<>"" then%>
<input type=hidden name=EC_ArticleID value=<%=EC_ArticleID%>>
用户名：<input type="text" name="Author" style="width:100px;height:16px;border:1px solid #9FAABF" value="<%=Request.cookies(echsys)("UserName")%>" readonly>
电子邮件：<input type="text" name="email" style="width:100px;height:16px;border:1px solid #9FAABF" value="<%=Request.cookies(echsys)("UserEmail")%>" >
验证码：<input name="verifycode" type="text"  style="width:50px;height:16px;border:1px solid #9FAABF" ><%=getcode1()%>
<br/>
评论内容：（100字以内）
<% if M_MAIN=1 then %>
<font color=red >签收文件</font>： <img class=None  src="images/watermark.gif" align="absmiddle" border="0" style="cursor:hand;" alt="签收文件" lANGUAGE="javascript" onClick="sign()"><br/>
<% end if%>
<script language="javascript">
var bTextMode=false;
document.write ('<iframe src="guestbox.asp?action=new" id="message" width="98%" height="100" frameborder=yes scrolling=no align=center></iframe>')
frames.message.document.designMode = "On";
</script>
<br/>
<input type="hidden" name="editor" value="<%=editor%>">
<input name="passed" type="hidden" value="<%if reviewcheck="1" then%>1<%else%>0<%end if%>">
<input type="submit" value="发表评论" name="Submit3" OnClick="document.AddReview.content.value = frames.message.document.body.innerHTML;">
<input name="reset" type=reset value="重新填写">
<input type="hidden" name="content" value="">
<input type="hidden" name="title" value="评论：<%=title%>">
<%else%>

<input type=hidden name=EC_ArticleID value=<%=EC_ArticleID%>>
用户名：<input type="text" name="Author" style="width:100px;height:16px;border:1px solid #9FAABF">
游客：<INPUT onclick=changedata() type=checkbox value=true  name=none>
电子邮件：<input name="email" type="text" value="" style="width:100px;height:16px;border:1px solid #9FAABF">
游客：<INPUT onclick=changedata1() type=checkbox value=true  name=none1>
验证码：<input name="verifycode" type="text"  style="width:50px;height:16px;border:1px solid #9FAABF" ><%=getcode1()%>
<br/>
评论内容：（100字以内）<br/>
<script language="javascript">
document.write ('<iframe src="guestbox.asp?action=new" id="message" width="98%" height="100" frameborder=yes scrolling=no align=center></iframe>')
frames.message.document.designMode = "On";
</script><br/>
<input type="hidden" name="editor" value="<%=editor%>">
<input name="passed" type="hidden" value="<%if reviewcheck="1" then%>1<%else%>0<%end if%>">
<input type="submit" value="发表评论" name="Submit3" OnClick="document.AddReview.content.value = frames.message.document.body.innerHTML;">
<input name="reset2" type=reset value="重新填写">
<input type="hidden" name="content" value="">
<input type="hidden" name="title" value="评论：<%=title%>">
<%end if%>
</form>

</div>
</div>
<%end if%>
<!--评论部分结束-->

</DIV>
<!--正文部分结束-->
</div>

<!--左边部分结束-->

<!--右边部分开始-->
<div class="EC_Cnt_Right float_right">
<div class="EC_n_right lianmu_bg">
<H3>热门文章</H3>
<DIV>
<ul class="list">
<%
set Rs_hot=server.CreateObject("ADODB.RecordSet")
if uselevel=1 then
if Request.cookies(echsys)("key")="super" or Request.cookies(echsys)("key")="typemaster" or Request.cookies(echsys)("key")="bigmaster" or Request.cookies(echsys)("key")="smallmaster" or Request.cookies(echsys)("key")="check" then
Rs_hot.Source="select top "&top_txt&" * from "& db_wygkcn_Article_Table &" where  Checked=1 and E_typeid="&E_typeid&" order by click DESC,EC_ArticleID desc"
end if
if Request.cookies(echsys)("key")="" then
Rs_hot.Source="select top "&top_txt&" * from "& db_wygkcn_Article_Table &" where (Checked=1 and newslevel=0 and E_typeid="&E_typeid&" ) order by click DESC,EC_ArticleID desc"
end if
if Request.cookies(echsys)("key")="selfreg" then
	if Request.cookies(echsys)("reglevel")=3 then
Rs_hot.Source="select top "&top_txt&" * from "& db_wygkcn_Article_Table &" where (Checked=1 and E_typeid="&E_typeid&" ) order by click DESC,EC_ArticleID desc"
	end if
	if Request.cookies(echsys)("reglevel")=2 then
Rs_hot.Source="select top "&top_txt&" * from "& db_wygkcn_Article_Table &" where (Checked=1 and E_typeid="&E_typeid&" ) order by click DESC,EC_ArticleID desc"
	end if
	if Request.cookies(echsys)("reglevel")=1 then
Rs_hot.Source="select top "&top_txt&" * from "& db_wygkcn_Article_Table &" where (Checked=1 and E_typeid="&E_typeid&" ) order by click DESC,EC_ArticleID desc"
	end if
end if
else
Rs_hot.Source="select top "&top_txt&" * from "& db_wygkcn_Article_Table &" where  Checked=1 and E_typeid="&E_typeid&" order by click DESC,EC_ArticleID desc"
end if
Rs_hot.Open Rs_hot.Source,conn,1,1
Do While Not Rs_hot.Eof
		newsurl="wygkcn_ShowArticle.asp?EC_ArticleID=" & rs_hot("EC_ArticleID")
		newswwwurl=rs_hot("titleface")
		fileExt=lcase(getFileExtName(rs_hot("picname")))
%>
<li><span class="float_right">[<%=rs_hot("click")%>]</span>·<a href="<%if rs_hot("titleface")="无" then %><%=newsurl%><% else %> <%=newswwwurl%><%end if%>" title="<%=htmlencode4(rs_hot("title"))%>" target="_blank"> <font color="<%=rs_hot("titlecolor")%>"> <%=CutStr(htmlencode4(rs_hot("title")),40)%> </font> </a></li>
<%
Rs_hot.Movenext
Loop
Rs_hot.Close
Set Rs_hot=Nothing	
%>	
</ul>
</div>
</div>

<div class="EC_npic_right lianmu_bg">
<H3>最新图文</H3>
<ul>
<%
set rs3=server.CreateObject("ADODB.RecordSet")
if uselevel=1 then
	if Request.cookies(echsys)("key")="super" or Request.cookies(echsys)("key")="typemaster" or Request.cookies(echsys)("key")="bigmaster" or Request.cookies(echsys)("key")="smallmaster" or Request.cookies(echsys)("key")="check" then
	rs3.Source ="select top 2 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1 and goodnews=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("key")="" then
	rs3.Source ="select top 2 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and goodnews=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("key")="selfreg" then
if Request.cookies(echsys)("reglevel")=3 then
	rs3.Source ="select top 2 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and goodnews=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("reglevel")=2 then
	rs3.Source ="select top 2 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and goodnews=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("reglevel")=1 then
	rs3.Source ="select top 2 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and goodnews=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
end if
else
	rs3.Source ="select top 2 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1 and goodnews=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
end if

rs3.Open rs3.Source,conn,1,1
if not rs3.EOF then
while not rs3.EOF
fileExt=lcase(getFileExtName(rs3("picname")))
Content=htmlencode4(rs3("Content"))

%>
<li>
<DIV class="npic" onMouseOver="this.className='npic npic_Hover'" onMouseOut="this.className='npic'">
<a class=middle href="wygkcn_ShowArticle.asp?EC_ArticleID=<%=rs3("EC_ArticleID")%>" target=_blank title="<%=htmlencode4(rs3("title"))%>">
                          <%if fileext="jpg" or fileext="bmp" or fileext="png" or fileext="gif" then%>
                          <img  src="<%=FileUploadPath & rs3("picname")%>" width="120" height="100" border=0 align="center">
                          <%end if%>
                          <%if fileext="swf" then%>
                          <object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000'  codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0' width="120" height="100" border=0 align="center">
                            <param name=movie value="<%=FileUploadPath & rs3("picname")%>">
                            <param name=quality value=high>
                            <param name='Play' value='-1'>
                            <param name='Loop' value='0'>
                            <param name='Menu' value='-1'>
                            <embed src="<%=FileUploadPath & rs3("picname")%>" width="120" height="100" border=0 align="center" pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash'></embed>
                        </object>
                          <%end if%>
                        </a> 
</div>
<div class="npic_title">
<a href="wygkcn_ShowArticle.asp?EC_ArticleID=<%=rs3("EC_ArticleID")%>" target=_blank title="<%=htmlencode4(rs3("title"))%>"><%=CutStr(htmlencode4(rs3("title")),18)%></a>

</div>

</li>
<%   
rs3.MoveNext
wend
else
Response.Write "<li>暂无</li>"
end if
%>
</ul>
<div class="EC_ntext_right">
<ul class="list">
<%
set rs3=server.CreateObject("ADODB.RecordSet")
if uselevel=1 then
	if Request.cookies(echsys)("key")="super" or Request.cookies(echsys)("key")="typemaster" or Request.cookies(echsys)("key")="bigmaster" or Request.cookies(echsys)("key")="smallmaster" or Request.cookies(echsys)("key")="check" then
	rs3.Source ="select top 10 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("key")="" then
	rs3.Source ="select top 10 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("key")="selfreg" then
if Request.cookies(echsys)("reglevel")=3 then
	rs3.Source ="select top 10 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("reglevel")=2 then
	rs3.Source ="select top 10 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
	if Request.cookies(echsys)("reglevel")=1 then
	rs3.Source ="select top 10 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1  and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
	end if
end if
else
	rs3.Source ="select top 10 * from "& db_wygkcn_Article_Table &" where picnews=1 and Checked=1 and E_typeid="&E_typeid&" and picname is not null order by EC_ArticleID DESC"
end if

rs3.Open rs3.Source,conn,1,1
if not rs3.EOF then
while not rs3.EOF
fileExt=lcase(getFileExtName(rs3("picname")))
Content=htmlencode4(rs3("Content"))
		newsurl="wygkcn_ShowArticle.asp?EC_ArticleID=" & rs3("EC_ArticleID")
		newswwwurl=rs3("titleface")
		fileExt=lcase(getFileExtName(rs3("picname")))

%>
<li>·<a href="<%if rs3("titleface")="无" then %><%=newsurl%><% else %> <%=newswwwurl%><%end if%>" title="<%=htmlencode4(rs3("title"))%>" target="_blank"> <font color="<%=rs3("titlecolor")%>"> <%=CutStr(htmlencode4(rs3("title")),48)%> </font> </a></li>
<%   
rs3.MoveNext
wend
else
Response.Write "<li>暂无</li>"
end if
rs3.close
set rs3=nothing
%>
</ul></div>
</div>


</div>
<!--右边部分结束-->
<div class=clear_float></div>
</div>
<!--中间内容部分结束-->
<!--#include file="bottom.asp"-->
<%
End if
Conn.Close
Set Conn=Nothing
%> 
</div>
<!--内容部分结束-->
</body>
</html>