5.x db.inc fp_get_system_settings($force_rebuild = FALSE)
4.x db.inc fp_get_system_settings($force_rebuild = FALSE)
8 calls to fp_get_system_settings()
admin_advising_settings_form in modules/admin/admin.module
This is a systems settings form, which lets the user edit advising variabled for FlightPath.
admin_get_de_catalog_year in modules/admin/admin.module
Get the "de_catalog_year" from the REQUEST. If it's not there or invalid, pull it from our system settings.
advise_display_popup_group_select in modules/advise/advise.module
advise_init_advising_variables in modules/advise/advise.module
Takes various variables from the REQUEST and stores them in our advising_session_variables table for more convenient use later on.
course_search_display_courses in modules/course_search/course_search.module
Show the user their select of courses.

... See full list


includes/db.inc, line 652
This file contains mostly db shortcuts.


function fp_get_system_settings($force_rebuild = FALSE) {

  if ($force_rebuild == FALSE && isset($GLOBALS["fp_system_settings"])) {
    return $GLOBALS["fp_system_settings"];

  // Get all of our settings from the variables table.
  $res = db_query("SELECT * FROM variables");
  while ($cur = db_fetch_array($res)) {
    $name = $cur["name"];
    $val = unserialize($cur["value"]);

    if ($val == "BOOLEAN_FALSE_PLACEHOLDER") {
      $val = FALSE;

    $settings[$name] = $val;
    $GLOBALS["fp_system_settings"][$name] = $val;


  // Make sure some important settings have _something_ set, or else it could cause
  // problems for some modules.
  if ($settings["current_catalog_year"] == "") {
    $settings["current_catalog_year"] = 2006;
  if ($settings["earliest_catalog_year"] == "") {
    $settings["earliest_catalog_year"] = 2006;

  $GLOBALS["fp_system_variables"] = $settings;

  return $settings;