From fba19143954dfcd80d6a3efa48d871fe3b77804d Mon Sep 17 00:00:00 2001 From: Anthony Talarico Date: Mon, 23 Nov 2015 16:09:05 -0500 Subject: [PATCH] removed regex --- search.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/search.php b/search.php index 5a7175f..2002624 100644 --- a/search.php +++ b/search.php @@ -37,7 +37,7 @@ // Load content as plain text global $wp_query, $post; - $content = preg_replace('/[\n\r]+/', '', $content); + $content = (!post_password_required($post) ? strip_tags(preg_replace(array("/\r?\n/", '@<\s*(p|br\s*/?)\s*>@'), array(' ', "\n"), apply_filters('the_content', $post->post_content))) : ''); // Search content for terms -- 2.17.1