Update app.py
Browse files
app.py
CHANGED
|
@@ -44,11 +44,17 @@ elif page == "NLP Techniques":
|
|
| 44 |
# Pagination buttons
|
| 45 |
if st.button("Previous Page"):
|
| 46 |
if page == "NLP Techniques":
|
| 47 |
-
st.
|
| 48 |
|
| 49 |
if st.button("Next Page"):
|
| 50 |
if page == "Introduction to NLP":
|
| 51 |
-
st.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 52 |
|
| 53 |
# Footer
|
| 54 |
st.sidebar.write("---")
|
|
|
|
| 44 |
# Pagination buttons
|
| 45 |
if st.button("Previous Page"):
|
| 46 |
if page == "NLP Techniques":
|
| 47 |
+
st.experimental_set_query_params(page="Introduction to NLP")
|
| 48 |
|
| 49 |
if st.button("Next Page"):
|
| 50 |
if page == "Introduction to NLP":
|
| 51 |
+
st.experimental_set_query_params(page="NLP Techniques")
|
| 52 |
+
|
| 53 |
+
# Handle query params to set the active page
|
| 54 |
+
query_params = st.experimental_get_query_params()
|
| 55 |
+
if "page" in query_params and query_params["page"]:
|
| 56 |
+
page = query_params["page"][0]
|
| 57 |
+
|
| 58 |
|
| 59 |
# Footer
|
| 60 |
st.sidebar.write("---")
|