Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Michiel (NSC) 95 posts 115 karma points
    Oct 31, 2011 @ 12:09
    Michiel (NSC)
    0

    How do I remove a macro from the rich text editor?

    It's generally really hard to remove a macro from the rich text editor, the cursor gets stuck and you just end up deleting content after the macro. If there is no content before the macro, it's imposible to position the cursor, and impossible to enter content before the macro.

    Umbraco 4.7.1 and Chrome 15. Is this new or known?

  • Rodion Novoselov 694 posts 859 karma points
    Oct 31, 2011 @ 18:07
    Rodion Novoselov
    1

    Hmm. I've seen such a problem. That's not that difficult for me since I switch to the html view and insert an <p></p> before the macro tag in case of troubles, don't know however to what extent it could be acceptable for a regular user...

  • Jan Skovgaard 11280 posts 23678 karma points MVP 10x admin c-trib
    Oct 31, 2011 @ 18:46
    Jan Skovgaard
    1

    Hi Michiel

    This is known I think, since I've also been wondering about how to remove macros myself.

    However I usually do one of these...

    1) Enter HTML view and remove the div containing the macro
    2) Mark the macro with the cursor so the text turns blue and hit delete a couple of times

    It's not ideal in any way but it has worked for me so far.

    /Jan

  • Michiel (NSC) 95 posts 115 karma points
    Nov 01, 2011 @ 10:33
    Michiel (NSC)
    0

    Yeah, it's not so much that it's impossible, but more that it's a nuisance. With your second option, it's generally inconsistent, you end up with content that follows the macro inside the macro block. 

    As for editors, they just don't understand this. Perhaps after a few weeks of using the CMS they learn to live with it, but it's never going to be fun for them. Especially if they need to go into the HTML view.

    Definitely room for improvement, I'm opening a ticket...

    brb

  • Michiel (NSC) 95 posts 115 karma points
    Nov 01, 2011 @ 10:37
  • Jean-Francois Dessureault 7 posts 30 karma points c-trib
    Aug 06, 2015 @ 19:33
    Jean-Francois Dessureault
    0

    This can be fixed by modifying line 64 of umbraco/plugins/tinymce3/insertMacro.aspx .

    Just replace

    tinyMCEPopup.editor.execCommand("mceInsertContent", false, renderedContent);
    

    by

    tinyMCEPopup.editor.execCommand("mceInsertContent", false, renderedContent + "<p>&nbsp;</p>");
    

    I'm inserting a non-breaking space inside the paragraph so TinyMCE doesn't strip the empty tag afterwards.

    I know this is kinda old but I didn't find the solution documented anywhere and the ticket somehow disappeared in the last 5 years. I've received many user complaints about this issue so, I hope this helps!

Please Sign in or register to post replies

Write your reply to:

Draft