2014-02-28 00:13:54 +00:00
|
|
|
<!DOCTYPE HTML>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<meta charset="utf8" />
|
|
|
|
<link rel="stylesheet" type="text/css" href="style/styles.css">
|
|
|
|
<title>Acces camera</title>
|
2014-02-28 01:34:08 +00:00
|
|
|
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
|
2014-02-28 01:12:24 +00:00
|
|
|
<script type="text/javascript" >
|
|
|
|
|
2014-02-28 02:36:53 +00:00
|
|
|
function refresh() {
|
2014-02-28 01:12:24 +00:00
|
|
|
$.ajax({
|
|
|
|
type: "POST",
|
|
|
|
url:'/ajax',
|
2014-02-28 01:57:46 +00:00
|
|
|
contentType: "image/jpeg",
|
2014-02-28 01:12:24 +00:00
|
|
|
success: function(data){
|
2014-02-28 02:11:07 +00:00
|
|
|
var str = "<img src='data:image/jpeg;base64,"+data+"'>";
|
2014-02-28 02:50:12 +00:00
|
|
|
$('.image').html(str);}
|
2014-02-28 01:21:18 +00:00
|
|
|
});
|
2014-02-28 01:28:34 +00:00
|
|
|
|
2014-02-28 02:36:53 +00:00
|
|
|
}
|
2014-02-28 02:50:12 +00:00
|
|
|
$(document).ready(refresh())
|
2014-02-28 02:52:39 +00:00
|
|
|
setInterval('refresh()', 2000);
|
2014-02-28 02:36:53 +00:00
|
|
|
|
|
|
|
|
2014-02-28 01:12:24 +00:00
|
|
|
</script>
|
2014-02-28 00:13:54 +00:00
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<h2>Vue camera</h2>
|
2014-02-28 02:50:12 +00:00
|
|
|
<div class="image"></div>
|
2014-02-28 03:19:03 +00:00
|
|
|
<form action="/disconnection" method="post">
|
|
|
|
<input type="submit" value="Deconnexion">
|
|
|
|
</form>
|
2014-02-28 00:13:54 +00:00
|
|
|
</body>
|
|
|
|
</html>
|