An error has occurred: You are attempting to view an FAQ question that does not exist. "; } echo "

$question[question]

$question[answer]

 

"; } else { // IF USER IS LOOKING AT THE MAIN PAGE $totalcount = 0; $faq_questions = mysql_query("SELECT * FROM faq_questions"); $faqcat = mysql_query("SELECT * FROM faq_categories ORDER BY c_order"); $num_of_kitties = mysql_num_rows($faqcat); while($faqcat_info = mysql_fetch_assoc($faqcat)) { $questions = mysql_query("SELECT q_id, c_id, question FROM faq_questions WHERE c_id='$faqcat_info[c_id]' ORDER BY q_order"); // SHOW CATEGORY NAME, IF IT CONTAINS QUESTIONS AND CATEGORY NAMES ARE TURNED ON if(mysql_num_rows($questions) > 0) { if($admin_info[showcats] == 1) { echo "

$faqcat_info[category]

"; } } // SHOW QUESTIONS $count = 0; while($question = mysql_fetch_assoc($questions)) { $totalcount++; $count++; // SHOW NUMBERS IF ENABLED if($admin_info[shownumbers] == 1) { if($admin_info[showcats] == 1) { echo "$count. "; } else { echo "$totalcount. "; } } echo "$question[question]
"; } // ADD SPACE AFTER THIS CATEGORY if(mysql_num_rows($questions) != 0 AND $admin_info[showcats] == 1) { echo "
"; } } } // SHOW HTML FOOTER echo $admin_info[footer]; ?>