Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Editing the buttons in cleditor?

NonnisiNonnisi New
edited June 2012 in Vanilla 2.0 - 2.8

The cleditor does a great job formatting users comments and keeping things nice n simple. However it has WAY too many buttons, for example, ones for copy,paste and print are really not needed.

Is there any way to edit what buttons it uses to make is simpler and cleaner for users?

Best Answer

  • edited June 2012 Answer ✓

    yes of course

    as I remember in the plugin starting php file there's a script for "jquery(document).ready"-
    there you can delete buttons and change their places, and set the groups as you want with | char

Answers

  • edited June 2012 Answer ✓

    yes of course

    as I remember in the plugin starting php file there's a script for "jquery(document).ready"-
    there you can delete buttons and change their places, and set the groups as you want with | char

  • kirkpa31kirkpa31 ✭✭
    edited February 2013

    Can I bring this question back up? I'm confused as to your answer for this problem. I'm sure it's easy, only I am a newb.

  • I've found the following script in my default.php for cleditor, no clude even if I'm looking in the correct place, just based off of your previous answer.

    <script type="text/javascript"> jQuery(document).ready(function($) { // Make sure the removal of autogrow does not break anything jQuery.fn.autogrow = function(o) { return; } // Attach the editor to comment boxes jQuery("#Form_Body").livequery(function() { var frm = $(this).parents("div.CommentForm"); ed = jQuery(this).cleditor({width:"100%", height:"100%"})[0]; this.editor = ed; // Support other plugins! jQuery(frm).bind("clearCommentForm", {editor:ed}, function(e) { frm.find("textarea").hide(); e.data.editor.clear(); }); }); }); </script>');

  • The Buttons work using a sprite image, that means that the toolbar uses one image for all the buttons. If you were to disable a button/function from the jquery.cleditor.min.js you would also have to edit the toolbar image that has the rest of the buttons. If you don't wan't the full functionality of the cleditor, then just disable it in the dashboard and you will have a minimalistic Form.

  • kirkpa31kirkpa31 ✭✭
    edited February 2013

    @vrijvlinder Thanks, I'll give this a try, hopefully later today.

Sign In or Register to comment.