<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Group-m.aspx.cs" Inherits="JuSNS.Web.home.Group.Group_m" %>

<!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="../../template/<% Response.Write(JuSNS.Config.UiConfig.SkinStyle); %>/css/base.css" id="skinpath" type="text/css" rel="stylesheet" />
<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>
 <!--头部-->
<%=this.GetHtmlShort()%> 
<div id="divhead">
    <%=this.GetHtmlHead()%>
</div>

<div id="divbody">
    <div id="body_first">
        <div class="body_menu"> 
        <%=this.GetHtmlLeft()%>
        </div>
    </div>
       <div id="body_sec">
            <div id="body_mid"> 
                <div class="body_frame"> 
                    <div class="body_frame_otherinfo">
	                        <div class="title">
                                <div class="l"><img src="../../template/<%Response.Write(JuSNS.Config.UiConfig.SkinStyle); %>/images/site/group.gif" align="absmiddle" /> <span class="shenlan bold font14 ocolor" id="H2_GroupName" runat="server"></span>(<span id="P_Publicity" runat="server"></span>)</div>
                                <div class="r">
                                    
                                    <input type="text" class="f-text" id="myKey" runat="server" />
                                    <input type="button" class="f-button" value="搜索群组" onclick="self.location='list.aspx?GroupName='+escape(document.getElementById('myKey').value);" />
                                     
                                </div>
                                <div class="c"></div>
                            </div>
            		       
                            <div class="nav-menu">
                                <ul>
                                    <li><a href="../group">最新主题</a></li>
                                    <li><a href="../group/my.aspx?r=<%=ruser %>&a=join">我加入的群组</a></li>
                                    <li><a href="../group/my.aspx?r=<%=ruser %>&a=creat">我创建的群组</a></li>
                                    <li><a href="../group/list.aspx">好友群组</a></li>
                                    <li><a href="../group/list.aspx?r=all">随便看看</a></li>
                                    <li class="current"><a href="javascript:;">讨论区</a></li>
                                </ul>
                            </div>        
                     </div>   
                     
                     <div class="body_sec_all">
                             
                            <div class="content nl s100">
                                    <div class="nl s99"><div class="nl" id="showtitle" >共 <span id="span_DiscussCount" runat="server"></span>个主题</div><div class="group-navi nr"><ul class="acbg1" id="Ul_GroupAdminOp" runat="server"></ul></div></div> 
                                    
                                    <div class="group-content nl">
                                            <div class="content" style="width:740px;"><span class="reshow">公告：</span> <span id="Div_sect" runat="server"></span></div>
                                            <asp:Repeater ID="Rpt_DiscussList" runat="server">
                                                <HeaderTemplate>
                                                <div class="tn nl">
                                                    <div class="title nl">主题</div>
                                                    <div class="author nl">作者</div>
                                                    <div class="replay nl">回复数</div>
                                                    <div class="replier nl">最后发言</div>
                                                </div>
                                                <div class="c"></div>
                                                </HeaderTemplate>
                                                <ItemTemplate>
                                                <div class="tcn nl">
                                                    <div class="title nl">      
                                                            <a href="Topic.aspx?DisID=<%# DataBinder.Eval(Container.DataItem, "ID")%>">
                                                                <%# getIsTop(DataBinder.Eval(Container.DataItem, "TopNum"))%>
                                                                <%# DataBinder.Eval(Container.DataItem, "Topic")%>
                                                            </a>
                                                   </div>
                                                    <div class="author nl">    
                                                            <a href="/user/<%# JuSNS.Common.Public.URLWrite("","r",""+DataBinder.Eval(Container.DataItem, "UserID")+"")%>">
                                                                <%# DataBinder.Eval(Container.DataItem, "UserName")%>
                                                            </a>                                                   
                                                   </div>
                                                   <div class="replay nl">
                                                   <%# DataBinder.Eval(Container.DataItem, "Replys")%>
                                                   </div>
                                                   <div class="replier nl">
                                                        <%# getUserName(DataBinder.Eval(Container.DataItem, "LastPoster"))%>
                                                            <span class="time">
                                                                <%# getTime(DataBinder.Eval(Container.DataItem, "LastPostTime"), DataBinder.Eval(Container.DataItem, "ID"))%>
                                                            </span>                                                   
                                                    </div>
                                                </div>                                           
                                                </ItemTemplate>
                                                <FooterTemplate>
                                                    </div>
                                                </FooterTemplate>
                                            </asp:Repeater>
                                            <div class="pagination" runat="server" id="DivPage"></div>                                    
                                         </div>
                                 <%if(isGroupHead){ %>
                                    <form id="form1" runat="server">
                                     <div class="pstr s99" id="isPost" runat="server">
                                            <a name="posttopic"></a> 
                                            <div class="bold s100 font14 hdtitle">发表话题</div>
                                            <div class="spline"></div>
                                             <div class="msg-error" id="div_Error" runat="server" style="display: none;"></div>
                                            <div class="content">
                                                <label class="f-label">
                                                标题
                                                </label>
                                               <input type="text" class="f-text s50" runat="server" id="Topic" maxlength="40" size="60" /> 
                                            </div>
                                            <div class="content">
                                                <label class="f-label">
                                                内容
                                                </label>
                                                <script type="text/javascript" language="javascript">
                                                    window.onload = function()
                                                    {
                                                        var sBasePath = "../../inc/editor/"
                                                        var oFCKeditor = new FCKeditor('Content') ;
                                                        oFCKeditor.BasePath	= sBasePath ;
                                                        oFCKeditor.Width = '88%' ;
                                                        oFCKeditor.ToolbarSet = 'Basic';
                                                        oFCKeditor.Height = '180' ;	
                                                        oFCKeditor.ReplaceTextarea();
                                                    }
                                                 </script>
                                                <textarea runat="server" rows="10" name="Content" class="f-text" id="Content" style="width: 350px; height: 200px;display:none;"></textarea>
                                            </div>
                                            <div class="content">
                                                <label class="f-label">
                                                &nbsp;
                                                </label>
                                                    <asp:HiddenField ID="Hid_GroupID" runat="server" />
                                                    <asp:Button ID="Button1" runat="server" Text="发表话题"  CssClass="f-button" OnClick="Button1_Click" />
                                            </div>
                                     </div>
                                    </form>
                                    <%}else{ %>
                                    <div class="msg-warn">您需要上传了头像后，才能 <b>发表主题</b>！，现在开始<a href="../space/userheadphoto.aspx">上传头像</a></div>
                                    <%} %>
                                    
                            </div>
                     </div>
                     </div>
                       <!--底部-->
                     <div class="divbottom">
                      <%=this.GetHtmlFoot()%>
                      </div>                         
         </div>
     </div>
</div>
</body>
</html>