import requests from xml.dom.minidom import parseString def get_sitemap_from_url(sitemap_url=None): if sitemap_url is None: return None try: response = requests.get(sitemap_url, allow_redirects=True) return response.text except requests.exceptions.RequestException: return None
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter