how to disable the editor and hide the tool bar by javascript?

Last post 05-05-2010, 9:57 AM by Adam. 3 replies.
Sort Posts: Previous Next
  •  05-03-2010, 9:14 PM 60648

    how to disable the editor and hide the tool bar by javascript?

    pls help
  •  05-04-2010, 1:47 AM 60655 in reply to 60648

    Re: how to disable the editor and hide the tool bar by javascript?

    Hi wolf11th,
     
    1. Can not disable but you can hide it. example:
     
    1. <%@ Page Language="C#" %>   
    2.   
    3. <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>   
    4. <html>   
    5. <head>   
    6. </head>   
    7. <body>   
    8.     <form id="Form1" runat="server">   
    9.         <CE:Editor ID="editor1" runat="server">   
    10.         </CE:Editor>   
    11.         <input type="button" value="hide" onclick="hide()" />   
    12.     </form>   
    13. </body>   
    14. </html>   
    15.   
    16. <script>   
    17. function hide()   
    18. {   
    19. var editor1=document.getElementById("<%= editor1.ClientID %>");   
    20. editor1.style.visibility="hidden";   
    21. }   
    22.   
    23. </script>  

    2. For now edtior does not support hide the toolbar by javascript.
     
    Regards,
     
    ken
  •  05-04-2010, 8:37 PM 60693 in reply to 60655

    Re: how to disable the editor and hide the tool bar by javascript?

    thx Ken,
    that's ok. In this case I have to force another ajax post to disable the editor which will still show the tool bar in the meanwhile. depending on the Internet connection, it's sort of the only way although still anoying~~~
     
    Hopefully, in the new version cute editor can provider more client side API.
     
  •  05-05-2010, 9:57 AM 60729 in reply to 60693

    Re: how to disable the editor and hide the tool bar by javascript?

    wolf11th:
    thx Ken,
    that's ok. In this case I have to force another ajax post to disable the editor which will still show the tool bar in the meanwhile. depending on the Internet connection, it's sort of the only way although still anoying~~~
     
    Hopefully, in the new version cute editor can provider more client side API.
     
     
    It's possible to hide the toolbar when loading.
     
    Please try the following code:
     
    Editor1.AddInitializeScriptCode("document.getElementById('CE_Editor1_ID_ToolBar').style.display='none'");
     
    In the above code, the ID of Editor is Editor1.
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

View as RSS news feed in XML