?? managenews.aspx
字號(hào):
<%@ Register TagPrefix="uc1" TagName="AdminFooter" Src="../Inc/AdminFooter.ascx" %>
<%@ Page language="c#" Codebehind="ManageNews.aspx.cs" AutoEventWireup="false" Inherits="Zj.Web.Admin.ManageNews" %>
<%@ Register TagPrefix="uc1" TagName="AdminNewsHeader" Src="../Inc/AdminNewsHeader.ascx" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
<HEAD>
<title> <%=WebName%> ·新聞管理</title>
<LINK href="Style/default.css" type="text/css" rel="stylesheet">
</HEAD>
<body topMargin="0">
<form id="NewsManage" method="post" runat="server">
<uc1:adminnewsheader id="AdminNewsHeader1" runat="server" DESIGNTIMEDRAGDROP="83"></uc1:adminnewsheader>
<TABLE id="Table1" cellSpacing="0" cellPadding="0" width="770" align="center" border="0">
<TR>
<TD align="center" colSpan="2"><STRONG> 新聞管理</STRONG></TD>
</TR>
<TR>
<TD align="left" colspan="2">
<asp:dropdownlist id="DropState" runat="server">
<asp:ListItem Value="-1">全部狀態(tài)</asp:ListItem>
<asp:ListItem Value="0">未審核</asp:ListItem>
<asp:ListItem Value="1">已審核</asp:ListItem>
</asp:dropdownlist><asp:dropdownlist id="DropCatName" runat="server"></asp:dropdownlist><asp:textbox id="txtTitle" runat="server" ToolTip="請(qǐng)輸入新聞標(biāo)題關(guān)鍵字"></asp:textbox> <asp:button id="btnSearch" runat="server" Text="查詢新聞"></asp:button>
<asp:button id="btnPass" runat="server" Text="審核通過"></asp:button>
<asp:button id="btnCancel" runat="server" Text="取消通過"></asp:button>
<asp:button id="btnMainNews" runat="server" Text="設(shè)為主頁顯示"></asp:button>
<asp:button id="btnCancelMainNews" runat="server" Text="取消主頁顯示"></asp:button></TD>
</TR>
<TR>
<TD colSpan="2">
<asp:datagrid id="DataGrid1" runat="server" AutoGenerateColumns="False" DataKeyField="News_ID"
Width="100%" AlternatingItemStyle-HorizontalAlign="Center" AllowPaging="True" AllowCustomPaging="True"
AllowSorting="True" PageSize="20">
<AlternatingItemStyle HorizontalAlign="Center"></AlternatingItemStyle>
<ItemStyle HorizontalAlign="Center" BackColor="#F2F3F4"></ItemStyle>
<HeaderStyle HorizontalAlign="Center" CssClass="12bor" BackColor="#C7CBD3"></HeaderStyle>
<Columns>
<asp:TemplateColumn>
<ItemStyle Width="10px"></ItemStyle>
<ItemTemplate>
<input type='CheckBox' name="Chk_ID" value='<%# DataBinder.Eval(Container.DataItem, "News_ID") %>'>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn SortExpression="Cat_ID" HeaderText="新聞?lì)悇e">
<ItemStyle HorizontalAlign="Left"></ItemStyle>
<ItemTemplate>
<asp:Label id="Label1" runat="server" Text='<%# getCatName(Convert.ToInt32(DataBinder.Eval(Container, "DataItem.Cat_ID")))%>'>
</asp:Label>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn SortExpression="News_Title" HeaderText="新聞標(biāo)題">
<ItemStyle HorizontalAlign="Left"></ItemStyle>
<ItemTemplate>
<a href='../../News/NewsDetails.aspx?News_ID=<%# DataBinder.Eval(Container.DataItem, "News_ID") %>' title='<%# DataBinder.Eval(Container.DataItem, "News_Title") %>' target="_blank">
<%# getNewsTitle(Convert.ToString(DataBinder.Eval(Container, "DataItem.News_Title")), Convert.ToByte(DataBinder.Eval(Container, "DataItem.News_IsPicture")), Convert.ToByte(DataBinder.Eval(Container, "DataItem.News_Type")))%>
</a>
</ItemTemplate>
</asp:TemplateColumn>
<asp:BoundColumn DataField="News_Author" SortExpression="News_Author" HeaderText="作者">
<ItemStyle HorizontalAlign="Left"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="News_Hits" SortExpression="News_Hits" HeaderText="點(diǎn)擊數(shù)">
<HeaderStyle HorizontalAlign="Center"></HeaderStyle>
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:BoundColumn>
<asp:TemplateColumn SortExpression="News_State" HeaderText="審核">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
<ItemTemplate>
<asp:Label runat="server" Text='<%# getStateName(Convert.ToBoolean(DataBinder.Eval(Container, "DataItem.News_State")))%>'>
</asp:Label>
</ItemTemplate>
</asp:TemplateColumn>
<asp:BoundColumn DataField="News_Date" SortExpression="News_Date" HeaderText="發(fā)布時(shí)間" DataFormatString="{0:yyyy-MM-dd}">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:BoundColumn>
<asp:HyperLinkColumn Target="_self" DataNavigateUrlField="News_ID" DataNavigateUrlFormatString="EditNews.aspx?News_ID={0}" DataTextField="News_ID" DataTextFormatString="<img border=0 Alt='修改新聞' src='Images/edit.gif'><font color='blue'>修改</font>">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:HyperLinkColumn>
<asp:ButtonColumn Text="<img border=0 Alt='刪除新聞' src='Images/del.gif'><font color='blue'>刪除</font>" CommandName="delete">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:ButtonColumn>
<asp:HyperLinkColumn Target="_blank" DataNavigateUrlField="News_ID" DataNavigateUrlFormatString="../../News/NewsDetails.aspx?News_ID={0}" DataTextField="News_ID" HeaderText="查看" DataTextFormatString="<img border=0 Alt='瀏覽新聞' src='Images/view.gif'><font color='blue'>查看</font>">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:HyperLinkColumn>
</Columns>
<PagerStyle Visible="False"></PagerStyle>
</asp:datagrid></TD>
</TR>
<TR>
<TD align="center" colSpan="2">
<TABLE cellSpacing="0" cellPadding="0" width="100%" align="center" border="0">
<TR bgColor="#efefef">
<TD vAlign="top" align="center" colSpan="2">頁次:
<asp:label id="lblCurr" runat="server" ForeColor="Red"></asp:label><FONT color="red">/</FONT>
<asp:label id="lblTotal" runat="server" ForeColor="Red"></asp:label> 每頁:
<asp:label id="lblPageCount" ForeColor="Red" Runat="server"></asp:label>條記錄 共有
<asp:label id="lblAllNum" runat="server" ForeColor="Red"></asp:label>條記錄
<asp:linkbutton id="btnFirst" onclick="PagerButtonClick" runat="server" Text="第一頁" CommandArgument="0">首頁</asp:linkbutton>
<asp:linkbutton id="btnPrev" onclick="PagerButtonClick" runat="server" CommandArgument="prev">前頁</asp:linkbutton>
<asp:linkbutton id="btnNext" onclick="PagerButtonClick" runat="server" CommandArgument="next">后頁</asp:linkbutton>
<asp:linkbutton id="btnLast" onclick="PagerButtonClick" runat="server" CommandArgument="last">末頁</asp:linkbutton>
跳轉(zhuǎn)到第
<asp:textbox id="txtCuur" runat="server" Text="1" Width="30px" MaxLength="3">1</asp:textbox>頁
<asp:button id="Jump" onclick="JumpGo" runat="server" Text="go"></asp:button></TD>
</TR>
</TABLE>
</TD>
</TR>
<TR>
<TD align="center" colSpan="2">
<asp:label id="lblMsg" runat="server" ForeColor="Red" Font-Bold="True" EnableViewState="False"></asp:label></TD>
</TR>
</TABLE>
<table height="6" cellSpacing="0" cellPadding="0" width="770" align="center" border="0">
<tr>
<td bgColor="#8d0294" height="3"></td>
</tr>
</table>
<table height="20" cellSpacing="0" cellPadding="0" width="770" align="center" border="0">
<tr bgColor="#e7e7e7">
<td align="center" width="894"><FONT face="宋體">
<uc1:AdminFooter id="AdminFooter1" runat="server"></uc1:AdminFooter></FONT></td>
</tr>
</table></FONT></form>
</body>
</HTML>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -