Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

Multiple in-place editors for non-RTE fields

Avatar

Level 2

Greetings forum members,

I was following the steps provided in [1] to create multiple inline editors. The problem I face, is that all of these give the RTE interface, and considers the text as rich, and adds <p> tag.

Does any one have advice on how to create multiple inplace editing option for non-RTE text fields in touch UI. I am using 6.2?

  1. https://docs.adobe.com/docs/en/aem/6-1/develop/components/multiple-inplace-editors.html
1 Accepted Solution

Avatar

Correct answer by
Administrator

Hi 

Please have a look at this community article :

Link:-http://freakyrajput.blogspot.in/2015/07/remove-p-tag-from-rte-in-aem.html  [Not Tested on AEM 6.1 but it should work]

// Remove p tag from RTE in AEM

    You can keep the RTE from surrounding your text with <p> tags by setting the removeSingleParagraphContainer property to true as long as you only create one paragraph.

    With Chrome on Mac OS X (at least), holding shift while pressing enter inserts line breaks instead of paragraph breaks so you can still create text with multiple lines.

    <rtePlugins jcr:primaryType="nt:unstructured">
        ...
    </rtePlugins>
    <htmlRules jcr:primaryType="nt:unstructured">
        <docType jcr:primaryType="nt:unstructured">
            ...
        </docType>
        <blockHandling
            jcr:primaryType="nt:unstructured"
            removeSingleParagraphContainer="{Boolean}true"/>

    </htmlRules>

Reference Forum Post:- http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manage...

// rte remove tag p

Try this, if this comes to you as some rescue. Else i will try to get some RTE Expert to help you on this./

~kautuk



Kautuk Sahni

View solution in original post

3 Replies

Avatar

Correct answer by
Administrator

Hi 

Please have a look at this community article :

Link:-http://freakyrajput.blogspot.in/2015/07/remove-p-tag-from-rte-in-aem.html  [Not Tested on AEM 6.1 but it should work]

// Remove p tag from RTE in AEM

    You can keep the RTE from surrounding your text with <p> tags by setting the removeSingleParagraphContainer property to true as long as you only create one paragraph.

    With Chrome on Mac OS X (at least), holding shift while pressing enter inserts line breaks instead of paragraph breaks so you can still create text with multiple lines.

    <rtePlugins jcr:primaryType="nt:unstructured">
        ...
    </rtePlugins>
    <htmlRules jcr:primaryType="nt:unstructured">
        <docType jcr:primaryType="nt:unstructured">
            ...
        </docType>
        <blockHandling
            jcr:primaryType="nt:unstructured"
            removeSingleParagraphContainer="{Boolean}true"/>

    </htmlRules>

Reference Forum Post:- http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manage...

// rte remove tag p

Try this, if this comes to you as some rescue. Else i will try to get some RTE Expert to help you on this./

~kautuk



Kautuk Sahni

Avatar

Level 3

Hi Kautuk?

Is it possible to have multiple in-place editing options for the Image component with two image fields (Desktop/mobile)?
By default, it works for the first configured image.