'."\n";
}
// Determine if faqs for sub-categories should be displayed or not.
if (($get_child_terms && $category_display == 'categories_inline') || ((($show_term_page_children && $this_page != 'faq') || $hide_child_terms) && $category_display == 'hide_qa')) {
$output .= faq_get_child_categories_faqs($term, 'faq_category_questions_top', $default_weight, $default_sorting, $category_display, $class);
}
// Retrieve questions and answers for this term.
$group_questions_top = variable_get('faq_group_questions_top', FALSE);
$questions = array();
if (count($nodes)) {
foreach ($nodes as $node) {
$anchor = $term->tid ."n". $node->nid;
$questions[] = l($node->question, $this_page, NULL, NULL, $anchor);
if ($group_questions_top || $category_display == "hide_qa") {
$answers .= theme('faq_format_question', $node, NULL, $anchor);
$answers .= faq_view_answer($node, $back_to_top, $teaser, $links);
}
}
}
// Add question list to HTML output first, to appear at top of page.
$list_style = variable_get('faq_question_listing', 'ul');
$output .= theme('item_list', $questions, NULL, $list_style, array("class" => "faq-ul-questions-top"));
// If questions and answers are to be grouped together, add answers to HTML
// output before adding question list for sub-categories. Same is true if
// using the 'hide_qa' category layout.
if ($group_questions_top || $category_display == "hide_qa") {
// Output category name with answers.
if ($answer_category_name) {
if ($node_count) {
$output .= $answers_header;
$output .= "
\n". $answers ."\n
\n";
}
$output .= "