-
Notifications
You must be signed in to change notification settings - Fork 1
/
issue-en.php
63 lines (57 loc) · 2.18 KB
/
issue-en.php
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
55
56
57
58
59
60
61
62
63
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link href="../css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<script type="application/javascript">
let irma_server_url = "<?= IRMA_SERVER_URL ?>";
let lang = "<?= LANG ?>";
</script>
<script type="text/javascript" src="../js/jquery.min.js"></script>
<script type="text/javascript" src="../js/yivi.js"></script>
<script type="text/javascript" src="../js/enroll.js"></script>
<title><?= PROVIDER_NAME ?> attributes</title>
</head>
<body>
<div class="container">
<div class="row">
<div class="col-xs-12 col-md-8 col-lg-6 col-md-offset-2 col-lg-offset-3">
<h2>Available <?= PROVIDER_NAME ?> attributes</h2>
<div id="warning" class="alert alert-warning hide" role="alert">
<strong>Cancelled</strong><br/>
<small class="message"></small>
</div>
<div id="error" class="alert alert-danger hide" role="alert">
<strong>Error</strong>: cannot issue credential.<br/>
<small class="message"></small>
</div>
<?php if (!$irma_attributes || count($irma_attributes) === 0) { ?>
<div id="no-attributes" class="alert alert-danger" role="alert">
<strong>Error</strong>: cannot issue credential.<br/>
<small class="message">Issuance was aborted because no attributes were received.</small>
</div>
<?php } else { ?>
<p>The attributes below can be added to your IRMA app:</p>
<table class="table">
<?php foreach ($irma_attributes as $key => $value) { ?>
<tr>
<th scope="row"><?= $ATTRIBUTE_HUMAN_NAMES[$key] ?></th>
<?php if ($key == 'profileurl') { ?>
<td><a href="<?= $value ?>"><?= $value ?></a></td>
<?php } else { ?>
<td><?= htmlspecialchars($value, ENT_QUOTES|ENT_HTML5) ?></td>
<?php } ?>
</tr>
<?php } ?>
</table>
<p>Click here to add this attributes to your IRMA app.</p>
<button id="enroll" class="btn btn-primary">Load attributes in IRMA app</button>
<hr />
<small>You are logged in as <?= $irma_attributes['firstname'] ?> (<a href="?action=logout">Log out</a>)</small>
<?php } ?>
</div>
</div>
</div>
</body>
</html>