Copied to clipboard

Flag this post as spam?

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


  • David Armitage 414 posts 1655 karma points
    Aug 24, 2017 @ 04:27
    David Armitage
    0

    Umbraco RTE Tinymce remove <br/><br/> wrapped around plain paragraphs

    Hi Guys,

    I started using the Umbraco 7.6 and the RTE is acting slightly different which I don't like.

    Previously if I had a few plain text paragraphs (copied straight out of notepad) and then pasted into the RTE it wrapped the paragraphs in paragraph.

    E.g <p>paragraph1</p><p>paragraph2</p>

    Now with the new version it seems to not wrap the paragraphs but instead separates the paragraphs with line breaks.

    Eg. <p>paragraph1<br /><br />paragraph2</p>

    Does anyone know how to change this setting back to using

    tags rather than the line breaks?

    Thanks in advance.

    Kind Regards

    David

  • David Armitage 414 posts 1655 karma points
    Aug 24, 2017 @ 04:51
    David Armitage
    0

    Hi,

    I found a few mentions of

    <config key="force_br_newlines">true</config>
    

    as per this link.

    https://our.umbraco.org/forum/using/ui-questions/27674-tinyMCE3-and-forcebrnewlines

    I tested updating the config settings of the config/tinyMceConfig.config file to the following. Unfortunately it had no effect. Html line breaks (

    ) are still added in between paragraphs rather than

    tags.

    <customConfig>
        <!--    <config key="myKey">mySetting</config>-->
        <config key="entity_encoding">raw</config>
        <config key="force_br_newlines">false</config>
        <config key="force_p_newlines">true</config>
        <config key="codemirror">
          {
          "indentOnInit": false,
          "path": "../../../../lib/codemirror",
          "config": {
          },
          "jsFiles": [
          ],
          "cssFiles": [
          ]
          }
        </config>
      </customConfig>
    

    Any ideas?

    Kind Regards

    David

  • David Armitage 414 posts 1655 karma points
    Aug 24, 2017 @ 05:34
    David Armitage
    100

    Hi,

    I finally figured this out with a little help from another post I found.

    https://our.umbraco.org/forum/umbraco-7/using-umbraco-7/54785-Paste-from-word-help-needed

    It appears that the settings I mentioned above don't really do anything. Well maybe not now.

    Here is the new setup for the config/tinyMceConfig.config file which works for me. It also cleans up the nasty html formatting when copy and pasting from Microsoft Word.

    <customConfig>
        <!--    <config key="myKey">mySetting</config>-->
        <config key="entity_encoding">raw</config>
        <config key="paste_as_text">true</config>
        <config key="paste_text_sticky">true</config>
        <config key="paste_text_sticky_default">true</config>
        <config key="codemirror">
          {
          "indentOnInit": false,
          "path": "../../../../lib/codemirror",
          "config": {
          },
          "jsFiles": [
          ],
          "cssFiles": [
          ]
          }
        </config>
      </customConfig>
    
  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies