PHP Classes

File: web/SSO/modules/core/www/frontpage_welcome.php

Recommend this page to a friend!
  Classes of william amed   Raptor 2   web/SSO/modules/core/www/frontpage_welcome.php   Download  
File: web/SSO/modules/core/www/frontpage_welcome.php
Role: Example script
Content type: text/plain
Description: Example script
Class: Raptor 2
Framework that takes routes from annotations
Author: By
Last change:
Date: 8 years ago
Size: 1,308 bytes
 

Contents

Class file image Download
<?php


/* Load simpleSAMLphp, configuration */
$config = SimpleSAML_Configuration::getInstance();
$session = SimpleSAML_Session::getSessionFromRequest();

/* Check if valid local session exists.. */
if ($config->getBoolean('admin.protectindexpage', false)) {
   
SimpleSAML_Utilities::requireAdmin();
}
$loginurl = SimpleSAML_Utilities::getAdminLoginURL();
$isadmin = SimpleSAML_Utilities::isAdmin();





$links = array();
$links_welcome = array();
$links_config = array();
$links_auth = array();
$links_federation = array();



$allLinks = array(
   
'links' => &$links,
   
'welcome' => &$links_welcome,
   
'config' => &$links_config,
   
'auth' => &$links_auth,
   
'federation' => &$links_federation,
);

$links_welcome[] = array(
   
'href' => 'https://simplesamlphp.org/docs/stable/',
   
'text' => '{core:frontpage:doc_header}',
);

SimpleSAML_Module::callHooks('frontpage', $allLinks);









$t = new SimpleSAML_XHTML_Template($config, 'core:frontpage_welcome.tpl.php');
$t->data['pageid'] = 'frontpage_welcome';
$t->data['isadmin'] = $isadmin;
$t->data['loginurl'] = $loginurl;

$t->data['links'] = $links;
$t->data['links_welcome'] = $links_welcome;
$t->data['links_config'] = $links_config;
$t->data['links_auth'] = $links_auth;
$t->data['links_federation'] = $links_federation;




$t->show();