renommé: fichier/autorise -> m/fichier/autorise
renommé: fichier/conf -> m/fichier/conf renommé: fichier/log -> m/fichier/log renommé: loadConf.py -> m/loadConf.py renommé: login.py -> m/login.py modifié: superTornado.py renommé: illegal.html -> v/illegal.html renommé: images/iut.jpg -> v/images/iut.jpg renommé: index.html -> v/index.html renommé: js/jquery-2.1.0.min.js -> v/js/jquery-2.1.0.min.js renommé: style/styles.css -> v/style/styles.css renommé: video.html -> v/video.html
This commit is contained in:
17
v/illegal.html
Normal file
17
v/illegal.html
Normal file
@ -0,0 +1,17 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf8" />
|
||||
<link rel="stylesheet" type="text/css" href="style/styles.css">
|
||||
<title>Acces camera</title>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Acces securise camera</h2>
|
||||
<form action="/unauthorized" method="post">
|
||||
<p>Forcer l'acces a la camera :</p>
|
||||
Oui : <input type="radio" name="illegalAccess" value=1>
|
||||
Non : <input type="radio" name="illegalAccess" value= 2 checked="checked"> <br/>
|
||||
<input type="submit" value="Valider">
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
BIN
v/images/iut.jpg
Normal file
BIN
v/images/iut.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.1 KiB |
44
v/index.html
Normal file
44
v/index.html
Normal file
@ -0,0 +1,44 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="ISO-8859-1" />
|
||||
<title>Page d'identification</title>
|
||||
<link rel="stylesheet" type="text/css" href="style/styles.css">
|
||||
<script type="text/javascript">
|
||||
// Si aucun login et mot de passe n'ont <20>t<EFBFBD> saisis alors :
|
||||
function checkForm(form) {
|
||||
if(form.j_username.value == "" && form.j_password.value == "") {
|
||||
alert('Veuillez saisir votre login et votre mot de passe svp !')
|
||||
return false;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<!-- Login Logo -->
|
||||
<div id="login-logo">
|
||||
<img src="images/iut.jpg" alt="IUT Logo">
|
||||
</div>
|
||||
<!-- Login Form -->
|
||||
<div id="login-form">
|
||||
<!-- Header -->
|
||||
<h2>Page d'identification</h2>
|
||||
<!-- Form -->
|
||||
<form id="sw-login" method="POST" action="/">
|
||||
<!-- Username -->
|
||||
<div class="field">
|
||||
<label for="username">Identifiant</label>
|
||||
<input id="username" name="id" type="text">
|
||||
</div>
|
||||
<!-- Password -->
|
||||
<div class="field">
|
||||
<label for="password">Mot de passe</label>
|
||||
<input id="password" name="mdp" type="password">
|
||||
</div>
|
||||
<!-- On click on the submit button run the checkFrom function -->
|
||||
<input type="submit" value="Connexion" onclick="return checkForm(form);">
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
4
v/js/jquery-2.1.0.min.js
vendored
Normal file
4
v/js/jquery-2.1.0.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
11
v/style/styles.css
Normal file
11
v/style/styles.css
Normal file
@ -0,0 +1,11 @@
|
||||
*{margin:0;padding:0;}
|
||||
html{font-size:100%;}
|
||||
body{background:#fff;color:#222;font-family:"Helvetica Neue", Arial, Helvetica, sans-serif;text-align:center;font-size:75%;}
|
||||
h2{font-size:2em;margin-bottom:0.75em;}
|
||||
.error{background:#FBE3E4;border:2px solid #FBC2C4;color:#8a1f11;margin-bottom:1em;text-align:center;width:332px;padding:6px;}
|
||||
#login-logo{padding:40px 0;}
|
||||
#login-form{background:#fff;border:1px solid #ccc;text-align:center;width:350px;-moz-border-radius:5px;-webkit-border-radius:5px;-moz-box-shadow:0 1px 3px #ddd;-webkit-box-shadow:0 1px 3px #ddd;margin:0 auto;padding:15px 15px 25px;}
|
||||
#login-form h2{text-align:center;padding:5px 0;}
|
||||
#login-form .field{width:335px;margin:15px 0;}
|
||||
#login-form .field label{color:#777;display:block;font-size:1em;font-weight:700;margin-bottom:5px;text-align:left;}
|
||||
#login-form .field input{border:1px solid #ccc;font-size:1.2em;width:100%;padding:5px;}
|
47
v/video.html
Normal file
47
v/video.html
Normal file
@ -0,0 +1,47 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf8" />
|
||||
<link rel="stylesheet" type="text/css" href="style/styles.css">
|
||||
<title>Acces camera</title>
|
||||
<script src="js/jquery-2.1.0.min.js"></script>
|
||||
<script >
|
||||
var ws = new WebSocket ("ws://192.168.1.23/socket");
|
||||
ws.onmessage = function (evt) {
|
||||
console.log("data receive");
|
||||
if(evt.data != "error") {
|
||||
console.log("data OK !");
|
||||
var str = "<img src='data:image/jpeg;base64,"+evt.data+"'>";
|
||||
}
|
||||
else {
|
||||
console.log("data NOK !");
|
||||
var str = "<p>Erreur : image camera indisponible</p>";
|
||||
}
|
||||
$('.image').html(str);
|
||||
}
|
||||
ws.onopen = function () {
|
||||
console.log("websocket engage");
|
||||
};
|
||||
ws.onclose = function () {
|
||||
console.log("connection closed");
|
||||
};
|
||||
window.onbeforeunload=function(){
|
||||
ws.close();
|
||||
};
|
||||
function refresh() {
|
||||
console.log("Data send");
|
||||
ws.send("lol");
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
</head>
|
||||
<body onload="javascript:setInterval('refresh();',2000)">
|
||||
<h2>Vue camera</h2>
|
||||
<div class="image"></div>
|
||||
<form action="/disconnection" method="post">
|
||||
<input type="submit" value="Deconnexion">
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
|
Reference in New Issue
Block a user