Support

Account

Home Forums General Issues Textarea doesn't automatically add paragraphs

Solving

Textarea doesn't automatically add paragraphs

  • I have set the textarea new lines option to ‘automatically add paragraphs’; however what it does is wrap the entire text in a paragraph and separate new lines with <br/>. I would have thought the correct behaviour would be each paragraph would be wrapped in its own <p> tag? Is there a bug or was ACF intended to work like this?

    • James

    • January 18, 2017 at 12:42 am

    Hi @ch1n3s3b0y

    This is not standard behavior, the first step in diagnosing whether there is a conflict would be to check if the same is reported when all other plugins have been deactivated and while running one of the stock WP themes.

    Let me know how this goes.

  • Hi @acf-support

    I’m not running any other plugins. Only the latest version or WordPress and the latest version of ACF.

    • James

    • January 18, 2017 at 3:58 pm

    Hi @ch1n3s3b0y

    Please keep in mind that a new paragraph is a text with two new lines. So, if the text only has one line, ACF will add <br> tag instead. Here’s an example of text that will add <p> tag:

    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean finibus viverra risus, ut viverra metus tristique at.
    
    Quisque id dui iaculis, dignissim lorem ac, sagittis orci. Etiam a semper justo.

    And this one will add only <br> tag:

    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean finibus viverra risus, ut viverra metus tristique at.
    Quisque id dui iaculis, dignissim lorem ac, sagittis orci. Etiam a semper justo.

    I hope this makes sense 🙂

  • I’m having the same problem with “Automatically add paragraphs”. A single line break results in:

    <p>
    Text 1
    <br />
    <br />
    Text 2
    </p>

    Two line breaks results in:

    <p>
    Text1
    </p>
    <br />
    <p>
    Text 2
    </p>

    Either way there’s an unwanted <br> whose height is quite difficult to control via css.

    • Giray

    • December 25, 2019 at 7:52 am

    Old thread but current problem. In a text area, new paragraph selected, this is still my output no matter how may ways I try to do it – fresh typed, copy paste, etc.

    <p>This is a test<br>
    This is line two<br>
    This is line three</p>

    I cannot find a way to create three paragraphs. Am I missing something?

  • This isn’t standard conduct, the initial phase in diagnosing whether there is a contention is check if the equivalent is accounted for when all different modules have been deactivated and keeping in mind that running one of the stock WP topics.

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.

We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Cookie Policy. If you continue to use this site, you consent to our use of cookies.