Re: cute editor bug tab container tab panel

  •  02-01-2011, 1:08 PM

    Re: cute editor bug tab container tab panel

    Dear Alex1234,
     
    I have tested the following code in TabContainer, it works fine, this issue is not related to TabContainer.
    <%@ Page Language="C#" Trace="false"  ValidateRequest="false"   %>
    <%@ Register  Assembly="AjaxControlToolkit"   Namespace="AjaxControlToolkit"  TagPrefix="ajaxToolkit" %>
    <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html>
    <head id="Head1" runat="server" >
        <title>HTMLEditor Sample</title>
        <style type="text/css">
               a {
                       font:11px Verdana;
                       color:#315686;
                       text-decoration:underline;
               }
               a:hover {
                       color:#DC143C;
               }
        </style>
    </head>
    <script type="text/JavaScript"> 
    </script>
    <body style="font:12px Verdana;">
        <a href="../HTMLEditor.aspx">< Back to <strong>HTMLEditor</strong> page</a>
        <br /><br />
        <b>HTMLEditor</b> controls inside <b>Tabs</b> control.<br />
        <br />
        <form id="Form1" runat="server">
            <ajaxToolkit:ToolkitScriptManager runat="Server" EnablePartialRendering="true" ID="ScriptManager1" />
            <script type="text/javascript">
            </script>
            <ajaxToolkit:TabContainer runat="server" ID="Tabs" Height="370px" ActiveTabIndex="0" Width="832px">
                <ajaxToolkit:TabPanel runat="server" ID="TabPanel1" HeaderText="HTMLEditor 1">
                    <ContentTemplate>
                        <asp:UpdatePanel ID="updatePanel1" runat="server">
                            <ContentTemplate>
                              <CE:Editor id="editor1"  ThemeType="Office2007" EditCompleteDocument="true" AllowPasteHtml="false" runat="server" ></CE:Editor><br />      
                              <br />
                               <asp:Button runat="server" Text="Submit content" />
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </ContentTemplate>
                </ajaxToolkit:TabPanel>
                  <ajaxToolkit:TabPanel runat="server" ID="TabPanel2" HeaderText="HTMLEditor 2">
                    <ContentTemplate>
                        <asp:UpdatePanel ID="updatePanel2" runat="server">
                            <ContentTemplate>
                              <CE:Editor id="editor2"  ThemeType="Office2007" EditCompleteDocument="true" AllowPasteHtml="false" runat="server" ></CE:Editor><br />      
                              <br />
                               <asp:Button ID="Button1" runat="server" Text="Submit content" />
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </ContentTemplate>
                </ajaxToolkit:TabPanel>
            </ajaxToolkit:TabContainer>
        </form>
    </body>
    </html>
    <script runat="server">
     void Page_Load(object sender, System.EventArgs e)
      {
             if (!Page.IsPostBack)
             {
                 editor1.Text = "Some text for Tab panel #1";
                 editor2.Text = "Some text for Tab panel #2";
             }
     }
    </script>
    You can save the following code to test.aspx:
    <%@ Page Language="C#"%>
    <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html>
        <head>
      <title>ASP and ASP.NET WYSIWYG Editor - Edit Static Html Example </title> 
     </head>
     <body>
            <form id="Form1" runat="server">   
            <CE:Editor id="Editor1" runat="server" ></CE:Editor><BR>
            <asp:Button id="btnUpdate" onclick="Submit" Runat="server" Text="Submit"></asp:Button><br />   
         <asp:textbox id="textbox1" runat="server" TextMode="MultiLine" Height="250px" Width="750px" Font-Name="Arial"></asp:TextBox> 
      </form>
     </body>
    </html>
    <script runat="server">
     void Page_Load(object sender, System.EventArgs e)
      {      
       }
     public void Submit(object sender, System.EventArgs e)
     {   
       textbox1.Text = Editor1.PlainText; 
     }
    </script>
    If you run this snippet, does this style issue happen?
    You can post your code here, i will test your code on my end.
     
    Thank you for asking
     
     
     
     
View Complete Thread