77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
if html.find('"?p={}">'.format(p)) >= 0:
html += ahttp.get(self.genre_url.format(cat) + "?p={}".format(p))
self.set_key(html)
r = []
# split station blocks
for row in re.split("""<div class="stationinfo""", html):
print row
# extract text fields
d = re.findall("""
<a\s+href="(//([\w-]+)\.radio\.net/?)" .*?
<img\s+src="([^<">]+)" .*?
<strong[^>]*>(.*?)</strong> .*?
<small[^>]*>\s*(.*?)\s*</small> .*?
|
<
|
77
78
79
80
81
82
83
84
85
86
87
88
89
90
|
if html.find('"?p={}">'.format(p)) >= 0:
html += ahttp.get(self.genre_url.format(cat) + "?p={}".format(p))
self.set_key(html)
r = []
# split station blocks
for row in re.split("""<div class="stationinfo""", html):
# extract text fields
d = re.findall("""
<a\s+href="(//([\w-]+)\.radio\.net/?)" .*?
<img\s+src="([^<">]+)" .*?
<strong[^>]*>(.*?)</strong> .*?
<small[^>]*>\s*(.*?)\s*</small> .*?
|