首页 > 编程语言 > 详细

《用Python写网络爬虫》示例网站搭建(框架+本书pdf+章节代码)

时间:2017-03-29 22:49:40      阅读:650      评论:0      收藏:0      [点我收藏+]

技术分享

所用到的代码及工具

示例网站源码+框架+本书pdf+章节代码

链接: https://pan.baidu.com/s/1miHjIYk 密码: af35

环境

python2.7

win7x64

示例网站搭建

wswp-places.zip 书中站点源码
web2py_src.zip 站点所使用的框架

1 解压web2py_src.zip
2 然后到web2py/applications目录下

3 将wswp-places.zip解压到applications目录下

   技术分享
4 返回上一层目录,到web2py目录下,双击web2py.py,或者 执行命令python web2py.py

    技术分享

如果设置了admin密码,使用命令python web2py.py --password=<password>,没有设置密码默认空

技术分享


5 浏览器访问 http://127.0.0.1:8000/places

 技术分享

 

 


 

书上的正经途径

网站源代码托管在 https://bitbucket.org/wswp/places

(注册时,需要翻,用到Google账号。需要安装sourceTree)

代码使用web2py框架搭架

This app relies on the web2py framework, which can be downloaded here and is documented here.
http://web2py.com/init/default/download
http://web2py.com/book

安装步骤

技术分享

文字版,方便复制

In the shell the installation instructions are as follows:
# first download web2py
wget http://www.web2py.com/examples/static/web2py_src.zip
unzip web2py_src.zip
# now download the app
cd web2py/applications
hg clone ssh://hg@bitbucket.org/wswp/places
# now start the web2py server with a password for the admin interface
cd ..
python web2py.py --password=<password>

The places app can now be accessed in your web browser at http://127.0.0.1:8000/places

《用Python写网络爬虫》示例网站搭建(框架+本书pdf+章节代码)

原文:http://www.cnblogs.com/hdan/p/6641848.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!