1
0
mirror of https://github.com/binary-kitchen/doorlockd synced 2024-06-10 10:22:34 +02:00
doorlockd-mirror/doorlockd-new/templates/display.html
Ralf Ramsauer ae0d4f5aa2 socketio: deliver local static copy of scripts
Signed-off-by: Ralf Ramsauer <ralf@binary-kitchen.de>
2018-03-18 17:22:39 +01:00

26 lines
741 B
HTML

{% extends "layout.html" %}
{% block scripts %}
{{ super() }}
<script type="text/javascript" src="static/socket.io.slim.js"></script>
<script type="text/javascript" charset="utf-8">
$(document).ready(function() {
var socket = io.connect(location.protocol + '//' + document.domain + ':' + location.port)
socket.on('connect', function() {
socket.emit('connected');
});
socket.on('status', function(status) {
$('#led').html(status.led)
$('#message').html(status.message)
});
});
</script>
{% endblock %}
{% block content %}
<h1>Willkommen in der Binary Kitchen!</h1>
<div id="led"></div>
<div id="message"></div>
{{ super() }}
{% endblock %}