more raw regexp strings
This commit is contained in:
parent
29a309f15e
commit
ae10c5c9b9
11 changed files with 45 additions and 45 deletions
|
|
@ -8,7 +8,7 @@ from ox.net import read_url
|
|||
def get_poster_url(id):
|
||||
url = 'http://piratecinema.org/posters/'
|
||||
html = read_url(url).decode('utf-8')
|
||||
results = re.compile('src="(.+)" title=".+\((\d{6}\d+)\)"').findall(html)
|
||||
results = re.compile(r'src="(.+)" title=".+\((\d{6}\d+)\)"').findall(html)
|
||||
for result in results:
|
||||
if result[1] == id:
|
||||
return url + result[0]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue