phpBB

Code Changes

File: phpbb/search/fulltext_postgres.php

  Unmodified   Added   Modified   Removed
Line 204Line 204
		}

// Filter out as above

		}

// Filter out as above

		$split_keywords = preg_replace("#[\"\n\r\t]+#", ' ', trim(htmlspecialchars_decode($keywords, ENT_COMPAT)));

		$split_keywords = preg_replace("#[\"\n\r\t]+#", ' ', trim(html_entity_decode($keywords, ENT_COMPAT)));


// Split words
$split_keywords = preg_replace('#([^\p{L}\p{N}\'*"()])#u', '$1$1', str_replace('\'\'', '\' \'', trim($split_keywords)));


// Split words
$split_keywords = preg_replace('#([^\p{L}\p{N}\'*"()])#u', '$1$1', str_replace('\'\'', '\' \'', trim($split_keywords)));

Line 550Line 550
		// if the total result count is not cached yet, retrieve it from the db
if (!$result_count)
{

		// if the total result count is not cached yet, retrieve it from the db
if (!$result_count)
{

			$sql_count = "SELECT COUNT(*) as result_count

			$sql_count = "SELECT COUNT(DISTINCT " . (($type == 'posts') ? 'p.post_id' : 't.topic_id') . ") as result_count

				$sql_from
$sql_where";
$result = $this->db->sql_query($sql_count);

				$sql_from
$sql_where";
$result = $this->db->sql_query($sql_count);