Preview:
def get_urls_from_sitemap(sitemap_url=None):
    sitemap = get_sitemap_from_url(sitemap_url)
    if sitemap is None:
        return None
    document = parseString(sitemap)
    locations = document.getElementsByTagName('loc')
    urls = []
    for location in locations:
        urls.append(location.firstChild.nodeValue)
    return urls
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