32 function __construct()
34 parent::__construct(self::NAME, array(
35 self::TITLE => _(
"Getting Started with FOSSology"),
36 self::REQUIRES_LOGIN =>
false,
37 self::MENU_LIST =>
"Home",
38 self::MENU_ORDER => 100
46 protected function handle(Request $request)
48 $vars = array(
'isSecure' => $request->isSecure());
49 if (array_key_exists(
'User', $_SESSION) && $_SESSION[
'User'] ==
50 "Default User" && plugin_find_id(
"auth") >= 0) {
51 if (isset($_SERVER[
'HTTPS']) && $_SERVER[
'HTTPS'] !=
"off") {
52 $vars[
'protocol'] =
"HTTPS";
54 $vars[
'protocol'] = preg_replace(
"@/.*@",
"",
55 @$_SERVER[
'SERVER_PROTOCOL']);
58 $vars[
'referrer'] =
"?mod=browse";
59 $vars[
'authUrl'] =
"?mod=auth";
62 return $this->
render(
"home.html.twig", $this->mergeWithDefault($vars));
render($templateName, $vars=null, $headers=null)