This repository was archived by the owner on Sep 19, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathredirect_some_users-tpl.php
More file actions
54 lines (40 loc) · 1.55 KB
/
redirect_some_users-tpl.php
File metadata and controls
54 lines (40 loc) · 1.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<?php
use SimpleSAML\Module;
use SimpleSAML\XHTML\Template;
/**
* Template for warn user that he/she is accessing test SP
*
* Allow type hinting in IDE
* @var Template $this
*/
$this->data['header'] = '';
$allowedContinue = $this->data['allowedContinue'];
$redirectURL = $this->data['redirectURL'];
$pageText = $this->data['pageText'];
$this->includeAtTemplateBase('includes/header.php');
?>
<form method="post" action="<?php echo Module::getModuleURL('perun/redirect_some_users_continue.php'); ?>">
<input type="hidden" name="StateId" value="<?php echo $_REQUEST['StateId'] ?>">
<h3> <?php echo $this->t('{perun:perun:redirect_some_users-header}') ?> </h3>
</hr>
</br>
<div> <?php echo $pageText ?> </div>
</hr>
</br>
<?php
if ($allowedContinue) {
echo '<a class="btn btn-lg btn-block btn-primary" style="color:#FFF" target="_blank" href="' .
$redirectURL . '">' . $this->t('{perun:perun:continue}') . '</a>';
echo "</br>";
echo '<div class="form-group">'. $this->t('{perun:perun:continue_to_service}') . '
<input type="submit" value="' . $this->t('{perun:perun:here}') . '"
class="btn btn-sm btn-link">
</div>';
} else {
echo '<a class="btn btn-lg btn-block btn-primary "style="color:#FFF" href="' . $redirectURL . '">' .
$this->t('{perun:perun:continue}') . '</a>';
}
?>
</form>
<?php
$this->includeAtTemplateBase('includes/footer.php');