<%@ page language="C#" autoeventwireup="true" inherits="Knowledge_KnowledgeInfo, App_Web_tnkwl-px" stylesheettheme="Themes" theme="Themes" %>

<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
<!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 runat="server">
    <title></title>
    <style type="text/css">
        .commentContent
        {
            text-indent: 1em;
            line-height: 25px;
            padding-left: 20px;
            padding-right: 50px;
            color: #000;
        }
        .hlkReply
        {
            cursor: pointer;
            text-decoration: underline;
        }
        .content
        {
            font-size: 12px;
            line-height: 22px;
            overflow: hidden;
        }
    </style>

    <script type="text/javascript">
        function perform() {
            if (window.event.keyCode == 13) {
                var obj = document.activeElement;

                document.getElementById("btnSubmit").focus();
            }
        }
        //document.onkeydown = perform 
    </script>

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

    <script type="text/javascript" src="../js/jquery.pngFix.pack.js"></script>

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

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

</head>
<body>
    <form id="form1" runat="server">
    <table cellpadding="0" cellspacing="0" class="table_box">
        <tr>
            <td class="right_bg">
                <span class="right_title">
                    <img src="../Images/homen.gif" class="img_style" />
                    您的当前位置：个人知识信息 </span>&nbsp;
            </td>
        </tr>
        <tr>
            <td align="center">
                <table width="100%" border="0" cellspacing="0" cellpadding="0" class="tablebg">
                    <tr>
                        <td width="99%" align="center" valign="top">
                            <div class="box">
                                <table cellpadding="3" cellspacing="0" border="0" style="border: solid 1px #CAE0EA;
                                    text-align: left;" width="100%">
                                    <tr>
                                        <td class="detailtitle">
                                            <asp:Label ID="lblTitle" runat="server" Text=""></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="center" style="background-color:#F3F9FD; padding:5px 0px;">
                                            <span>所属分类：</span><asp:Label ID="lblSortName" runat="server" Text="" ForeColor="#666666"></asp:Label>&nbsp;|
                                            <span>作者：</span><%--<asp:Label ID="lblAuthor" runat="server" Text="" ForeColor="#666666"></asp:Label>--%>
                                            <asp:HyperLink ID="hlkUserName" runat="server"></asp:HyperLink>&nbsp;| <span>发布时间：</span><asp:Label
                                                ID="lblPublishTime" runat="server" Text="" ForeColor="#666666"></asp:Label>
                                            <span>点击量：</span><asp:Label ID="lblClickRate" runat="server" Text="" ForeColor="#666666"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr style="">
                                        <td valign="top" style="padding: 10px; text-indent: 1em; border-bottom: 1px dotted #DCDCDC;
                                            background-color: White; word-wrap: break-word; word-break: break-all;">
                                            <asp:Label ID="lblContent" runat="server" Text="" Width="90%" CssClass="content"></asp:Label><br />
                                            <br />
                                            <br />
                                            <asp:Panel ID="panelAttachmentList" runat="server">
                                                <table>
                                                    <tr>
                                                        <td>
                                                            附件名称
                                                        </td>
                                                        <td>
                                                            附件大小
                                                        </td>
                                                    </tr>
                                                    <asp:Repeater ID="rptAttachmentList" runat="server">
                                                        <ItemTemplate>
                                                            <tr>
                                                                <td>
                                                                    <a href='<%#Eval("Address") %>'>
                                                                        <%#Eval("Name") %></a>
                                                                </td>
                                                                <td>
                                                                    <%#Eval("Size")%>
                                                                </td>
                                                            </tr>
                                                        </ItemTemplate>
                                                    </asp:Repeater>
                                                </table>
                                            </asp:Panel>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="font-size: 14px; font-weight: bold; padding-left: 10px; line-height: 35px;" align="center">
                                            <%--<input id="Button2" class="BigButton" type="button" value="返回" 
                        onclick="history.go(-1)" />--%>
                                            <asp:Button ID="btnReturn" runat="server" Text="返回" OnClick="btnReturn_Click" Visible="false" />
                                            <asp:Button ID="btnTransfer" runat="server" Text="申请转化" OnClick="btnTransfer_Click" />
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="font-size: 14px; font-weight: bold; line-height: 25px; padding-left: 10px;background-color:#F3F9FD;">
                                            评论列表
                                        </td>
                                    </tr>
                                    <tr>
                                        <td valign="top" style="padding-left: 10px; border:solid 1px #f3f9fd;">
                                            <asp:DataList ID="dlCommentList" runat="server" DataKeyField="ID" OnItemCommand="dlCommentList_ItemCommand"
                                                Width="95%" BorderWidth="1px" GridLines="Both" CellPadding="4" BackColor="White"
                                                BorderStyle="None" OnItemDataBound="dlCommentList_ItemDataBound">
                                                <SelectedItemStyle Font-Bold="True" ForeColor="#663399" BackColor="#f5f5f5"></SelectedItemStyle>
                                                <FooterStyle ForeColor="#0099cc" BackColor="#FFFFCC"></FooterStyle>
                                                <ItemStyle ForeColor="#0099cc" BackColor="White" BorderStyle="Dotted" BorderColor="#DCDCDC"
                                                    BorderWidth="1"></ItemStyle>
                                                <ItemTemplate>
                                                    <asp:Label ID="lblUserID" runat="server" Text='<%# Eval("UserID") %>' Visible="false"></asp:Label>
                                                    用户：<asp:Label ID="lblUser" runat="server"></asp:Label>
                                                    留言于：<asp:Label ID="lblCommentTime" runat="server" Text='<%# Eval("CommentTime")%>'></asp:Label>&nbsp;&nbsp;&nbsp;&nbsp;
                                                    <asp:LinkButton ID="lkbtnReply" PostBackUrl="#txtContent" Text="回复" runat="server"
                                                        CommandName="select"></asp:LinkButton><br />
                                                    <%--<a id="aReply" href="#txtContent" onclick="aReply_Click" runat="server">回复</a><br />--%>
                                                    <asp:Label ID="lblContent" runat="server" CssClass="commentContent" Text='<%# Eval("Content").ToString().Replace("\r\n", "<br>") %>'></asp:Label><br />
                                                    <br />
                                                    <%--<asp:DataList ID="dlReplyList" Width="100%" DataSource='<%#GetReplyDS(Eval("CommentID").ToString()) %>' runat="server" BorderWidth="0" DataKeyField="ReplyID" CellPadding="4" BackColor="White" BorderStyle="None" BorderColor="#CC9966">
                                <ItemStyle ForeColor="#33aaaa" BackColor="#F2FAFD"></ItemStyle>
                                <ItemTemplate>                                    
                                    <asp:Label ID="lblContent" runat="server" Text='<%# Eval("UserName").ToString()+ "回复：</font><font color=#660000>"+ Eval("Content").ToString().Replace("\r", "<br>").Replace("\n", "") + "</font>"%>'></asp:Label><br /><br />
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" ForeColor="#FFFFCC" BackColor="#990000"></HeaderStyle>
                            </asp:DataList>--%>
                                                    <%# string.IsNullOrEmpty(Eval("Reply").ToString()) == true ? "" : "<div>发布者回复：<br /> <span style='font-size:12px;line-height:22px;'>" + Eval("Reply") + "</span></div>"%>
                                                    <asp:TextBox ID="txtReply" runat="server" Text='<%#Eval("Reply") %>' Visible="false"></asp:TextBox>
                                                </ItemTemplate>
                                            </asp:DataList>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="font-size: 14px; font-weight: bold; line-height: 25px; padding-left: 10px;background-color:#F3F9FD;">
                                            发表评论
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="padding-left: 10px;">
                                            <textarea name="txtContent" class="txt" id="txtContent" cols="50" rows="10" runat="server"></textarea>&nbsp;<span
                                                style="color: Red;">*</span>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="padding-left: 10px;">
                                            <asp:TextBox ID="tbxCode" runat="server" class="txt" autocomplete="off" MaxLength="6" onkeydown="perform()"
                                                Width="51px"></asp:TextBox>
                                            &nbsp;<img border="0" src="../VerifyCode.aspx" />
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="padding-left: 10px;">
                                            <asp:Button ID="btnSubmit" runat="server" Text="提交" OnClick="btnSubmit_Click" />
                                            &nbsp;
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        </td>
                        <%-- <td width="0%" align="right" valign="top">
                            <img src="../images/right02.gif" width="4" height="134" />
                        </td>--%>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
    </form>

    <script language="javascript" type="text/javascript">
        $(document).ready(function() {
            Validator();
        });
        function Validator() {
            $('#<%= btnSubmit.ClientID %>').bind('click', function() {

                return GetValidatorMessage();
            });
            $("#<%=txtContent.ClientID %>").textlimit(2000);
        }
    </script>

</body>
</html>
