Hacker News new | ask | show | jobs
by zeynel1 5567 days ago
Thanks for trying. The title of the page you are submitting must have returns before and after it. I try to catch that error with "strip" but for some reason yours is not caught:

    soup = BeautifulSoup.BeautifulSoup(urllib.urlopen(url))
    title = str(soup.html.head.title.string).lstrip("\r\n").rstrip("\r\n")
Try another url.
1 comments

ok, I fixed the problem. It should work now.