Update app.py
Browse files
app.py
CHANGED
@@ -100,7 +100,7 @@ def application_page():
|
|
100 |
<p>Upload a JPG image to square and fill with color filler.</p>
|
101 |
<form action="/upload/" enctype="multipart/form-data" method="post">
|
102 |
<input name="file" type="file">
|
103 |
-
<input type="Square It">
|
104 |
</form>
|
105 |
<a href="/">Back</a>
|
106 |
</body>
|
@@ -138,10 +138,10 @@ async def upload_file(file: UploadFile = File(...)):
|
|
138 |
content=f"""
|
139 |
<h3>Image successfully squared!</h3>
|
140 |
<img src='data:image/jpeg;base64,{display_encoded_img}' width="512" height="512" />
|
141 |
-
<br
|
142 |
<a href="data:image/jpeg;base64,{full_size_encoded_img}" download="squared_image.jpg">
|
143 |
<button>Download Full-Size Image</button>
|
144 |
-
</a>
|
145 |
""",
|
146 |
media_type="text/html"
|
147 |
)
|
|
|
100 |
<p>Upload a JPG image to square and fill with color filler.</p>
|
101 |
<form action="/upload/" enctype="multipart/form-data" method="post">
|
102 |
<input name="file" type="file">
|
103 |
+
<input type="submit" value="Square It">
|
104 |
</form>
|
105 |
<a href="/">Back</a>
|
106 |
</body>
|
|
|
138 |
content=f"""
|
139 |
<h3>Image successfully squared!</h3>
|
140 |
<img src='data:image/jpeg;base64,{display_encoded_img}' width="512" height="512" />
|
141 |
+
<br/><form>
|
142 |
<a href="data:image/jpeg;base64,{full_size_encoded_img}" download="squared_image.jpg">
|
143 |
<button>Download Full-Size Image</button>
|
144 |
+
</a></form>
|
145 |
""",
|
146 |
media_type="text/html"
|
147 |
)
|