本文整理汇总了Python中utils.cleantext函数的典型用法代码示例。如果您正苦于以下问题:Python cleantext函数的具体用法?Python cleantext怎么用?Python cleantext使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了cleantext函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。
示例1: PAQList
def PAQList(url, page, onelist=None):
if onelist:
url = url.replace("page/1/", "page/" + str(page) + "/")
listhtml = utils.getHtml(url, "")
if "pornaq" in url:
match = re.compile(
r'<h2>\s+<a title="([^"]+)" href="([^"]+)".*?src="([^"]+)" class="attachment-primary-post-thumbnail',
re.DOTALL | re.IGNORECASE,
).findall(listhtml)
for name, videopage, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 62, img, "")
elif "porn00" in url:
match = re.compile(
'<h2> <a title="([^"]+)" href="([^"]+)".*?src="([^"]+)" class="attachment-primary-post-thumbnail',
re.DOTALL | re.IGNORECASE,
).findall(listhtml)
for name, videopage, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 62, img, "")
if not onelist:
if re.search("<span class='current'>\d+?</span><span>", listhtml, re.DOTALL | re.IGNORECASE):
npage = page + 1
url = url.replace("page/" + str(page) + "/", "page/" + str(npage) + "/")
utils.addDir("Next Page (" + str(npage) + ")", url, 61, "", npage)
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:Fr33m1nd,项目名称:WhiteCream-V0.0.1,代码行数:26,代码来源:hdporn.py
示例2: Categories
def Categories(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<a href="(.+?)" title=".+?">\n.+?<div class="thumb">\n.+?<img class="thumb" src="(.+?)" alt="(.+?)"/>').findall(listhtml)
for catpage, img, name in match:
name = utils.cleantext(name)
utils.addDir(name, catpage, 341, img, '')
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:opesboy,项目名称:WhiteCream-V0.0.1,代码行数:7,代码来源:hdzog.py
示例3: Cat
def Cat(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<li><a href="([^"]+)" rel="tag">([^<]+)<', re.DOTALL | re.IGNORECASE).findall(listhtml)
for catpage, name in match:
name = utils.cleantext(name)
utils.addDir(name, catpage, 371, '', '')
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:opesboy,项目名称:WhiteCream-V0.0.1,代码行数:7,代码来源:freeomovie.py
示例4: Cat
def Cat(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<a class="item" href="([^"]+)" title="([^"]+)".*?thumb" src="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for catpage, name, img in match:
name = utils.cleantext(name)
utils.addDir(name, catpage, 361, img, '')
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:Fr33m1nd,项目名称:WhiteCream-V0.0.1,代码行数:7,代码来源:tubepornclassic.py
示例5: XTList
def XTList(url, page):
sort = getXTSortMethod()
if re.search('\?', url, re.DOTALL | re.IGNORECASE):
url = url + '&filtre=' + sort
else:
url = url + '?filtre=' + sort
print url
listhtml = utils.getHtml(url, '')
match = re.compile('src="([^"]+?)" class="attachment.*?<a href="([^"]+)" title="([^"]+)".*?<div class="right">.<p>([^<]+)</p>', re.DOTALL | re.IGNORECASE).findall(listhtml)
for img, videopage, name, desc in match:
name = utils.cleantext(name)
desc = utils.cleantext(desc)
utils.addDownLink(name, videopage, 23, img, desc)
if re.search('<link rel="next"', listhtml, re.DOTALL | re.IGNORECASE):
npage = page + 1
url = url.replace('/page/'+str(page)+'/','/page/'+str(npage)+'/')
utils.addDir('Next Page ('+str(npage)+')', url, 21, '', npage)
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:natonatonato,项目名称:WhiteCream-V0.0.1,代码行数:18,代码来源:xtheatre.py
示例6: WXFList
def WXFList(url, page):
sort = getWXFSortMethod()
if re.search('\?', url, re.DOTALL | re.IGNORECASE):
url = url + '&filtre=' + sort + '&display=extract'
else:
url = url + '?filtre=' + sort + '&display=extract'
print url
listhtml = utils.getHtml(url, '')
match = re.compile('src="([^"]+)"[^<]+</noscript>.*?<a href="([^"]+)" title="([^"]+)".*?<p>([^<]+)</p>', re.DOTALL | re.IGNORECASE).findall(listhtml)
for img, videopage, name, desc in match:
name = utils.cleantext(name)
desc = utils.cleantext(desc)
utils.addDownLink(name, videopage, 13, img, desc)
if re.search('<link rel="next"', listhtml, re.DOTALL | re.IGNORECASE):
npage = page + 1
url = url.replace('/page/'+str(page)+'/','/page/'+str(npage)+'/')
utils.addDir('Next Page ('+str(npage)+')', url, 11, '', npage)
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:natonatonato,项目名称:WhiteCream-V0.0.1,代码行数:18,代码来源:watchxxxfree.py
示例7: ListSearch
def ListSearch(url):
html = utils.getHtml(url, '').replace('\n','')
match = re.compile('<p>(.+?)</p><p>.+?<img src="(.+?)".*?/>.*?</a>.*?<a href="(.+?)" class="more-link">').findall(html)
for name, img, videopage in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 422, img, '')
try:
nextp = re.compile('<link rel="next" href="(.+?)" />', re.DOTALL | re.IGNORECASE).findall(html)
utils.addDir('Next Page', nextp[0], 425,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:dubhead1,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:xxxsorg.py
示例8: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile(r'class="content-list-thumb">\s+<a href="([^"]+)" title="([^"]+)">.*?src="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 232, img, '')
try:
nextp=re.compile('next page-numbers" href="([^"]+)">»', re.DOTALL | re.IGNORECASE).findall(listhtml)[0]
utils.addDir('Next Page', nextp, 231,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:Mirocow,项目名称:WhiteCream-V0.0.2,代码行数:11,代码来源:k18.py
示例9: P00List
def P00List(url, page):
listhtml = utils.getHtml(url, '')
match = re.compile('src="([^"]+)" class="attachment-primary-post-thumbnail wp-post-image".*?<a title="([^"]+)" href="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for img, name, videopage in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 62, img, '')
if re.search("<span class='current'>\d+?</span><span>", listhtml, re.DOTALL | re.IGNORECASE):
npage = page + 1
url = url.replace('page/'+str(page)+'/','page/'+str(npage)+'/')
utils.addDir('Next Page ('+str(npage)+')', url, 65, '', npage)
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:natonatonato,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:hdporn.py
示例10: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile(r'<div class="quadrato">\s*?<a href="([^"]+)"\s*?title="([^"]+)".*?src="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 172, img, '')
try:
nextp=re.compile(r"""current(?:"|')>\d+</span><a.*?href=(?:"|')([^'"]+)""", re.DOTALL | re.IGNORECASE).findall(listhtml)[0]
utils.addDir('Next Page', nextp, 171,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:iamlegend2525,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:streamxxx.py
示例11: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<h2><a href="([^"]+)".*?title="([^"]+)">.+?<img src="([^"]+)".+? width="', re.DOTALL).findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 372, img, '')
try:
nextp = re.compile('<span class=\'current\'>.+?</span><a class="page larger" href="([^"]+)"').findall(listhtml)
utils.addDir('Next Page', nextp[0], 371,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:opesboy,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:freeomovie.py
示例12: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile(r'<a class="thumbnail" href="(.+?)">\n<script.+?</script>\n<figure>\n<img id=".+?" src="(.+?)".+?/>\n<figcaption>\n<span class="video-icon"><i class="fa fa-play"></i></span>\n<span class="duration"><i class="fa fa-clock-o"></i>(.+?)</span>\n(.+?)\n').findall(listhtml)
for videopage, img, duration, name in match:
name = utils.cleantext(name) + ' ' + duration
utils.addDownLink(name, 'http://www.mrsexe.com/' + videopage, 402, img, '')
try:
nextp=re.compile(r'<li class="arrow"><a href="(.+?)">suivant</li>').findall(listhtml)
utils.addDir('Next Page', 'http://www.mrsexe.com/' + nextp[0], 401,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:opesboy,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:mrsexe.py
示例13: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<a class="" href="(.+?)" title="(.+?)">\n<img src="(.+?)" class="has-image" alt=".+?"/>', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 352, img, '')
try:
nextp=re.compile('<li class="disabled active"><span class="active">.+?</span></li><li><a href="(.+?)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
utils.addDir('Next Page', nextp[0], 351,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:NothingGnome,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:cat3movie.py
示例14: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<li>\n.+?<a href="(.+?)" title="(.+?)">\n.+?<div class="thumb thumb-paged" data-screen-main="1">\n\n.+?<img src="(.+?)"').findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 342, img, '')
try:
nextp=re.compile('<a href="(.+?)" title="Next Page" data-page-num.+?>Next page').findall(listhtml)
utils.addDir('Next Page', 'http://www.hdzog.com' + nextp[0], 341,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:opesboy,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:hdzog.py
示例15: List
def List(url):
html = utils.getHtml(url, '')
match = re.compile(r'data-id="\d+" title="([^"]+)" href="([^"]+)".*?src="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(html)
for name, videopage, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 412, img, '')
try:
nextp = re.compile('<a class="nextpostslink" rel="next" href="(.+?)">', re.DOTALL | re.IGNORECASE).findall(html)
utils.addDir('Next Page', nextp[0], 411,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:RaspberryMCAdmin,项目名称:DevProjects,代码行数:11,代码来源:xxxstreams.py
示例16: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<div id="post-.*?<div class="thumb">.*?href="([^"]+)".*?src="([^"]+)".*?alt="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, img, name in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 182, img, '')
try:
nextp=re.compile('<a class="nextpostslink" rel="next" href="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
utils.addDir('Next Page', nextp[0], 181,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:Fr33m1nd,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:javhdonline.py
示例17: List
def List(url):
html = utils.getHtml(url, '')
match = re.compile('<img src="([^"]+)"/>.+?<a href="([^"]+)" class="more-link">.+?<span class="screen-reader-text">([^"]+)</span>', re.DOTALL | re.IGNORECASE).findall(html)
for img, videopage, name in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 422, img, '')
try:
nextp = re.compile('<a class="nextpostslink" rel="next" href="(.+?)">', re.DOTALL | re.IGNORECASE).findall(html)
utils.addDir('Next Page', nextp[0], 421,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:johnloveszoe,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:xxxsorg.py
示例18: PHList
def PHList(url):
listhtml = utils.getHtml(url, '')
match = re.compile('panel-img">.*?<a href="([^"]+)" title="([^"]+)".*?src="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 72, img, '')
try:
nextp=re.compile('<a href="([^"]+)">Next', re.DOTALL | re.IGNORECASE).findall(listhtml)
utils.addDir('Next Page', nextp[0],71,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:dreamykun,项目名称:WhiteCream-V0.0.1,代码行数:11,代码来源:pornhive.py
示例19: List
def List(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<div class="photo-thumb-image.*?href="([^"]+)".*?title="([^"]+)".*?src="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, name, img in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 233, img, '')
try:
nextp=re.compile('<a class="nextpostslink" rel="next" href="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
nextp = nextp[0].replace("&", "&")
utils.addDir('Next Page', nextp, 232,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:RaspberryMCAdmin,项目名称:DevProjects,代码行数:12,代码来源:playporn.py
示例20: YFTList
def YFTList(url):
listhtml = utils.getHtml(url, '')
match = re.compile('<a href="([^"]+)"[^<]+<[^<]+<img src="([^"]+)" alt="([^"]+)"', re.DOTALL | re.IGNORECASE).findall(listhtml)
for videopage, img, name in match:
name = utils.cleantext(name)
utils.addDownLink(name, videopage, 192, img, '')
try:
nextp=re.compile('<a href="([^"]+)">»', re.DOTALL | re.IGNORECASE).findall(listhtml)
nextp = "http://www.yourfreetube.net/" + nextp[0]
utils.addDir('Next Page', nextp, 191,'')
except: pass
xbmcplugin.endOfDirectory(utils.addon_handle)
开发者ID:Fr33m1nd,项目名称:WhiteCream-V0.0.1,代码行数:12,代码来源:yourfreetube.py
注:本文中的utils.cleantext函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论