Subversion Repositories ALCASAR

Rev

Rev 537 | Rev 725 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 537 Rev 640
1
<?php
1
<?php
2
#
2
#
3
# status.php for Alcasar captive portal
3
# status.php for Alcasar captive portal
4
# by steweb57
4
# by steweb57
5
# 
5
# 
6
$organisme = "steweb57";
6
$organisme = "";
7
 
7
 
8
# Choice of language
8
# Choice of language
9
//reste quelques traductions à faire
9
//reste quelques traductions à faire
10
$Language = 'en';
10
$Language = 'en';
11
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){
11
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){
12
  $Langue = explode(",",$_SERVER['HTTP_ACCEPT_LANGUAGE']);
12
  $Langue = explode(",",$_SERVER['HTTP_ACCEPT_LANGUAGE']);
13
  $Language = strtolower(substr(chop($Langue[0]),0,2)); }
13
  $Language = strtolower(substr(chop($Langue[0]),0,2)); }
14
if($Language == 'es'){
14
if($Language == 'es'){
15
	$l_login1			= "El éxito de la autenticación.";
15
	$l_login1			= "El éxito de la autenticación.";
16
	$l_login2			= "Cierre esta ventana interrumpte la sesion.";
16
	$l_login2			= "Cierre esta ventana interrumpte la sesion.";
17
	$l_logout			= "Conexión de cierre";
17
	$l_logout			= "Conexión de cierre";
18
	$l_logout_question	= "Are you sure you want to disconnect now?";	//à traduire
18
	$l_logout_question	= "Are you sure you want to disconnect now?";	//à traduire
19
	$l_loggedout		= "Su sesión se cierra";
19
	$l_loggedout		= "Su sesión se cierra";
20
	$l_wait				= "Por favor, espere un momento ...";
20
	$l_wait				= "Por favor, espere un momento ...";
21
	$l_state_label				= "State";		//à traduire
21
	$l_state_label				= "State";		//à traduire
22
	$l_session_id_label			= "Session ID";	//à traduire
22
	$l_session_id_label			= "Session ID";	//à traduire
23
	$l_max_session_time_label	= "Max Session Time";	//à traduire
23
	$l_max_session_time_label	= "Max Session Time";	//à traduire
24
	$l_max_idle_time_label		= "Max Idle Time";		//à traduire
24
	$l_max_idle_time_label		= "Max Idle Time";		//à traduire
25
	$l_start_time_label			= "Start Time";	//à traduire
25
	$l_start_time_label			= "Start Time";	//à traduire
26
	$l_session_time_label		= "Tiempo de conexión";
26
	$l_session_time_label		= "Tiempo de conexión";
27
	$l_idle_time_label			= "Idle Time";	//à traduire
27
	$l_idle_time_label			= "Idle Time";	//à traduire
28
	$l_downloaded_label			= "Downloaded";	//à traduire
28
	$l_downloaded_label			= "Downloaded";	//à traduire
29
	$l_uploaded_label			= "Uploaded";	//à traduire
29
	$l_uploaded_label			= "Uploaded";	//à traduire
30
	$l_original_url_label		= "Original URL";	//à traduire
30
	$l_original_url_label		= "Original URL";	//à traduire
31
	$l_not_available			= "Not available";	//à traduire
31
	$l_not_available			= "Not available";	//à traduire
32
	$l_na						= "N/A";		//à traduire
32
	$l_na						= "N/A";		//à traduire
33
	$l_error					= "error";		//à traduire
33
	$l_error					= "error";		//à traduire
34
	$l_welcome					= "Welcome";	//à traduire
34
	$l_welcome					= "Welcome";	//à traduire
35
}
35
}
36
else if($Language == 'de'){
36
else if($Language == 'de'){
37
	$l_login1			= "Erfolgreiche Authentifizierung.";
37
	$l_login1			= "Erfolgreiche Authentifizierung.";
38
	$l_login2			= "Schlißen dieses fensters unterbricht die sitzung";
38
	$l_login2			= "Schlißen dieses fensters unterbricht die sitzung";
39
	$l_logout			= "Beenden der Verbindung";
39
	$l_logout			= "Beenden der Verbindung";
40
	$l_logout_question	= "Are you sure you want to disconnect now?";	//à traduire
40
	$l_logout_question	= "Are you sure you want to disconnect now?";	//à traduire
41
	$l_loggedout		= "Ihre Sitzung ist geschlossen";
41
	$l_loggedout		= "Ihre Sitzung ist geschlossen";
42
	$l_wait				= "Bitte warten Sie einen Moment ...";
42
	$l_wait				= "Bitte warten Sie einen Moment ...";
43
	$l_state_label				= "State";		//à traduire
43
	$l_state_label				= "State";		//à traduire
44
	$l_session_id_label			= "Session ID";	//à traduire
44
	$l_session_id_label			= "Session ID";	//à traduire
45
	$l_max_session_time_label	= "Max Session Time";	//à traduire
45
	$l_max_session_time_label	= "Max Session Time";	//à traduire
46
	$l_max_idle_time_label		= "Max Idle Time";		//à traduire
46
	$l_max_idle_time_label		= "Max Idle Time";		//à traduire
47
	$l_start_time_label			= "Start Time";	//à traduire
47
	$l_start_time_label			= "Start Time";	//à traduire
48
	$l_session_time_label		= "Online-zeit";
48
	$l_session_time_label		= "Online-zeit";
49
	$l_idle_time_label			= "Idle Time";	//à traduire
49
	$l_idle_time_label			= "Idle Time";	//à traduire
50
	$l_downloaded_label			= "Downloaded";	//à traduire
50
	$l_downloaded_label			= "Downloaded";	//à traduire
51
	$l_uploaded_label			= "Uploaded";	//à traduire
51
	$l_uploaded_label			= "Uploaded";	//à traduire
52
	$l_original_url_label		= "Original URL";	//à traduire
52
	$l_original_url_label		= "Original URL";	//à traduire
53
	$l_not_available			= "Not available";	//à traduire
53
	$l_not_available			= "Not available";	//à traduire
54
	$l_na						= "N/A";		//à traduire
54
	$l_na						= "N/A";		//à traduire
55
	$l_error					= "error";		//à traduire
55
	$l_error					= "error";		//à traduire
56
	$l_welcome					= "Welcome"; 	//à traduire
56
	$l_welcome					= "Welcome"; 	//à traduire
57
}
57
}
58
else if($Language == 'nl'){
58
else if($Language == 'nl'){
59
	$l_login1			= "Succesvolle authenticatie.";
59
	$l_login1			= "Succesvolle authenticatie.";
60
	$l_login2			= "Dit venster te sluiten onderbreekt uw sessie.";
60
	$l_login2			= "Dit venster te sluiten onderbreekt uw sessie.";
61
	$l_logout			= "Slotkoers verbinding";
61
	$l_logout			= "Slotkoers verbinding";
62
	$l_logout_question	= "Are you sure you want to disconnect now?";	//à traduire
62
	$l_logout_question	= "Are you sure you want to disconnect now?";	//à traduire
63
	$l_loggedout		= "Uw sessie is gesloten";
63
	$l_loggedout		= "Uw sessie is gesloten";
64
	$l_wait				= "Wacht een moment ...";
64
	$l_wait				= "Wacht een moment ...";
65
	$l_state_label				= "State";		//à traduire
65
	$l_state_label				= "State";		//à traduire
66
	$l_session_id_label			= "Session ID";	//à traduire
66
	$l_session_id_label			= "Session ID";	//à traduire
67
	$l_max_session_time_label	= "Max Session Time";	//à traduire
67
	$l_max_session_time_label	= "Max Session Time";	//à traduire
68
	$l_max_idle_time_label		= "Max Idle Time";		//à traduire
68
	$l_max_idle_time_label		= "Max Idle Time";		//à traduire
69
	$l_start_time_label			= "Start Time";	//à traduire
69
	$l_start_time_label			= "Start Time";	//à traduire
70
	$l_session_time_label		= "Online tijd";
70
	$l_session_time_label		= "Online tijd";
71
	$l_idle_time_label			= "Idle Time";	//à traduire
71
	$l_idle_time_label			= "Idle Time";	//à traduire
72
	$l_downloaded_label			= "Downloaded";	//à traduire
72
	$l_downloaded_label			= "Downloaded";	//à traduire
73
	$l_uploaded_label			= "Uploaded";	//à traduire
73
	$l_uploaded_label			= "Uploaded";	//à traduire
74
	$l_original_url_label		= "Original URL";	//à traduire
74
	$l_original_url_label		= "Original URL";	//à traduire
75
	$l_not_available			= "Not available";	//à traduire
75
	$l_not_available			= "Not available";	//à traduire
76
	$l_na						= "N/A";		//à traduire
76
	$l_na						= "N/A";		//à traduire
77
	$l_error					= "error";		//à traduire
77
	$l_error					= "error";		//à traduire
78
	$l_welcome					= "Welcome";	//à traduire
78
	$l_welcome					= "Welcome";	//à traduire
79
}
79
}
80
else if($Language == 'fr'){
80
else if($Language == 'fr'){
81
	$l_login1			= "Authentification r&eacute;ussie.";
81
	$l_login1			= "Authentification r&eacute;ussie.";
82
	$l_login2			= "La fermeture de cette fenêtre interrompt votre session.";
82
	$l_login2			= "La fermeture de cette fenêtre interrompt votre session.";
83
	$l_logout			= "Fermeture de la session";
83
	$l_logout			= "Fermeture de la session";
84
	$l_logout_question	= "Etes vous sûr de vouloir vous déconnecter?";
84
	$l_logout_question	= "Etes vous sûr de vouloir vous déconnecter?";
85
	$l_loggedout		= "Votre session est fermée";
85
	$l_loggedout		= "Votre session est fermée";
86
	$l_wait				= "Patientez un instant ....";
86
	$l_wait				= "Patientez un instant ....";
87
	$l_state_label				= "Etat";
87
	$l_state_label				= "Etat";
88
	$l_session_id_label			= "Session ID";
88
	$l_session_id_label			= "Session ID";
89
	$l_max_session_time_label	= "Temps de connexion autoris&eacute";
89
	$l_max_session_time_label	= "Temps de connexion autoris&eacute";
90
	$l_max_idle_time_label		= "Inactivit&eacute; max. autoris&eacute;e";
90
	$l_max_idle_time_label		= "Inactivit&eacute; max. autoris&eacute;e";
91
	$l_start_time_label			= "D&eacute;but de connexion";
91
	$l_start_time_label			= "D&eacute;but de connexion";
92
	$l_session_time_label		= "Dur&eacute;e de connexion";
92
	$l_session_time_label		= "Dur&eacute;e de connexion";
93
	$l_idle_time_label			= "Inactivit&eacute;";
93
	$l_idle_time_label			= "Inactivit&eacute;";
94
	$l_downloaded_label			= "Donn&eacute;es t&eacute;l&eacute;charg&eacute;es";
94
	$l_downloaded_label			= "Donn&eacute;es t&eacute;l&eacute;charg&eacute;es";
95
	$l_uploaded_label			= "Donn&eacute;es envoy&eacute;es";
95
	$l_uploaded_label			= "Donn&eacute;es envoy&eacute;es";
96
	$l_original_url_label		= "URL demand&eacute;e";
96
	$l_original_url_label		= "URL demand&eacute;e";
97
	$l_not_available			= "Non disponible";
97
	$l_not_available			= "Non disponible";
98
	$l_na						= "N/D";	//à traduire
98
	$l_na						= "N/D";	//à traduire
99
	$l_error					= "erreur";
99
	$l_error					= "erreur";
100
	$l_welcome					= "Bienvenue";
100
	$l_welcome					= "Bienvenue";
101
}
101
}
102
else {
102
else {
103
	$l_login1			= "Successful authentication.";
103
	$l_login1			= "Successful authentication.";
104
	$l_login2			= "Closing this window interrupts your session.";
104
	$l_login2			= "Closing this window interrupts your session.";
105
	$l_logout			= "Closing connection";
105
	$l_logout			= "Closing connection";
106
	$l_logout_question	= "Are you sure you want to disconnect now?";
106
	$l_logout_question	= "Are you sure you want to disconnect now?";
107
	$l_loggedout		= "Your session is closed";
107
	$l_loggedout		= "Your session is closed";
108
	$l_wait				= "Please wait a moment ...";
108
	$l_wait				= "Please wait a moment ...";
109
	$l_state_label				= "State";
109
	$l_state_label				= "State";
110
	$l_session_id_label			= "Session ID";
110
	$l_session_id_label			= "Session ID";
111
	$l_max_session_time_label	= "Max Session Time";
111
	$l_max_session_time_label	= "Max Session Time";
112
	$l_max_idle_time_label		= "Max Idle Time";
112
	$l_max_idle_time_label		= "Max Idle Time";
113
	$l_start_time_label			= "Start Time";
113
	$l_start_time_label			= "Start Time";
114
	$l_session_time_label		= "Session Time";
114
	$l_session_time_label		= "Session Time";
115
	$l_idle_time_label			= "Idle Time";
115
	$l_idle_time_label			= "Idle Time";
116
	$l_downloaded_label			= "Downloaded";
116
	$l_downloaded_label			= "Downloaded";
117
	$l_uploaded_label			= "Uploaded";
117
	$l_uploaded_label			= "Uploaded";
118
	$l_original_url_label		= "Original URL";
118
	$l_original_url_label		= "Original URL";
119
	$l_not_available			= "Not available";
119
	$l_not_available			= "Not available";
120
	$l_na						= "N/A";
120
	$l_na						= "N/A";
121
	$l_error					= "error";
121
	$l_error					= "error";
122
	$l_welcome					= "Welcome";
122
	$l_welcome					= "Welcome";
123
}
123
}
124
?>
124
?>
125
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
125
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
126
<html lang="fr">
126
<html lang="fr">
127
<!-- written by steweb57 -->
127
<!-- written by steweb57 -->
128
<head>
128
<head>
129
<title>Alcasar - <?php echo $organisme; ?></title>
129
<title>Alcasar - <?php echo $organisme; ?></title>
130
<meta http-equiv="Cache-control" content="no-cache">
130
<meta http-equiv="Cache-control" content="no-cache">
131
<meta http-equiv="Pragma" content="no-cache">
131
<meta http-equiv="Pragma" content="no-cache">
132
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
132
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
133
<script type="text/javascript" src="./js/ChilliLibrary.js"></script>
133
<script type="text/javascript" src="./js/ChilliLibrary.js"></script>
134
<script type="text/javascript" src="./js/statusControler.js"></script>
134
<script type="text/javascript" src="./js/statusControler.js"></script>
135
<link type="text/css" href="./css/status.css" rel="stylesheet">
135
<link type="text/css" href="./css/status.css" rel="stylesheet">
136
</head>
136
</head>
137
<body>
137
<body>
138
<div id="Chilli">
138
<div id="Chilli">
139
<div id="locationName"></div>
139
<div id="locationName"></div>
140
<div id="chilliPage">
140
<div id="chilliPage">
141
<div id="loggedOutPage" class="c1">
141
<div id="loggedOutPage" class="c1">
142
<table id="disconnectTable">
142
<table id="disconnectTable">
143
<tr>
143
<tr>
144
<td><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
144
<td><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
145
<td>
145
<td>
146
<p class="text_auth"><?php echo $l_loggedout; ?></p>
146
<p class="text_auth"><?php echo $l_loggedout; ?></p>
147
</td>
147
</td>
148
</tr>
148
</tr>
149
</table>
149
</table>
150
</div>
150
</div>
151
<div id="statusPage" class="c1">
151
<div id="statusPage" class="c1">
152
<table border="0" id="statusTable">
152
<table border="0" id="statusTable">
153
<tr>
153
<tr>
154
<td rowspan="2" valign="top"><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
154
<td rowspan="2" valign="top"><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
155
<td>
155
<td>
156
<p class="text_auth"><?php echo $l_welcome; ?> <span id="userName"></span>.</p>
156
<p class="text_auth"><?php echo $l_welcome; ?> <span id="userName"></span>.</p>
157
<p class="text_auth"><?php echo $l_login1; ?></p>
157
<p class="text_auth"><?php echo $l_login1; ?></p>
158
<hr>
158
<hr>
159
<?php echo $l_login2; ?></td>
159
<?php echo $l_login2; ?></td>
160
</tr>
160
</tr>
161
<tr>
161
<tr>
162
<td align="center"><br>
162
<td align="center"><br>
163
<a href="#" onclick="return logoutWithConfirmation('<?php echo $l_logout_question;?>');" class="lien_deco"><?php echo $l_logout; ?></a><br>
163
<a href="#" onclick="return logoutWithConfirmation('<?php echo $l_logout_question;?>');" class="lien_deco"><?php echo $l_logout; ?></a><br>
164
<br></td>
164
<br></td>
165
</tr>
165
</tr>
166
<!--tr id="connectRow">
166
<!--tr id="connectRow">
167
<td id="statusMessageLabel" class="chilliLabel"><strong><?php echo $l_state_label; ?></strong></td>
167
<td id="statusMessageLabel" class="chilliLabel"><strong><?php echo $l_state_label; ?></strong></td>
168
<td id="statusMessage" class="chilliValue">Connected</td>
168
<td id="statusMessage" class="chilliValue">Connected</td>
169
</tr-->
169
</tr-->
170
<!--tr id="sessionIdRow">
170
<!--tr id="sessionIdRow">
171
<td id="sessionIdLabel" class="chilliLabel"><strong><?php echo $l_session_id_label; ?></strong></td>
171
<td id="sessionIdLabel" class="chilliLabel"><strong><?php echo $l_session_id_label; ?></strong></td>
172
<td id="sessionId" class="chilliValue"><?php echo $l_not_available; ?></td>
172
<td id="sessionId" class="chilliValue"><?php echo $l_not_available; ?></td>
173
</tr-->
173
</tr-->
174
<tr id="sessionTimeoutRow">
174
<tr id="sessionTimeoutRow">
175
<td id="sessionTimeoutLabel" class="chilliLabel"><strong><?php echo $l_max_session_time_label; ?></strong></td>
175
<td id="sessionTimeoutLabel" class="chilliLabel"><strong><?php echo $l_max_session_time_label; ?></strong></td>
176
<td id="sessionTimeout" class="chilliValue"><?php echo $l_not_available; ?></td>
176
<td id="sessionTimeout" class="chilliValue"><?php echo $l_not_available; ?></td>
177
</tr>
177
</tr>
178
<tr id="idleTimeoutRow">
178
<tr id="idleTimeoutRow">
179
<td id="idleTimeoutLabel" class="chilliLabel"><strong><?php echo $l_max_idle_time_label; ?></strong></td>
179
<td id="idleTimeoutLabel" class="chilliLabel"><strong><?php echo $l_max_idle_time_label; ?></strong></td>
180
<td id="idleTimeout" class="chilliValue"><?php echo $l_not_available; ?></td>
180
<td id="idleTimeout" class="chilliValue"><?php echo $l_not_available; ?></td>
181
</tr>
181
</tr>
182
<tr id="startTimeRow">
182
<tr id="startTimeRow">
183
<td id="startTimeLabel" class="chilliLabel"><strong><?php echo $l_start_time_label; ?></strong></td>
183
<td id="startTimeLabel" class="chilliLabel"><strong><?php echo $l_start_time_label; ?></strong></td>
184
<td id="startTime" class="chilliValue"><?php echo $l_not_available; ?></td>
184
<td id="startTime" class="chilliValue"><?php echo $l_not_available; ?></td>
185
</tr>
185
</tr>
186
<tr id="sessionTimeRow">
186
<tr id="sessionTimeRow">
187
<td id="sessionTimeLabel" class="chilliLabel"><strong><?php echo $l_session_time_label; ?></strong></td>
187
<td id="sessionTimeLabel" class="chilliLabel"><strong><?php echo $l_session_time_label; ?></strong></td>
188
<td id="sessionTime" class="chilliValue"><?php echo $l_not_available; ?></td>
188
<td id="sessionTime" class="chilliValue"><?php echo $l_not_available; ?></td>
189
</tr>
189
</tr>
190
<tr id="idleTimeRow">
190
<tr id="idleTimeRow">
191
<td id="idleTimeLabel" class="chilliLabel"><strong><?php echo $l_idle_time_label; ?></strong></td>
191
<td id="idleTimeLabel" class="chilliLabel"><strong><?php echo $l_idle_time_label; ?></strong></td>
192
<td id="idleTime" class="chilliValue"><?php echo $l_not_available; ?></td>
192
<td id="idleTime" class="chilliValue"><?php echo $l_not_available; ?></td>
193
</tr>
193
</tr>
194
<tr id="inputOctetsRow">
194
<tr id="inputOctetsRow">
195
<td id="inputOctetsLabel" class="chilliLabel"><strong><?php echo $l_downloaded_label; ?></strong></td>
195
<td id="inputOctetsLabel" class="chilliLabel"><strong><?php echo $l_downloaded_label; ?></strong></td>
196
<td id="inputOctets" class="chilliValue"><?php echo $l_na; ?></td>
196
<td id="inputOctets" class="chilliValue"><?php echo $l_na; ?></td>
197
</tr>
197
</tr>
198
<tr id="outputOctetsRow">
198
<tr id="outputOctetsRow">
199
<td id="outputOctetsLabel" class="chilliLabel"><strong><?php echo $l_uploaded_label; ?></strong></td>
199
<td id="outputOctetsLabel" class="chilliLabel"><strong><?php echo $l_uploaded_label; ?></strong></td>
200
<td id="outputOctets" class="chilliValue"><?php echo $l_na; ?></td>
200
<td id="outputOctets" class="chilliValue"><?php echo $l_na; ?></td>
201
</tr>
201
</tr>
202
<tr id="originalURLRow">
202
<tr id="originalURLRow">
203
<td id="originalURLLabel" class="chilliLabel"><strong><?php echo $l_original_url_label; ?></strong></td>
203
<td id="originalURLLabel" class="chilliLabel"><strong><?php echo $l_original_url_label; ?></strong></td>
204
<td id="originalURL" class="chilliValue"><?php echo $l_na; ?></td>
204
<td id="originalURL" class="chilliValue"><?php echo $l_na; ?></td>
205
</tr>
205
</tr>
206
</table>
206
</table>
207
</div>
207
</div>
208
<div id="waitPage">
208
<div id="waitPage">
209
<table id="waitTable">
209
<table id="waitTable">
210
<tr>
210
<tr>
211
<td><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
211
<td><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
212
<td>
212
<td>
213
<p class="text_auth"><img src="./images/wait.gif" width="16" height="16" class="wait" alt="<?php echo $l_wait; ?>"><?php echo $l_wait; ?></p>
213
<p class="text_auth"><img src="./images/wait.gif" width="16" height="16" class="wait" alt="<?php echo $l_wait; ?>"><?php echo $l_wait; ?></p>
214
</td>
214
</td>
215
</tr>
215
</tr>
216
</table>
216
</table>
217
</div>
217
</div>
218
<div id="errorPage">
218
<div id="errorPage">
219
<table id="errorTable">
219
<table id="errorTable">
220
<tr>
220
<tr>
221
<td><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
221
<td><img height="150" src="./images/logo-alcasar.png" alt="logo"></td>
222
<td><span id="errorMessage"><?php echo $l_error; ?></span></td>
222
<td><span id="errorMessage"><?php echo $l_error; ?></span></td>
223
</tr>
223
</tr>
224
</table>
224
</table>
225
</div>
225
</div>
226
</div>
226
</div>
227
<!--div id="debugPage" style="display:inline;">
227
<!--div id="debugPage" style="display:inline;">
228
<textarea id="debugarea" rows="20" cols="60">
228
<textarea id="debugarea" rows="20" cols="60">
229
</textarea>
229
</textarea>
230
</div--></div>
230
</div--></div>
231
</body>
231
</body>
232
</html>
232
</html>
233
 
233