import urllib.request
import re
from lxml import etree


# 封装获取网页所有信息的函数
def getHtml(url):
    page = urllib.request.urlopen(url)
    html = page.read()
    return html


# 封装获取满足正则表达式的图片地址
def getImg(content):
    xml = etree.HTML(content)
    # print(content)
    datas = xml.xpath('//*[@id="main"]/div[1]/div[3]/img/@data-kksrc')
    print(datas)
    return datas


if __name__ == "__main__":
    html = getHtml("https://www.kuaikanmanhua.com/web/comic/129558/")
    # print(html)
    i = 0
    for imgurl in getImg(html):
        urllib.request.urlretrieve(imgurl, "/Volumes/develop/data/image/kuaikan-web/%s.jpg" % i)
        i += 1

2a92f837f6315a19694d70b9f546c87d11c76d8b
<mask token>


def getHtml(url):
    page = urllib.request.urlopen(url)
    html = page.read()
    return html


<mask token>

<mask token>


def getHtml(url):
    page = urllib.request.urlopen(url)
    html = page.read()
    return html


def getImg(content):
    xml = etree.HTML(content)
    datas = xml.xpath('//*[@id="main"]/div[1]/div[3]/img/@data-kksrc')
    print(datas)
    return datas


<mask token>

<mask token>


def getHtml(url):
    page = urllib.request.urlopen(url)
    html = page.read()
    return html


def getImg(content):
    xml = etree.HTML(content)
    datas = xml.xpath('//*[@id="main"]/div[1]/div[3]/img/@data-kksrc')
    print(datas)
    return datas


if __name__ == '__main__':
    html = getHtml('https://www.kuaikanmanhua.com/web/comic/129558/')
    i = 0
    for imgurl in getImg(html):
        urllib.request.urlretrieve(imgurl, 
            '/Volumes/develop/data/image/kuaikan-web/%s.jpg' % i)
        i += 1

import urllib.request
import re
from lxml import etree


def getHtml(url):
    page = urllib.request.urlopen(url)
    html = page.read()
    return html


def getImg(content):
    xml = etree.HTML(content)
    datas = xml.xpath('//*[@id="main"]/div[1]/div[3]/img/@data-kksrc')
    print(datas)
    return datas


if __name__ == '__main__':
    html = getHtml('https://www.kuaikanmanhua.com/web/comic/129558/')
    i = 0
    for imgurl in getImg(html):
        urllib.request.urlretrieve(imgurl, 
            '/Volumes/develop/data/image/kuaikan-web/%s.jpg' % i)
        i += 1

import urllib.request
import re
from lxml import etree


# 封装获取网页所有信息的函数
def getHtml(url):
    page = urllib.request.urlopen(url)
    html = page.read()
    return html


# 封装获取满足正则表达式的图片地址
def getImg(content):
    xml = etree.HTML(content)
    # print(content)
    datas = xml.xpath('//*[@id="main"]/div[1]/div[3]/img/@data-kksrc')
    print(datas)
    return datas


if __name__ == "__main__":
    html = getHtml("https://www.kuaikanmanhua.com/web/comic/129558/")
    # print(html)
    i = 0
    for imgurl in getImg(html):
        urllib.request.urlretrieve(imgurl, "/Volumes/develop/data/image/kuaikan-web/%s.jpg" % i)
        i += 1
