10 namespace Fossology\UI\Page;
13 use Symfony\Component\HttpFoundation\Request;
14 use Symfony\Component\HttpFoundation\Response;
19 const NAME =
'Getting Started';
21 function __construct()
23 parent::__construct(self::NAME, array(
24 self::TITLE => _(
"Getting Started with FOSSology"),
25 self::REQUIRES_LOGIN =>
false,
26 self::MENU_LIST =>
"Help::Getting Started",
35 $topMenuList =
"Main::" .
"Help::Getting Started";
37 menu_insert($topMenuList.
'::Overview', $menuOrder-10, $this->getName().
"&show=welcome");
38 menu_insert($topMenuList.
'::License Browser', $menuOrder, $this->getName().
"&show=licensebrowser");
45 protected function handle(Request $request)
47 $show = $request->get(
'show');
48 if ($show ==
'licensebrowser') {
49 return $this->
render(
"getting_started_licensebrowser.html.twig");
52 if (empty($_SESSION[
'User']) && (plugin_find_id(
"auth") >= 0)) {
53 $login =
"<a href='".Traceback_uri().
"?mod=auth'>$login</a>";
57 return $this->
render(
'getting_started.html.twig', $this->mergeWithDefault($vars));
61 register_plugin(
new GettingStartedPage());
render($templateName, $vars=null, $headers=null)
RegisterMenus()
Customize submenus.
Traceback_uri()
Get the URI without query to this location.