MsRewards-Reborn/Flask/templates/dev.html
2023-09-27 11:34:47 +02:00

27 lines
882 B
HTML

{% extends "base.html" %}
{% block left_pannel %}
{% endblock %}
{% block content %}
{%if not current_user.is_authenticated %}
<button class="unselected" onclick="location.href = '/login';">login</button>
{% else %}
<embed type="text/html" src="{{url_for('static', filename='logs/dev.txt')}}" width="100%" height="85%" id="embed">
<iframe id="iframe" src="{{url_for('static', filename='logs/dev.txt')}}"></iframe>
<script>
window.setInterval(function() {
reloadIFrame()
}, 500);
function reloadIFrame() {
console.log('reloading..');
document.getElementById('iframe').contentWindow.location.reload();
var myIframe = document.getElementById('iframe');
myIframe.contentWindow.scrollTo(0, myIframe.contentDocument.body.scrollHeight);
}
</script>
{% endif %}
{% endblock %}