Skip to:
Content

bbPress.org


Ignore:
Timestamp:
12/16/2012 08:19:21 AM (13 years ago)
Author:
jmdodd
Message:

Introduce dedicated forum search.

  • Search forums, topics, and replies.
  • Add new search functions, including bbp_has_search_results().
  • Provide templates for search results.
  • Fixes #1575.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/topics/template-tags.php

    r4575 r4579  
    366366     * @param $topic_id Optional. Used to check emptiness
    367367     * @uses bbPress::topic_query::post::ID To get the topic id
     368     * @uses bbp_is_topic() To check if the search result is a topic
    368369     * @uses bbp_is_single_topic() To check if it's a topic page
    369370     * @uses bbp_is_topic_edit() To check if it's a topic edit page
     
    390391        } elseif ( !empty( $bbp->topic_query->in_the_loop ) && isset( $bbp->topic_query->post->ID ) ) {
    391392            $bbp_topic_id = $bbp->topic_query->post->ID;
     393
     394        // Currently inside a search loop
     395        } elseif ( !empty( $bbp->search_query->in_the_loop ) && isset( $bbp->search_query->post->ID ) && bbp_is_topic( $bbp->search_query->post->ID ) ) {
     396            $bbp_topic_id = $bbp->search_query->post->ID;
    392397
    393398        // Currently viewing/editing a topic, likely alone
Note: See TracChangeset for help on using the changeset viewer.