<%@ Page Language="C#" AutoEventWireup="true" Codebehind="add.aspx.cs" Inherits="JuSNS.Web.system.news.add" %>

<!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">
<head>
    <title id="ptitle" runat="server">增加新闻</title>
    <link href="../images/css/style.css" rel="stylesheet" type="text/css" />

    <script language="javascript" type="text/javascript" src="../../js/ajax.js"></script>

    <script language="javascript" type="text/javascript" src="../../js/public.js"></script>

    <script type="text/javascript" src="../../inc/editor/fckeditor.js"></script>

</head>
<body>
    <table width="99%" border="0" align="center" cellpadding="5" cellspacing="1">
        <tr>
            <td width="120" align="center" valign="top">
                <div class="menu">
                    <ul>
                        <%=this.GetSystemMenu(sort)%>
                    </ul>
                </div>
            </td>
            <td valign="top">
                <div class="navip">
                    <span class="Blue"><a href="index.aspx">新闻管理</a> <a href="add.aspx">增加新闻</a> <a href="class.aspx">
                        分类管理</a></span>
                </div>
               <div style="height:12px;"></div> 
                <form id="form1" runat="server">
                    <table width="100%" border="0" cellpadding="3" cellspacing="1" class="maintable">
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                标题</td>
                            <td>
                                <asp:TextBox ID="TxtTitle" runat="server" Width="300px"></asp:TextBox>
                            <asp:RequiredFieldValidator
                                ID="RequireName" runat="server" ControlToValidate="TxtTitle" Display="Dynamic"
                                ErrorMessage="此项不能为空"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                分类</td>
                            <td>
                                <asp:DropDownList ID="TxtClassID" runat="server">
                                </asp:DropDownList>
                            </td>
                        </tr>
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                内容</td>
                            <td>
                                    <script type="text/javascript" language="javascript">
                                    window.onload = function()
                                    {
                                        var sBasePath = "../../inc/editor/"
                                        var oFCKeditor = new FCKeditor('TxtContent') ;
                                        oFCKeditor.BasePath	= sBasePath ;
                                        oFCKeditor.Width = '88%' ;
                                        oFCKeditor.ToolbarSet = 'Default';
                                        oFCKeditor.Height = '350' ;	
                                        oFCKeditor.ReplaceTextarea();
                                    }
                                 </script>
                                <textarea runat="server" rows="10" name="TxtContent" class="f-text" id="TxtContent" style="width: 350px; height: 200px;display:none;"></textarea>
                            </td>
                        </tr>
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                相关图片</td>
                            <td>
                               <asp:FileUpload  ID="supfile" runat="Server" /> (支持JPG、GIF 、JPEG,BMP和 PNG 格式的照片，每张最大 5M。)
                            </td>
                        </tr>      
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                类型</td>
                            <td>
                                <asp:CheckBox ID="TxtIsSys" Text="系统公告" runat="server" /> 
                            </td>
                        </tr>
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                状态</td>
                            <td>
                                <asp:CheckBox ID="TxtisLock" Text="锁定" runat="server" />
                            </td>
                        </tr>
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                点击</td>
                            <td>
                                <asp:TextBox ID="TxtClick" runat="server" Text="0" Width="300px"></asp:TextBox>
                            <asp:RequiredFieldValidator
                                ID="RequiredFieldValidator1" runat="server" ControlToValidate="TxtClick" Display="Dynamic"
                                ErrorMessage="此项不能为空"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                                时间</td>
                            <td>
                                <asp:TextBox ID="TxtCreatTime" runat="server" Width="300px"></asp:TextBox>
                            <asp:RequiredFieldValidator
                                ID="RequiredFieldValidator2" runat="server" ControlToValidate="TxtCreatTime" Display="Dynamic"
                                ErrorMessage="此项不能为空"></asp:RequiredFieldValidator>
                            </td>
                        </tr>                        
                        <tr class="maintablelist">
                            <td align="right" style="width: 15%;">
                            </td>
                            <td>
                                <asp:Button ID="Button1" runat="server" Text="确定" OnClick="Button1_Click" />
                                <asp:HiddenField ID="NewsID" Value="0" runat="server" />
                                <asp:HiddenField ID="TxtUserID" Value="0" runat="server" />
                                <asp:HiddenField ID="uppic" Value="" runat="server" />
                            </td>
                        </tr>
                    </table>
                </form>
            </td>
        </tr>
    </table>
</body>
</html>
