Hello good time
Friends, how can I embed google results?
I could not do this with iframe
Hello good time
Friends, how can I embed google results?
I could not do this with iframe
Hi there,
Thanks for sharing your question with the community! Check out our guidelines on how to post an effective question here – in particular, please share a code snippet that shows what you’ve tried so far to implement this.
Caroline
import streamlit as st
import streamlit.components.v1 as components
components.iframe(“http://www.google.com/”)
import streamlit as st
import streamlit.components.v1 as components
search = st.text_input("What do you want to search for?")
components.iframe(f"https://www.google.com/search?igu=1&ei=&q={search}", height=1000)
This results in something like this:
Hello
Thank you very much for your help.
Hello again
I have another question.
Is it possible to use two iframes side by side?
I mean to have two iframes across the page
Hi @amiran
That is certainly possible using st.columns
import streamlit.components.v1 as components
import streamlit as st
st.set_page_config(layout="wide")
search = st.text_input("What do you want to search for?")
col1, col2 = st.columns(2)
with col1:
components.iframe(
f"https://www.google.com/search?igu=1&ei=&q={search}", height=1000, width=400
)
with col2:
components.iframe(
f"https://www.google.com/search?igu=1&ei=&q={search}", height=1000, width=400
)
Hello
Thank you very much, right?
I had completely forgotten the columns