<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<%
'请尊重作者版权不要删除以下信息
' 程序作者:业一
'  http://yeyi.cn    
'  http://yeyicn.com
' 业一中国 
'--------------------------------------------------
' 承接各类网站制作和系统开发业务
'---------------------------------------------------
%>
<!--#include file="Connections/conn_news.asp" -->
<!--#include file="yns_config.asp" -->
<!--#include file="yns_chklogin.asp" -->
<% chk_user_login(3) %>
<!--#include file="yns_chkerror.asp" -->
<!--#include file="yns_js_create_news.asp" -->
<!--#include file="yns_js_create_news_pic.asp" -->
<%
Dim rst
Dim rst_numRows

Set rst = Server.CreateObject("ADODB.Recordset")
rst.ActiveConnection = MM_conn_news_STRING
rst.Source = "SELECT *  FROM t_type_son inner join t_type on t_type_son.ts_pid=t_type.t_id  ORDER BY t_id ,ts_id"
rst.CursorType = 0
rst.CursorLocation = 2
rst.LockType = 1
rst.Open()

rst_numRows = 0
%>
<%
Dim rsts
Dim rsts_numRows

Set rsts = Server.CreateObject("ADODB.Recordset")
rsts.ActiveConnection = MM_conn_news_STRING
rsts.Source = "SELECT * FROM t_type_son"
rsts.CursorType = 0
rsts.CursorLocation = 2
rsts.LockType = 1
rsts.Open()

rsts_numRows = 0
%>
<%
Dim Repeat1__numRows
Dim Repeat1__index

Repeat1__numRows = -1
Repeat1__index = 0
rst_numRows = rst_numRows + Repeat1__numRows
%>
<%
Dim Repeat2__numRows
Dim Repeat2__index

Repeat2__numRows = -1
Repeat2__index = 0
rsts_numRows = rsts_numRows + Repeat2__numRows
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<link href="style/css.css" rel="stylesheet" type="text/css">
</head>

<body>

  <table width="94%" border="1" cellpadding="4" cellspacing="0" bordercolor="#CCCCCC" class="table-line">
    <tr> 
      <td bgcolor="#F7F7F7">所有新闻的调用 
        <hr size="1" noshade color="#CCCCCC">
      <table width="94%" border="1" align="center" cellpadding="4" cellspacing="0" bordercolor="#FFCC00" class="table-line">
        <tr bgcolor="#FFEEAC"> 
          <td height="30" colspan="2"><strong>所有新闻</strong> 的调用代码 : </td>
        </tr>
        <tr> 
          <td width="10%" align="right" bgcolor="#FFFFCC"> 所有新闻: </td>
          <td bgcolor="#FFFFCC"><%= mm_create_js("",yns_js_repeat01) %></td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC">专题新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js(" and n_sid <> null ",yns_js_repeat02) %></td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC">推荐新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js(" and n_commend = 1",yns_js_repeat03) %></td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC">图片新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js_pic("") %></td>
        </tr>
        <tr bgcolor="#FFFF33"> 
          <td align="right">菜单调用:</td>
          <td>&lt;script language=&quot;JavaScript&quot; src=&quot;js/news__menu.js&quot; 
            type=&quot;text/JavaScript&quot;&gt;&lt;/script&gt; </td>
        </tr>
      </table>
      <p></p>
    </td>
    </tr>
  </table>
  <p></p>
  <table width="94%" border="1" cellpadding="4" cellspacing="0" bordercolor="#CCCCCC" class="table-line">
    <tr> 
    <% 
dim mm_menu_line 
dim menu_path
dim mm_raa
mm_raa = 0
menu_path = ("js/news__menu.js")
menu_path = server.MapPath(menu_path)
mm_menu_line = "document.write('"
mm_menu_line = mm_menu_line & yns_js_menu_split_icon
%>  
    <td bgcolor="#F7F7F7">大类新闻的调用 
      <hr size="1" noshade color="#CCCCCC">
	  
        <% 
While ((Repeat1__numRows <> 0) AND (NOT rst.EOF)) 
%>
<% if (rst.Fields.Item("t_id").Value) <> mm_raa then %>
<% mm_menu_line = mm_menu_line &" <a href="&chr(34)&yns_js_path&(rst.Fields.Item("t_dir").Value)&"/"&(rst.Fields.Item("ts_dir").Value)&"/list_1.htm"&chr(34)&" class="&chr(34)&yns_list_nav1_class&chr(34)&">"&(rst.Fields.Item("t_name").Value) &"</a> "&yns_js_menu_split_icon%>
      <table width="94%" border="1" align="center" cellpadding="4" cellspacing="0" bordercolor="#FFCC00" class="table-line">
        <tr bgcolor="#FFEEAC"> 
          <td height="30" colspan="2">大类 <strong><%=(rst.Fields.Item("t_name").Value)%></strong> 的调用代码 : </td>
        </tr>
        <tr> 
          <td width="10%" align="right" bgcolor="#FFFFCC">所有新闻: </td>
          <td bgcolor="#FFFFCC"> <%
dim mm_tid
mm_tid = (rst.Fields.Item("t_id").Value)
%> <%= mm_create_js(" and n_tid = "&mm_tid,yns_js_repeat04) %> </td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC">专题新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js(" and n_tid = "&mm_tid&" and n_sid <> null ",yns_js_repeat05) %></td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC"> 推荐新闻: </td>
          <td bgcolor="#FFFFCC"><%= mm_create_js(" and n_tid = "&mm_tid&" and n_commend = 1",yns_js_repeat06) %></td>
        </tr>
        <tr>
          <td align="right" bgcolor="#FFFFCC">图片新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js_pic(" and n_tid = "&mm_tid) %></td>
        </tr>
      </table>
      <p></p>
<% end if %>
<% mm_raa = (rst.Fields.Item("t_id").Value)  %>
      <% 
  Repeat1__index=Repeat1__index+1
  Repeat1__numRows=Repeat1__numRows-1
  rst.MoveNext()
Wend
%>
      </td>
    </tr>
  </table>
  <%
mm_menu_line=mm_menu_line&"')"
set fso = createobject("scripting.filesystemobject")
set fso_create = fso.createtextfile(menu_path,true)
fso_create.Write mm_menu_line
fso_create.close 
%>
  <p></p>
  <table width="94%" border="1" cellpadding="4" cellspacing="0" bordercolor="#CCCCCC" class="table-line">
    <tr> 
      
    <td bgcolor="#F7F7F7">小类新闻的调用 
      <hr size="1" noshade color="#CCCCCC">

        <% 
While ((Repeat2__numRows <> 0) AND (NOT rsts.EOF)) 
%>
      <table width="94%" border="1" align="center" cellpadding="4" cellspacing="0" bordercolor="#FFCC00" class="table-line">
        <tr bgcolor="#FFEEAC"> 
          <td height="30" colspan="2">小类<strong><%=(rsts.Fields.Item("ts_name").Value)%></strong> <strong></strong> 的调用代码 : </td>
        </tr>
        <tr> 
          <td width="10%" align="right" bgcolor="#FFFFCC">所有新闻: </td>
          <td bgcolor="#FFFFCC"> <% 
dim mm_tsid
mm_tsid = (rsts.Fields.Item("ts_id").Value)

%> <%= mm_create_js(" and n_tsid = "&mm_tsid,yns_js_repeat07) %> </td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC">专题新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js(" and n_tsid = "&mm_tsid&" and n_sid <> null ",yns_js_repeat08) %></td>
        </tr>
        <tr> 
          <td align="right" bgcolor="#FFFFCC"> 推荐新闻: </td>
          <td bgcolor="#FFFFCC"><%= mm_create_js(" and n_tsid = "&mm_tsid&" and n_commend = 1",yns_js_repeat09) %></td>
        </tr>
        <tr>
          <td align="right" bgcolor="#FFFFCC">图片新闻:</td>
          <td bgcolor="#FFFFCC"><%= mm_create_js_pic(" and n_tsid = "&mm_tsid) %></td>
        </tr>
      </table>
      <p></p>
      <% 
  Repeat2__index=Repeat2__index+1
  Repeat2__numRows=Repeat2__numRows-1
  rsts.MoveNext()
Wend
%>
      </td>
    </tr>
  </table>

</body>
</html>
<%
rst.Close()
Set rst = Nothing
%>
<%
rsts.Close()
Set rsts = Nothing
%>
