You most learn to not use quote tag on code,
i have fixed all you post.
In editor there there is "Insert python tag" to right of "Insert quote" button.
This is wrong:
i have fixed all you post.
In editor there there is "Insert python tag" to right of "Insert quote" button.
This is wrong:
print(link.get_text()) # Shall be print(link.text)
Quote:but I still get links that I do not wont, like the links from img tags, is there any way to exclude them from print?
for link in soup.find_all('a'): if 'img' not in link: print(link.get('href')) print(link.text)