diff options
author | Chris Smith <toonarmy@phpbb.com> | 2008-09-15 11:11:39 +0000 |
---|---|---|
committer | Chris Smith <toonarmy@phpbb.com> | 2008-09-15 11:11:39 +0000 |
commit | bc57ba098e5f908f1cf35acfb6363603fbeaf3dc (patch) | |
tree | 936f0395c671d33f334cf4fb6c5484d7dcfbcb89 /phpBB/search.php | |
parent | 572d5bd8c1bb2a175fb6cfafa24a4d0c516b69d0 (diff) | |
download | forums-bc57ba098e5f908f1cf35acfb6363603fbeaf3dc.tar forums-bc57ba098e5f908f1cf35acfb6363603fbeaf3dc.tar.gz forums-bc57ba098e5f908f1cf35acfb6363603fbeaf3dc.tar.bz2 forums-bc57ba098e5f908f1cf35acfb6363603fbeaf3dc.tar.xz forums-bc57ba098e5f908f1cf35acfb6363603fbeaf3dc.zip |
- Added missing terms parameter to search pagination. #34085
- Do not use the topics posted table when performing an egosearch.
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8843 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/search.php')
-rw-r--r-- | phpBB/search.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/phpBB/search.php b/phpBB/search.php index 6af534b0b0..d987c74fbd 100644 --- a/phpBB/search.php +++ b/phpBB/search.php @@ -476,6 +476,7 @@ if ($keywords || $author || $author_id || $search_id || $submit) $u_search = append_sid("{$phpbb_root_path}search.$phpEx", $u_sort_param . $u_show_results); $u_search .= ($search_id) ? '&search_id=' . $search_id : ''; $u_search .= ($u_hilit) ? '&keywords=' . urlencode(htmlspecialchars_decode($search->search_query)) : ''; + $u_search .= ($search_terms != 'all') ? '&terms=' . $search_terms : ''; $u_search .= ($topic_id) ? '&t=' . $topic_id : ''; $u_search .= ($author) ? '&author=' . urlencode(htmlspecialchars_decode($author)) : ''; $u_search .= ($author_id) ? '&author_id=' . $author_id : ''; @@ -542,7 +543,7 @@ if ($keywords || $author || $author_id || $search_id || $submit) if ($user->data['is_registered']) { - if ($config['load_db_track']) + if ($config['load_db_track'] && $author_id !== $user->data['user_id']) { $sql_from .= ' LEFT JOIN ' . TOPICS_POSTED_TABLE . ' tp ON (tp.user_id = ' . $user->data['user_id'] . ' AND t.topic_id = tp.topic_id)'; @@ -772,6 +773,11 @@ if ($keywords || $author || $author_id || $search_id || $submit) if ($show_results == 'topics') { + if ($config['load_db_track'] && $author_id === $user->data['user_id']) + { + $row['topic_posted'] = 1; + } + $folder_img = $folder_alt = $topic_type = ''; topic_status($row, $replies, (isset($topic_tracking_info[$forum_id][$row['topic_id']]) && $row['topic_last_post_time'] > $topic_tracking_info[$forum_id][$row['topic_id']]) ? true : false, $folder_img, $folder_alt, $topic_type); |