mirror of
https://github.com/tebarius/Docker-Flask-QR.git
synced 2025-12-20 22:23:30 +01:00
anpassung für proxy
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
from flask import Flask, render_template, request
|
||||
from flask_qrcode import QRcode
|
||||
|
||||
app = Flask(__name__)
|
||||
app = Flask(__name__, static_folder='qr-static')
|
||||
QRcode(app)
|
||||
|
||||
|
||||
@@ -13,6 +13,11 @@ def index():
|
||||
return render_template('index.html')
|
||||
|
||||
|
||||
@app.route("/index.html")
|
||||
def index_html():
|
||||
return render_template('index.html')
|
||||
|
||||
|
||||
@app.route("/text.html")
|
||||
def text():
|
||||
return render_template('text.html')
|
||||
@@ -69,6 +74,7 @@ def makeqr():
|
||||
|
||||
elif request.args.get('type') == "tel":
|
||||
data = f"tel:{request.args.get('tel')}"
|
||||
|
||||
elif request.args.get('type') == "geo":
|
||||
data = "GEO:"
|
||||
if request.args.get('ns') == "S":
|
||||
|
||||
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
@@ -3,13 +3,13 @@
|
||||
{% block inhalt %}
|
||||
<p>
|
||||
<b>Welche Art von QR-Code soll generiert werden?</b><br>
|
||||
<div><button><a href="./text.html">einfacher Text </a></button></div>
|
||||
<div><button><a href="./url.html">URL/Website-Link</a></button></div>
|
||||
<div><button><a href="./tel.html">Telefonnummer</a></button></div>
|
||||
<div><button><a href="./mail.html">EMail-Adresse</a></button></div>
|
||||
<div><button><a href="./wifi.html">WIFI</a></button></div>
|
||||
<div><button><a href="./cal.html">Kalender-Termin</a></button></div>
|
||||
<div><button><a href="./vcard.html">Visitenkarte (vCard)</a></button></div>
|
||||
<div><button><a href="./mecard.html">Visitenkarte (MeCard)</a></button></div>
|
||||
<div><button><a href="./geo.html">geographische Koordinaten</a></button></div>
|
||||
<div><button><a href="text.html">einfacher Text </a></button></div>
|
||||
<div><button><a href="url.html">URL/Website-Link</a></button></div>
|
||||
<div><button><a href="tel.html">Telefonnummer</a></button></div>
|
||||
<div><button><a href="mail.html">EMail-Adresse</a></button></div>
|
||||
<div><button><a href="wifi.html">WIFI</a></button></div>
|
||||
<div><button><a href="cal.html">Kalender-Termin</a></button></div>
|
||||
<div><button><a href="vcard.html">Visitenkarte (vCard)</a></button></div>
|
||||
<div><button><a href="mecard.html">Visitenkarte (MeCard)</a></button></div>
|
||||
<div><button><a href="geo.html">geographische Koordinaten</a></button></div>
|
||||
{% endblock %}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<img src="{{ data|qrcode(fit=True, box_size=10, border=2, ) }}" alt="QR-Code für {{ data }}">
|
||||
</p>
|
||||
<p>
|
||||
<a href="./">Noch einmal bitte!</a>
|
||||
<a href="/index.html">Noch einmal bitte!</a>
|
||||
</p>
|
||||
{% endblock %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user