Files
flask_url_shortener/tiny0/templates/url.html
T
2020-07-23 18:26:18 +00:00

27 lines
607 B
HTML

{% extends "layout.html" %}
{% block body %}
<body>
<div class="headers">
<a class="title" href="{{ url_for('index') }}">tiny0</a>
<h1 class="desc">Custom URL Shortener</h1>
</div>
<div class="container">
<div class="inputs">
<input type="text" value="{{ url }}" id="url" class="url" readonly>
<button onclick="copyURL()" class="button">Copy</button>
</div>
</div>
<script>
function copyURL() {
var url = document.getElementById("url");
url.select();
url.setSelectionRange(0, 99999)
document.execCommand("copy");
}
</script>
</body>
{% endblock %}