<%@ Register Assembly="Xiaoxiao.WebUI" Namespace="Xiaoxiao.WebUI" TagPrefix="cc1" %>
<%@ Control Language="C#" %>
<%@ Import Namespace="Spaces" %>
<style>
.bvError{margin:0 0 8 0;}
.bvSection{border-style:none;margin-left:0px}
.bvwordwrap{width:100%}
</style>
<cc1:Form runat="server" id="topicForm" onsubmit="return check()">
    <table class="bvwordwrap" border="0" width="100%" height="247">
        <tr>
            <td valign="top" class="cellstyle">
                <div id="_ctl3_ModuleHeader_MainPanel">
                    <table cellspacing="0" class="pheader" border="0" style="width: 100%;" height="22">
                        <tr>
                            <td class="mod_tlc" width="6" nowrap>
                                &nbsp;
                            </td>
                            <td width="100%" class="modhead">
                                <table cellspacing="0" width="100%" class="fixedTable partheader" style="width: 100%;">
                                    <tr>
                                        <td id="" class="bold ellipse partDetail" nowrap>
                                            <div class='ellipse'>
                                                <%=Globals.Text["viewPost_Daily"]%>
                                            </div>
                                        </td>
                                        <td class="partBuffer" align="right" nowrap>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                            <td class="mod_trc" width="6" nowrap>
                                &nbsp;
                            </td>
                        </tr>
                    </table>
                    <table cellspacing="0" style="width: 100%;" height="22">
                        <tr>
                            <td class='subnav'>
                                <table cellspacing="0" border="0" width='100%'>
                                    <tr>
                                        <td>
                                            <table class='nav' style="display: none">
                                                <tr>
                                                    <td valign="middle">
                                                        <img src="<%=Globals.GetSkinPath() %>/images/arrow_prev.gif" alt="" height="12px"
                                                            border="0" width="7px"></td>
                                                    <td nowrap valign="middle">
                                                        <a title="">上一项: </a>
                                                    </td>
                                                    <td nowrap style="width: 100%" valign="middle" align="right">
                                                        <a title="">下一项: </a>&nbsp;
                                                    </td>
                                                    <td valign="middle">
                                                        <img src="<%=Globals.GetSkinPath() %>/images/arrow_next.gif" alt="" border="0" height="12px"
                                                            width="7px"></td>
                                                </tr>
                                            </table>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                </div>
                <table cellspacing="0" border="0" class="partsmb">
                    <tr>
                        <td>
                            <img src="<%=Globals.GetSkinPath() %>/images/c.gif" width="8" height="1"></td>
                        <td>
                            <span id="_ctl3_lblPermalink">
                                <table cellspacing="0" border="0" width='100%' class='fixedTable blogpost'>
                                    <tr>
                                        <td class='bvh8'>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td valign="top">
                                            <span class='bold'>
                                                <asp:Literal runat="server" ID="Posted" /></span></td>
                                    </tr>
                                    <tr>
                                        <td height="4">
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class='dateline'>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td height="4">
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class='ellipse'>
                                            <span class='bvTitle'>
                                                <asp:HyperLink CssClass="singleposttitle" runat="server" ID="TitleUrl" /></span></td>
                                    </tr>
                                    <tr>
                                        <td class='bvh8'>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <asp:Literal ID="Body" runat="server" />
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <table cellspacing="0" border="0">
                                            </table>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class='bvh8'>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td width="100%">
                                            <table class="bvCommentLinks" cellspacing="0">
                                                <tr>
                                                    <td valign="top">
                                                        <nobr>
                                                            <asp:PlaceHolder ID="phTags" runat="server"></asp:PlaceHolder>
                                                        </nobr>
                                                    </td>
                                                </tr>
                                            </table>
                                            <table cellspacing="0">
                                                <tr>
                                                    <td valign="top" nowrap>
                                                    </td>
                                                    <td valign="top">
                                                        <span class='blogSectionLinkSep'></span>
                                                    </td>
                                                    <td valign="top">
                                                        <nobr>
                                                            <asp:Literal ID="PostDescription" runat="server" />
                                                        </nobr>
                                                    </td>
                                                </tr>
                                            </table>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td height="16">
                                        </td>
                                    </tr>
                                </table>
                                <table cellspacing="0" border="0" width="100%" id='MainTbl'>
                                    <tr>
                                        <td>
                                            <div class='bvSection'>
                                                <table cellspacing="0" width="100%" class='bvSectionTitle' style="display: none">
                                                    <tr height="20">
                                                        <td class='bold' nowrap>
                                                            <asp:Literal ID="PingBack" runat="server" />
                                                            <asp:Literal ID="TrackBack" runat="server" /></td>
                                                    </tr>
                                                </table>
                                                <div id='divTrackback' class='bvSection' runat="server">
                                                    <table cellspacing="0" width="100%" class='bvSectionTitle'>
                                                        <tr height="20">
                                                            <td class='bold' nowrap>
                                                                <%=Globals.Text["viewPost_TrackBack"]%>
                                                            </td>
                                                        </tr>
                                                    </table>
                                                    <table class='bvSectionContent' cellspacing="0" width="100%">
                                                        <tr style="display: none">
                                                            <td class='bvh8'>
                                                            </td>
                                                        </tr>
                                                        <tr>
                                                            <td>
                                                                <%=Globals.Text["viewPost_NoticeURL"]%>
                                                                <asp:Literal ID="TrackbackURL" runat="server"></asp:Literal>
                                                            </td>
                                                        </tr>
                                                    </table>
                                                </div>
                                                <table class='bvSectionContent fixedTable' cellspacing="0" style="display: none">
                                                    <tr>
                                                        <td class='bvh8'>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td class='bvwordwrap'>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td class='bvh8'>
                                                        </td>
                                                    </tr>
                                                </table>
                                            </div>
                                            <div class='bvSection' id="divComment" runat="server">
                                                <table cellspacing="0" width="100%" class='bvSectionTitle'>
                                                    <tr height="20">
                                                        <td class='bold' nowrap>
                                                            <%=Globals.Text["viewPost_Comments"]%>
                                                        </td>
                                                        <td width="100%">
                                                        </td>
                                                        <td nowrap>
                                                            <span style='padding: 0'>
                                                                <cc1:AspNetPager ID="CommentPager" runat="server" AlwaysShow="True" UrlPaging="True"
                                                                    CustomInfoSectionWidth="100%">
                                                                </cc1:AspNetPager>
                                                            </span>
                                                        </td>
                                                    </tr>
                                                </table>
                                                <asp:Repeater ID="CommentList" runat="server">
                                                    <ItemTemplate>
                                                        <table cellspacing="0" class='bvSectionContent fixedTable' width="100%">
                                                            <tr>
                                                                <td class='bvh8'>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td>
                                                                    <table style="margin: 0px" cellspacing='0' cellpadding='0' align='left'>
                                                                        <tr>
                                                                            <td>
                                                                                <span class='bvTitle'>
                                                                                    <asp:Literal runat="server" ID="Title" /></span>
                                                                            </td>
                                                                        </tr>
                                                                        <tr>
                                                                            <td class='bvwordwrap'>
                                                                                <table width="100%">
                                                                                    <tr>
                                                                                        <td>
                                                                                            <asp:Image ID="imgAvatar" runat="server" Height="120px" Width="120px" Visible="false" />
                                                                                        </td>
                                                                                        <td>
                                                                                            <asp:Literal ID="PostText" runat="server" /></td>
                                                                                    </tr>
                                                                                </table>
                                                                            </td>
                                                                        </tr>
                                                                    </table>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td height="8">
                                                                </td>
                                                            </tr>
                                                            <tr class='commententry'>
                                                                <td>
                                                                    <span class='notgray'>
                                                                        <%=Globals.Text["viewPost_Author"]%>
                                                                    </span><span class='bold mstitlewrap'>
                                                                        <asp:HyperLink Target="_blank" runat="server" ID="NameLink" />
                                                                    </span><span class='notgray'>&nbsp;-&nbsp;
                                                                        <asp:LinkButton runat="server" ID="EditLink" CausesValidation="False" /></span>
                                                                    <asp:Literal ID="PostDate" runat="server" />
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class='bvh8' width="100%">
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td>
                                                                </td>
                                                            </tr>
                                                        </table>
                                                    </ItemTemplate>
                                                    <SeparatorTemplate>
                                                        <table cellspacing="0" width="100%">
                                                            <tr>
                                                                <td class='line' width="100%">
                                                                </td>
                                                            </tr>
                                                        </table>
                                                    </SeparatorTemplate>
                                                </asp:Repeater>
                                            </div>
                                            <div id="divCommentform" class="commentform" runat="server">
                                                <table cellspacing="0" width="100%" class='bvSectionTitle' border="0">
                                                    <tr height="20">
                                                        <td width="100%" nowrap>
                                                            <span class='bold'>
                                                                <%=Globals.Text["viewPost_SubmitComments"]%>
                                                            </span>
                                                        </td>
                                                    </tr>
                                                </table>
                                                <table>
                                                    <tr>
                                                        <td height="3">
                                                        </td>
                                                    </tr>
                                                </table>
                                                <table width="100%">
                                                <tr>
                                                <td valign="top" width="460px">
                                                <table width="100%" cellspacing="0" class='bvSectionContentPC'>
                                                    <tr>
                                                        <td>
                                                            <table cellpadding="0" cellspacing="0" style="display: none">
                                                                <tr>
                                                                    <td>
                                                                        <span height='52px' width='62px' class='ccui' id="asd"></span>
                                                                    </td>
                                                                    <td width='100%'>
                                                                        <div>
                                                                            <input type='checkbox' value='true' id='txtShowContactControl' name='txtShowContactControl'
                                                                                onclick="" checked>
                                                                            登录发表</div>
                                                                    </td>
                                                                </tr>
                                                            </table>
                                                        </td>
                                                       
                                                    </tr>
                                                    <tr>
                                                        <td height="4">
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td id='Err' class='Err' style='width: 450px; padding: 0 3 0 3; margin: 0;'>
                                                            <div class='bvError' style="display: none" id="errMsg" runat="server">
                                                            </div>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <div style="padding: 2px">
                                                                <% =Globals.Text["viewPost_Name"]%>
                                                                <br />
                                                                <asp:TextBox ID="tbName" runat="server" Size="40" Width="450px" MaxLength="24"></asp:TextBox>
                                                            </div>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <div style="padding: 2px" id="divPassword" runat="server">
                                                                密码:(游客无须)<br />
                                                                <asp:TextBox ID="tbPassword" runat="server" TextMode="Password" Width="450px" MaxLength="24"></asp:TextBox>
                                                            </div>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <div style="padding: 2px">
                                                                <%=Globals.Text["viewPost_DailyURL"]%>
                                                                <br />
                                                                <asp:TextBox ID="tbUrl" runat="server" Size="1024" Width="450px"></asp:TextBox>
                                                            </div>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <div style="padding: 2px">
                                                                <%=Globals.Text["viewPost_Title"]%>
                                                                <br />
                                                                <asp:TextBox ID="tbTitle" runat="server" Size="40" Width="450px" MaxLength="200"></asp:TextBox>
                                                            </div>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <div style="padding: 2px" class='COMMENTENTRY'>
                                                                <%=Globals.Text["viewPost_Comments"]%>
                                                                <br />
 
                                                                <asp:TextBox ID="tbComment" runat="server" Columns="45" Width="450px" CssClass="rtecomment" TextMode="MultiLine"
                                                                    Rows="15"></asp:TextBox>
          
                                                            </div>
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <div runat="server" id="divVC">
                                                                <%=Globals.Text["code"]%><br />
                                                                <asp:TextBox ID="tbVC" runat="server" MaxLength="10" Width="100px"></asp:TextBox>
                                                                <img id="chk_img" onclick="checkwd_reload()" style="cursor: hand" align="absbottom" />
                                                                <span onclick="checkwd_reload()" style="cursor: hand">&nbsp;<%=Globals.Text["change"]%></span>
                                                                <asp:Button ID="btnSubmit" runat="server" Text="发布评论" OnClientClick="return chkTopicComment();">
                                                                </asp:Button></div>

                                                            <script>
        function ctlent(){
if(event.ctrlKey && window.event.keyCode==13)
{
$('<%=btnSubmit.ClientID %>').click();
}
}
function check(){
if ($('<%=btnSubmit.ClientID %>').checked)
{alert("回复正在提交到服务器，请耐心等待，无需重复提交");
return false}
else{
$('<%=btnSubmit.ClientID %>').checked = true;
return true;
}}
                                        function checkwd_reload(){
		
       		var ob = document.getElementById("chk_img");
		  if(ob)
		ob.src = '<%=string.Format("{0}/Include/RndImg.aspx?ImgHeight=25&imgWidth=150&FontSize=18&", Globals.ApplicationPath)%>' + new Date();
                }
                checkwd_reload();
                window.document.onkeydown=ctlent;
                                                            </script>

                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <table width="100%" cellspacing="0" class='bvPostCommentBtn' border="0">
                                                                <tr>
                                                                    <td>
                                                                        <br />
                                                                    </td>
                                                                    <td width="100%">
                                                                        &nbsp;&nbsp;
                                                                        <div style="display: none">
                                                                            &nbsp;&nbsp;<asp:CheckBox ID="chkRemember" runat="server" Text="记住我?" TabIndex="-1">
                                                                            </asp:CheckBox><asp:HyperLink ID="lnkLogin" runat="server">登录</asp:HyperLink>&nbsp;&nbsp;<asp:HyperLink
                                                                                ID="linkLoginComment" runat="server">使用高级评论</asp:HyperLink>&nbsp;&nbsp;</div>
                                                                    </td>
                                                                </tr>
                                                            </table>

                                                            <script>
                                       
                                        function setMsg(s)
                                        {
                                        var msg=$('<%=errMsg.ClientID %>'); 
                                        msg.innerHTML='';
                                        msg.style.display='';
                                       msg.style.padding='4px';
                                        msg.innerHTML='提示消息:<br />';
                                        msg.innerHTML+=s;
                                        }
                                        function chkTopicComment()
                                        {
                                        
                                       
                                     
                                         var name=$('<%=tbName.ClientID %>');
                                         var title=$('<%=tbTitle.ClientID %>');
                                          var comment=$('<%=tbComment.ClientID %>');
                                          if(name.value.trim()=='')
                                          {
                                          ///_error_msg_show('您忘记输入评论内容了！');
                                         // alert('您忘记输入评论内容了！');
                                         setMsg('<% =Globals.Text["Topic_noname"]%>');
                                          return false;
                                          }
                                          if(title.value.trim()=='')
                                          {
                                          // _error_msg_show('您忘记输入评论标题了！');
                                           //alert('您忘记输入评论标题了！');
                                           setMsg('<% =Globals.Text["Topic_nolemma"]%>');
                                          return false;
                                          }
                                          	//var oEditor = FCKeditorAPI.GetInstance('<%=tbComment.ClientID %>') ;
	 var bbody=$('<%=tbComment.ClientID %>').value;                                         //oEditor.EditorDocument.body.innerHTML ;
                                           if(bbody.trim()=='')
                                          {
                                            setMsg('<% =Globals.Text["Topic_nogut"]%>');
                                          return false;
                                          }
                                          return true;
                                        }
                                                            </script>

                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td class='bvh8'>
                                                        </td>
                                                    </tr>
                                                </table>
                                               </td> 
                                               <td align="center" valign="top"  width="230px" >
                                                <div align="center">
				<div  >
					<script language="JavaScript" type="text/javascript">
			
			function AddText(NewCode) {
			 var comment=$('<%=tbComment.ClientID %>');
        if(document.all){
        	insertAtCaret(comment, NewCode);
         
        } else{
        	comment.value += NewCode;
       
        }
        comment.focus();
}
 
function storeCaret (textEl){
        if(textEl.createTextRange){
                textEl.caretPos = document.selection.createRange().duplicate();
        }
}

function insertAtCaret (textEl, text){
        if (textEl.createTextRange && textEl.caretPos){
                var caretPos = textEl.caretPos;
                caretPos.text += caretPos.text.charAt(caretPos.text.length - 2) == ' ' ? text + ' ' : text;
        } else if(textEl) {
                textEl.value += text;
        } else {
        	textEl.value = text;
        }
}
			</script>
					<strong><span style="cursor:hand;padding-left:10px;" onclick="showIntro('add_smilies');">添加表情</span></strong><br /><hr />
					</div>
					<div style="display: none1;"  >
					<img style="cursor:hand;" onclick="AddText('[smile]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_smile.gif" /> 
					<img style="cursor:hand;" onclick="AddText('[confused]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_confused.gif" /> 
					<img style="cursor:hand;" onclick="AddText('[cool]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_cool.gif" /> 
					<img style="cursor:hand;" onclick="AddText('[cry]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_cry.gif" /> <br />
					<img style="cursor:hand;" onclick="AddText('[sad]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_sad.gif" /> 
					<img style="cursor:hand;" onclick="AddText('[angry]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_angry.gif" /> 
					<img style="cursor:hand;" onclick="AddText('[shame]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_shame.gif" />
					 <img style="cursor:hand;" onclick="AddText('[sweat]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_sweat.gif" /><br />
					  <img style="cursor:hand;" onclick="AddText('[lol]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_lol.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[question]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_question.gif" />
					  <img style="cursor:hand;" onclick="AddText('[razz]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_razz.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[tong]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_tong.gif" /> <br />
					  <img style="cursor:hand;" onclick="AddText('[lovely]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_lovely.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[music]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_music.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[ft]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_ft.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[heart]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_heart.gif" /> <br />
					  <img style="cursor:hand;" onclick="AddText('[fd]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_fd.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[sleep]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_sleep.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[eek]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_eek.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[belial]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_belial.gif" /> <br />
					  <img style="cursor:hand;" onclick="AddText('[bomb]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_bomb.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[xizao]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_xizao.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[abuse]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_abuse.gif" /> 
					  <img style="cursor:hand;" onclick="AddText('[cattle]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_cattle.gif" /><br />
					   <img style="cursor:hand;" onclick="AddText('[mummy]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_mummy.gif" /> 
					   <img style="cursor:hand;" onclick="AddText('[ghost]');" src="<%=Globals.ApplicationPath %>/images/smilies/icon_ghost.gif" />
				</div>
			</div>
                                               </td>
                                               </tr>
                                                </table>
                                            </div>
                                        </td>
                                    </tr>
                                </table>
                        </td>
                        <td>
                            <img src="<%=Globals.GetSkinPath() %>/images/c.gif" width="8" height="1"></td>
                    </tr>
                    <tr>
                        <td colspan="3" height="8">
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
</cc1:Form>
