Adding get_query_parameters function.
Browse files
app.py
CHANGED
|
@@ -1,7 +1,8 @@
|
|
| 1 |
import gradio as gr
|
| 2 |
|
| 3 |
-
def
|
| 4 |
-
|
|
|
|
| 5 |
|
| 6 |
-
demo = gr.Interface(fn=
|
| 7 |
demo.launch()
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
|
| 3 |
+
def get_query_params(request: gr.Request):
|
| 4 |
+
query_params = request.query_params
|
| 5 |
+
return f"Query Parameters: {query_params}"
|
| 6 |
|
| 7 |
+
demo = gr.Interface(fn=get_query_params, inputs=[], outputs="text", live=True)
|
| 8 |
demo.launch()
|