nl2br issue

  • I use and like this plugin – thanks for it!

    I do have a request, though. I noticed when a post had an un-ordered list that it would display “fine” in the actual post, but would have many more line breaks in the NLP display. Viewing the source, the NLP display adds BR tags around every
    LI tag.

    I’m not a coder, but browsing through the plugin’s “network-latest-posts.php” file, I found four calls to nl2br(). Based on the if() statements, I changed only the one pertinent to my scenario and voila: the extraneous BR tags were gone. Yay!

    FYI, I changed line 972 from:
    echo nl2br( do_shortcode( $field->post_content ) );
    echo ( do_shortcode( $field->post_content ) );

    But my problem is that when I update the plugin to your next release, my change to your code will disappear. Can you make this a user-interface option, so it is saved between plugin updates?

    Thanks again.

Viewing 1 replies (of 1 total)
  • Plugin Author Jose Luis SAYAGO


    Hello, thanks for your feedback. I will keep your suggestion in mind, certainly I can’t remove it because for some people line breaks don’t appear without nl2br. So I will give people the option to use it or not.


Viewing 1 replies (of 1 total)
  • The topic ‘nl2br issue’ is closed to new replies.
Skip to toolbar