Spaces:
Running
on
Zero
Running
on
Zero
added slash to file
Browse files
app.py
CHANGED
@@ -33,11 +33,11 @@ def predict(request: gr.Request,text_input):
|
|
33 |
</body>
|
34 |
</html>
|
35 |
""")
|
36 |
-
iframe = f
|
37 |
-
link = f'<a href="file={
|
|
|
38 |
return link, iframe
|
39 |
|
40 |
-
|
41 |
with gr.Blocks() as block:
|
42 |
gr.Markdown("""
|
43 |
## Gradio + FastAPI + Static Server
|
|
|
33 |
</body>
|
34 |
</html>
|
35 |
""")
|
36 |
+
iframe = f'<iframe src="/file=static/{file_name}" width="100%" height="500px"></iframe>'
|
37 |
+
link = f'<a href="/file=static/{file_name}" target="_blank">{file_name}</a>'
|
38 |
+
print("Serving file at:", f"/file=static/{file_name}")
|
39 |
return link, iframe
|
40 |
|
|
|
41 |
with gr.Blocks() as block:
|
42 |
gr.Markdown("""
|
43 |
## Gradio + FastAPI + Static Server
|