$searchterm) { if (strlen($searchterm) < 2) { unset($searchterms[$key]); } } $search = trim(implode(" ", $searchterms)); } $site = get_site(); if ($CFG->forcelogin) { require_login(); } $displaylist = array(); $parentlist = array(); make_categories_list($displaylist, $parentlist, ""); $strcourses = get_string("courses"); $strsearch = get_string("search"); $strsearchresults = get_string("searchresults"); $strcategory = get_string("category"); if (!$search) { print_header("$site->fullname : $strsearch", $site->fullname, "$strcourses -> $strsearch", "", ""); print_simple_box_start("center"); echo "
"; print_string("searchhelp"); echo "
"; echo ""; $course->summary .= "$strcategory: category\">"; $course->summary .= $displaylist[$course->category]; $course->summary .= "
"; print_course($course); print_spacer(5,5); } print_paging_bar($totalcount, $page, $perpage, "search.php?search=$search&perpage=$perpage&"); } else { print_heading(get_string("nocoursesfound", "", $search)); } echo "