summaryrefslogtreecommitdiff
path: root/src/main/webapp/wayf-ndn.jsp
blob: cbd0b738fdeee4f2d850609c391010a9d5fa65fa (plain)
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
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<%@ page contentType="text/html;charset=UTF-8" %> 
<html>

<%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>

<%request.setCharacterEncoding("UTF-8");%>
<%response.setCharacterEncoding("UTF-8");%>

<jsp:useBean id="requestURL" scope="request" class="java.lang.String"/>
<logic:notPresent name="entityID" scope="request">
<logic:notPresent name="shire" scope="request">
<jsp:forward page = "wayferror.jsp"/>
</logic:notPresent>
</logic:notPresent>

<head>
    <link rel="stylesheet" type="text/css" href="NORDUnet.css"/>
    <link type="text/css" href="jquery-ui-1.9pre/themes/base/jquery-ui.css" rel="stylesheet" />
    <script type="text/javascript" src="jquery-1.7.1.js"></script>
    <script type="text/javascript" src="jquery-ui-1.9pre/ui/jquery-ui.js"></script>
    <script type="text/javascript" src="jquery.searchabledropdown-1.0.7.min.js"></script>
    <title>Identity Provider Selection</title>
    <script type="text/javascript">
		$(function() {
				   $("input:submit, input:reset, input:button, a",".button").button();
				   $(".sitelist").menu();
                   $("#origin").searchable();
		});
    </script>
</head>
	
<body id="homepage">
    <div id="wrapper">
       <div id="top">
          <table id="top_table">
             <tr>
                <td><img src="<%= request.getContextPath() %>/images/NORDUnet2.jpg" width="203" height="46" alt="" /></td>
             </tr>
          </table>
       </div>
       <div id="container">
       	<ul class="ilist">
	       <li style="vertical-align: top;">
	          <div id="nav">
	             <ul class="site_tree">
	                <li class="level1"><strong class="level1">Resources</strong>
	                   <ul>
	                      <li class="level2"><a class="level2" href="http://www.nordu.net">NORDUnet Home</a></li>
	                      <li class="level2"><a class="level2" href="http://www.nordu.net#aup">Acceptable Use Policy</a></li>
	                      <li class="level2"><a class="level2" href="http://www.nordu.net#pii">Privacy Policy</a></li>
	                   </ul>
	                </li>
	             </ul>
	             <div id="nav_pic"><img src="images/pipes.jpg" width="200px" height="395" alt="" /></div>
	          </div>
	       </li>
	       <li style="vertical-align: top; padding-left: 20px;">
	       	<h1>Select an identity provider</h1>
	        <p class="text">The service you are trying to use require that you identify yourself. Please select your identity provider below...</p>
        	<logic:present name="cookieList" scope="request">
			  <h2>Recently Used</h2>
			  <ul class="sitelist">
			  	<logic:iterate id="site" name="cookieList">
			  	  <logic:present name="entityID" scope="request">
		                  <bean:define id="returnIDParam" name="returnIDParam"/>
		                  <bean:define id="ei" name="entityID" />
		                  <bean:define id="re" name="returnX"/>
		
		                 <li><a tabindex="10" href="<bean:write name="requestURL" />?entityID=<%= java.net.URLEncoder.encode(ei.toString(), "utf-8") %>&return=<%= java.net.URLEncoder.encode(re.toString(), "utf-8") %>&returnIDxParam=<%= java.net.URLEncoder.encode( returnIDParam.toString(), "utf-8" ) %>&cache=perm&action=selection&origin=<jsp:getProperty name="site" property="name" />">
		                    <jsp:getProperty name="site" property="displayName" />
		                 </a></li>
		              </logic:present>
		              <logic:notPresent name="entityID" scope="request">
		                <bean:define id="targ" name="target" />
		                <bean:define id="shire" name="shire" />
		                <bean:define id="pid" name="providerId" />
		                <li><a tabindex="10" href="<bean:write name="requestURL" />?target=<%= java.net.URLEncoder.encode(targ.toString(),"utf-8") %>&shire=<%= java.net.URLEncoder.encode(shire.toString(),"utf-8") %>&providerId=<%= java.net.URLEncoder.encode(pid.toString(),"utf-8") %>&time=<bean:write name="time" />&cache=perm&action=selection&origin=<jsp:getProperty name="site" property="name" />">
		                    <jsp:getProperty name="site"
		                    property="displayName" />
		                </a></li>
		              </logic:notPresent>
			    </logic:iterate>
		      </ul>
		      <form method="get" action="ClearCache.wayf" >
		          <logic:notPresent name="entityID" scope="request">
		            <input type="hidden" name="shire" value="<bean:write name="shire" />" />
		            <input type="hidden" name="target" value="<bean:write name="target" />" />
		            <input type="hidden" name="providerId" value="<bean:write name="providerId" />" />
		            <logic:present name="time" scope="request">
		               <input type="hidden" name="time" value="<bean:write name="time" />" />
		            </logic:present>
		          </logic:notPresent>
		          <logic:present name="entityID" scope="request">
		            <input type="hidden" name="entityID" value="<bean:write name="entityID" />" />
		            <input type="hidden" name="returnX" value="<bean:write name="returnX" />" />
		            <input type="hidden" name="returnIDParam" value="<bean:write name="returnIDParam" />" />
		          </logic:present>
		          <input tabindex="20" type="submit" value="Clear List" />
		      </form>
        	</logic:present>
       		<h2>Full list of identity providers</h2>
            <logic:present name="sites" scope="request">  
                  <form style="margin-bottom: 10px;" method="get" action="<bean:write name="requestURL" />">
	              <span>
	                <logic:notPresent name="entityID" scope="request">
	                    <input type="hidden" name="shire" value="<bean:write name="shire" />" />
	                    <input type="hidden" name="target" value="<bean:write name="target" />" />
	                    <input type="hidden" name="providerId" value="<bean:write name="providerId" />" />
	                    <logic:present name="time" scope="request">
	                         <input type="hidden" name="time" value="<bean:write name="time" />" />
	                    </logic:present>
	                </logic:notPresent>
	                <logic:present name="entityID" scope="request">
	                    <input type="hidden" name="entityID" value="<bean:write name="entityID" />" />
	                    <input type="hidden" name="returnX" value="<bean:write name="returnX" />" />
	                    <input type="hidden" name="returnIDParam" value="<bean:write name="returnIDParam" />" />
	                 </logic:present>
	                 <input type="hidden" name="action" value="selection" />
	                 <select name="origin" onSelect="this.form.submit();" id="origin" tabindex="40">
	                     <logic:iterate id="site" name="sites">
	                         <option value="<jsp:getProperty name="site" property="name" />">
	                             <jsp:getProperty name="site" property="displayName" />
	                         </option>
	                     </logic:iterate>
	                 </select>
                         <input type="hidden" name="cache" value="perm" />
                         <!-- input type="submit" class="button" id="originsubmit" value="Select" tabindex="50" / -->
	              </div>
	           </span>   
	       </logic:present> 		
	      </li>
	    </ul>
	  </div>
      <div id="footer" style="margin-top: 15px">
        <p>NORDUnet A/S | Kastruplundgade 22 | DK-2770 Kastrup | DENMARK | Phone +45 32 46 25 00 | Fax +45 45 76 23 66 | info@nordu.net</p>
      </div>
  </div>  
</body>
</html>