Forums Forums Search & Filter Pro Category description in search results

Viewing 3 posts - 11 through 13 (of 13 total)
  • Trevor
    #236248

    I added this code:

    https://www.screencast.com/t/WYIjHhwBYb

    This:

    global $searchandfilter;
    $sf_current_query = $searchandfilter->get(332)->current_query();
    $sf_current_query_array = $searchandfilter->get(332)->current_query()->get_array();
    if ((!$sf_current_query->is_filtered())&&($sf_current_query->get_search_term()=="")) {
      echo '<div>No category selected.</div>'; 
    } else {
      echo '<div>' . $sf_current_query_array["_sft_category"]["active_terms"][0]["value"] . '</div>';
      echo '<div>' . $sf_current_query_array["_sft_category"]["active_terms"][0]["id"]. '</div>';
      echo '<div>' . category_description($sf_current_query_array["_sft_category"]["active_terms"][0]["id"]). '</div>';
    }
    Anonymous
    #236317

    Thanks a big bunch Tervor! It’s perfect.

    Trevor
    #236319

    Thanks for letting me know. I will close this thread for now.

Viewing 3 posts - 11 through 13 (of 13 total)