Divi WordPress Theme
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WordPress fix Reply To: Closing – tag

Discussion in 'Misc WordPress Requests' started by clgrmn, Feb 22, 2018.

  1. clgrmn


    Reply To: Closing – tag, by clgrmn

    I have a local installation of wordpress with understrap as a parent theme.

    I just wanted to try something in the wordpress editor, created the structure as told above and wanted to inspect it in chrome.

    But I already figured out what is probably causing the problem. I had following function in my functions.php to remove empty <p> – tags.

    add_filter('the_content', 'remove_empty_p', 20, 1);
    function remove_empty_p($content){
    $content = force_balance_tags($content);
    return preg_replace('#<p>\s*+(<br\s*/*>)?\s*</p>#i', '', $content);

    After removing this function the main tag is closed as it should be. (after the sections)

    Reply To: Closing – tag

Share This Page

Monarch Social Sharing Plugin