|
5 | 5 | use SimpleSAML\XHTML\Template; |
6 | 6 |
|
7 | 7 | /** |
8 | | - * Template for inform user that he/she will be redirected to registration |
9 | | - * |
10 | | - * Allow type hinting in IDE |
| 8 | + * Template displaying information user that user will be redirected to registration page |
11 | 9 | * |
12 | 10 | * @var Template $this |
13 | 11 | */ |
|
16 | 14 | $this->data['head'] = '<link rel="stylesheet" media="screen" type="text/css" href="' . |
17 | 15 | Module::getModuleUrl('perun/res/css/perun_identity_go_to_registration.css') . '" />'; |
18 | 16 |
|
| 17 | +$params = $this->data['params']; |
| 18 | +if (isset($_POST['continueToRegistration'])) { |
| 19 | + HTTP::redirectTrustedURL($_REQUEST['registerUrL'], $params); |
| 20 | +} |
19 | 21 | $spMetadata = $this->data['SPMetadata']; |
| 22 | + |
20 | 23 | $serviceName = ''; |
21 | | -$informationURL = ''; |
22 | | -$params = $this->data['params']; |
23 | | -if ($spMetadata['name']['en']) { |
| 24 | +if (isset($spMetadata['name']['en'])) { |
24 | 25 | $serviceName = $spMetadata['name']['en']; |
25 | 26 | } |
26 | 27 |
|
27 | | -if ($spMetadata['InformationURL']['en']) { |
| 28 | +$informationURL = ''; |
| 29 | +if (isset($spMetadata['InformationURL']['en'])) { |
28 | 30 | $informationURL = $spMetadata['InformationURL']['en']; |
29 | 31 | } |
30 | 32 |
|
31 | | -if (isset($_POST['continueToRegistration'])) { |
32 | | - HTTP::redirectTrustedURL($_REQUEST['registerUrL'], $params); |
33 | | -} |
34 | | - |
35 | 33 | $this->includeAtTemplateBase('includes/header.php'); |
36 | 34 |
|
37 | 35 | $header = $this->t('{perun:perun:go-to-registration_header1}'); |
|
49 | 47 | ?> |
50 | 48 |
|
51 | 49 | <form method="post"> |
52 | | - </hr> |
53 | | - </br> |
| 50 | + <hr/> |
| 51 | + <br/> |
54 | 52 | <input type="submit" name="continueToRegistration" |
55 | 53 | value="<?php echo $this->t('{perun:perun:go-to-registration_continue}') ?>" |
56 | 54 | class="btn btn-lg btn-primary btn-block"> |
57 | | - <div class="form-group"> |
58 | | - </div> |
| 55 | + <div class="form-group"></div> |
59 | 56 | </form> |
60 | 57 |
|
61 | 58 | <?php |
|
0 commit comments