-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdefault-header.php
More file actions
122 lines (105 loc) · 3.85 KB
/
default-header.php
File metadata and controls
122 lines (105 loc) · 3.85 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
<?php // Copyright (c) 2012, SWITCH - Serving Swiss Universities ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title><?php echo getLocalString('title') ?></title>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="keywords" content="Home Organisation, Discovery Service, WAYF, Shibboleth, Login, AAI">
<meta name="description" content="Choose your home organisation to authenticate">
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0;" />
<script type="text/javascript" src="<?php echo $javascriptURL ?>/jquery.js"></script>
<script type="text/javascript" src="<?php echo $javascriptURL ?>/improvedDropDown.js"></script>
<script language="JavaScript" type="text/javascript">
<!--
// Prevent that WAYF is loaded in an IFRAME
function preventIframeEmbedding(){
if (top != self) {
top.location = self.location;
}
}
// Set focus to submit button or drop down list
function setFocus(){
// Skip this if we cannot access the form elements
if (
!document.IdPList ||
!document.IdPList.Select
){
return;
}
if (
document.IdPList.user_idp &&
document.IdPList.user_idp.selectedIndex == 0
){
// Set focus to select
document.IdPList.user_idp.focus();
} else {
// Set focus to submit button
document.IdPList.Select.focus();
}
}
// Confirm action
function showConfirmation(){
return confirm(unescape('<?php echo getLocalString('confirm_permanent_selection', 'js') ?>'));
}
// Confirm permanent selection
function showPermanentConfirmation(){
var message = unescape('<?php echo getLocalString('permanent_cookie_note', 'js') ?>');
message = message.replace('%s', window.location.href.replace(/\?.+/, ''));
return alert(message);
}
// Perform input validation on WAYF form
function checkForm(){
if(
document.IdPList.user_idp &&
document.IdPList.user_idp.selectedIndex == 0
){
alert(unescape('<?php echo getLocalString('make_selection', 'js') ?>'));
return false;
} else {
if (document.IdPList.permanent && document.IdPList.permanent.checked){
return showConfirmation();
} else {
return true;
}
}
}
// Init WAYF
function init(){
preventIframeEmbedding();
setFocus();
if (<?php echo ($useImprovedDropDownList) ? 'true' : 'false' ?>){
var searchText = '<?php echo getLocalString('search_idp', 'js') ?>';
$("#userIdPSelection:enabled option[value='-']").text(searchText);
// Convert select element into improved drop down list
$("#userIdPSelection:enabled").improveDropDown({
iconPath:'<?php echo $imageURL ?>/drop_icon.png',
noMatchesText: '<?php echo getLocalString('no_idp_found', 'js') ?>',
noItemsText: '<?php echo getLocalString('no_idp_available', 'js') ?>'
});
}
}
// Call init function when DOM is ready
$(document).ready(init);
-->
</script>
<style type="text/css">
<!--
<?php printCSS() ?>
-->
</style>
</head>
<body>
<div id="container">
<div class="box">
<div id="header">
<a href="http://www.switch.ch/aai"><img src="<?php echo $logoURL ?>" alt="SWITCHaai" id="federationLogo"></a>
<a href="http://www.switch.ch/"><img src="<?php echo $imageURL ?>/switch-logo.png" alt="SWITCH" id="organisationLogo"></a>
</div>
<div id="content">
<ul class="menu">
<li><a href="http://www.switch.ch/<?php echo $language ?>/aai/about/"><?php echo getLocalString('about_federation'); ?></a></li>
<li class="last"><a href="http://www.switch.ch/<?php echo $language ?>/aai/faq/"><?php echo getLocalString('faq') ?></a></li>
<li class="last"><a href="http://www.switch.ch/<?php echo $language ?>/aai/help/"><?php echo getLocalString('help') ?></a></li>
<li class="last"><a href="http://www.switch.ch/<?php echo $language ?>/aai/privacy/"><?php echo getLocalString('privacy') ?></a></li>
</ul>
<!-- Body: Start -->