Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -14,7 +14,8 @@ def search_fn(query):
|
|
14 |
for link in soup.find_all("a",href=re.compile("(?<=/url\?q=)(htt.*://.*)")):
|
15 |
out = (re.split(":(?=http)",link["href"].replace("/url?q=","").split("&sa",1)[0]))
|
16 |
out = out[0]
|
17 |
-
|
|
|
18 |
frame_l=f'<div class="container-mee"><div class="put-on-top"><a target="_blank" href="{out}">{out}</a></div><iframe class="responsive-iframe-mee" src="{out}" frameborder="3"></iframe></div>'
|
19 |
|
20 |
file.writelines(frame_l)
|
|
|
14 |
for link in soup.find_all("a",href=re.compile("(?<=/url\?q=)(htt.*://.*)")):
|
15 |
out = (re.split(":(?=http)",link["href"].replace("/url?q=","").split("&sa",1)[0]))
|
16 |
out = out[0]
|
17 |
+
rr=requests.get(f"{out}")
|
18 |
+
print(dict(rr.headers).get("x-frame-options"))
|
19 |
frame_l=f'<div class="container-mee"><div class="put-on-top"><a target="_blank" href="{out}">{out}</a></div><iframe class="responsive-iframe-mee" src="{out}" frameborder="3"></iframe></div>'
|
20 |
|
21 |
file.writelines(frame_l)
|