We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 12028
    • 152 Posts
    When you use the content area and edit it with TinyMCE, it's add the p tags around MODX tags.

    And if I remember correctly, I saw a plugin that could delete them on save in these forums - but I forgot to bookmark it.

    Is there anyone who knows where it is?

    This question has been answered by cyclissmo. See the first response.

    [ed. note: Henrik Nielsen last edited this post 12 years, 8 months ago.]
      - A small step for mankind, so why not take two...

      Working with web production, graphic design/workflow, photo and education - but are trying to get a life in between!
      • 14951
      • 151 Posts
      I'm not sure about a plugin, but you could change the setting "Forced Root Block" under System Settings in the TinyMCE namespace.

      You could change it to "<div>" which would be much less intrusive than a paragraph tag with inherit styling or just shut it off.

      • discuss.answer
        • 6228
        • 249 Posts
        Turning off Fored Root Blocks does have some drawbacks, so if you wish to use a plugin to remove the tags, you can use something like the following:

        $search = array('<p>[[', ']]</p>');
        $replace = array('[[', ']]');
        $modx->documentOutput = str_replace($search, $replace, $modx->documentOutput);


        set it to fire on OnParseDocument.
          lo9on.com

          MODx Evolution/Revolution | Remote Desktop Training | Development
          • 3749
          • 24,544 Posts
          Or just turn off rich-text editing. wink
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting
            • 12028
            • 152 Posts
            I apologize for the late reply - but your posts disappeared for me in the new forum...

            @cyclissmo: I had just tried your solution, and I go for that!
            @jaredloman and @BobRay: Although your suggestions would work for me, I'm afraid they are "no go" for the daily users.

            But many thanks for your suggestions!
              - A small step for mankind, so why not take two...

              Working with web production, graphic design/workflow, photo and education - but are trying to get a life in between!