V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
SuperFlanker
V2EX  ›  Python

来问个初级问题, 对于批量网页抓取,怎么实现好点儿

  •  
  •   SuperFlanker · 2015-05-18 10:35:00 +08:00 · 2111 次点击
    这是一个创建于 3274 天前的主题,其中的信息可能已经有所发展或是发生改变。
    ShowDetail.aspx?querywrid=xxxx 这种格式

    批量抓取

    另外登陆该怎么解决哦?
    imlinhanchao
        1
    imlinhanchao  
       2015-05-18 11:39:42 +08:00
    1. id連續就從1開始知道抓到錯誤頁。
    2. 登錄就模擬登錄請求保存cookies就好了。
    Flyshit
        2
    Flyshit  
       2015-05-18 16:05:28 +08:00 via Android
    循环get/post就可以了嘛。需要登陆的话就post登陆后记录cookies,设置cookies然后get/post嘛
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2589 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 24ms · UTC 14:09 · PVG 22:09 · LAX 07:09 · JFK 10:09
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.