Support

Account

Home Forums General Issues wysiwyg adding after each shortcode Reply To: wysiwyg adding after each shortcode

  • Here’s another why to do this:

    add_filter('acf_the_content', 'shortcode_empty_paragraph_fix');
    function shortcode_empty_paragraph_fix($content) {   
    	$array = array (
    		'<p>[' => '[', 
    		']</p>' => ']', 
    		']<br />' => ']'
    	);
    
    	$content = strtr($content, $array);
    
    	return $content;
    }