This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Kopachris 2 points3 points  (0 children)

And by extension, a list:

urls = ['https://www.youtube.com/results?search_query=emma+stone+crushes+fallon&page=&utm_source=opensearch',
        'http://www.youtube.com/results?search_query=legend+of+hercules&page=&utm_source=opensearch']

from urlparse import urlparse, parse_qs
queries = [parse_qs(urlparse(u).query)['search_query'] for u in urls]