/** * Add a module stylesheet to the CSS queue * @param string $module * @param string $stylesheet * @param string $media * @param string $path * @param string $ext; */ public static function add_css($module, $stylesheet, $media = 'screen', $path = '', $ext = '.css') { if (file_exists('site/' . FabriqStack::site() . "/modules/{$module}/stylesheets/{$path}/{$stylesheet}.{$ext}")) { self::$cssqueue[] = array('css' => $stylesheet, 'media' => $media, 'path' => Pathmap::getUrl() . "sites/" . FabriqStack::site() . "/modules/{$module}/stylesheets/{$path}", 'ext' => $ext); } else { self::$cssqueue[] = array('css' => $stylesheet, 'media' => $media, 'path' => PathMap::getUrl() . "modules/{$module}/stylesheets/{$path}", 'ext' => $ext); } }
/** * Redirect the user to the given error page * @param $error */ public static function error($error) { header('Location: ' . PathMap::getUrl() . "{$error}"); exit; }