You are here

function magic_theme_load in Magic 7.2

Menu system load callback.

Checks whether a given theme (menu argument) exists.

Parameters

$theme: The machine-readable name of a theme.

Return value

string|bool The given theme name or FALSE if the given theme does not exist.

File

./magic.module, line 119
Keep Frontend DRY; sprinkle it with MAGIC!

Code

function magic_theme_load($theme) {
  if (array_key_exists($theme, list_themes())) {
    return $theme;
  }
  return FALSE;
}