Lynx以纯文本的形式下载网页

Lynx是一款基于命令行的web浏览器

[root@test88 ~]# yum install lynx -y
[root@test88 ~]# lynx www.baidu.com

以纯文本的形式下载网页

[root@test88 ~]# lynx -dump www.baidu.com > baidu.txt
[root@test88 ~]# cat baidu.txt 
    #[1]百度搜索
   REFRESH(0 sec): [2]http://www.baidu.com/baidu.html?from=noscript

   [bd_logo1.png]
   [3]到百度首页 ____________________ 百度一下
   输入法
     * [4]手写
     * [5]拼音
     *
     * [6]关闭

   [7]百度首页[8]设置[9]登录
   [10]新闻[11]hao123[12]地图[13]视频[14]贴吧[15]学术[16]登录[17]设置[18]更多产品
   网页[19]新闻[20]贴吧[21]知道[22]音乐[23]图片[24]视频[25]地图[26]文库[27]更多»

   手机百度

   [28]把百度设为主页[29]关于百度[30]About  Baidu[31]百度推广

   ©2017 Baidu [32]使用百度前必读 [33]意见反馈 京ICP证030173号  [34]京公网安备11000002000001号

References         # 不仅下载网页同时将网页中所有超链接列在这里

   1. http://www.baidu.com/content-search.xml
   2. http://www.baidu.com/baidu.html?from=noscript
   3. http://www.baidu.com/
   4. javascript:;
   5. javascript:;
   6. javascript:;
   7. http://www.baidu.com/
   8. javascript:;
   9. https://passport.baidu.com/v2/?login&tpl=mn&u=http%3A%2F%2Fwww.baidu.com%2F
  10. http://news.baidu.com/
  11. http://www.hao123.com/
  12. http://map.baidu.com/
  13. http://v.baidu.com/
  14. http://tieba.baidu.com/
  15. http://xueshu.baidu.com/
  16. https://passport.baidu.com/v2/?login&tpl=mn&u=http%3A%2F%2Fwww.baidu.com%2F
  17. http://www.baidu.com/gaoji/preferences.html
  18. http://www.baidu.com/more/
  19. http://news.baidu.com/ns?cl=2&rn=20&tn=news&word=
  20. http://tieba.baidu.com/f?kw=&fr=wwwt
  21. http://zhidao.baidu.com/q?ct=17&pn=0&tn=ikaslist&rn=10&word=&fr=wwwt
  22. http://music.baidu.com/search?fr=ps&ie=utf-8&key=
  23. http://image.baidu.com/search/index?tn=baiduimage&ps=1&ct=201326592&lm=-1&cl=2&nc=1&ie=utf-8&word=
  24. http://v.baidu.com/v?ct=301989888&rn=20&pn=0&db=0&s=25&ie=utf-8&word=
  25. http://map.baidu.com/m?word=&fr=ps01000
  26. http://wenku.baidu.com/search?word=&lm=0&od=0&ie=utf-8
  27. http://www.baidu.com/more/
  28. http://www.baidu.com/cache/sethelp/help.html
  29. http://home.baidu.com/
  30. http://ir.baidu.com/
  31. http://e.baidu.com/?refer=888
  32. http://www.baidu.com/duty/
  33. http://jianyi.baidu.com/
  34. http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=11000002000001
posted @ 2017-09-26 12:51  Peterer~王勇  阅读(693)  评论(0编辑  收藏  举报