Sitemap generator
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
721 B

9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
  1. import pysitemap
  2. """
  3. Example script
  4. """
  5. if __name__=='__main__':
  6. <<<<<<< HEAD
  7. url = 'http://www.ltsvet.ru/' # url from to crawl
  8. logfile = 'errlog.log' # path to logfile
  9. oformat = 'xml' # output format
  10. outputfile = '/srv/www/site/sitemap.xml' # path to output file
  11. crawl = pysitemap.Crawler(url=url, logfile=logfile, oformat=oformat, outputfile=outputfile)
  12. crawl.crawl()
  13. =======
  14. url = 'http://www.example.ru/' # url from to crawl
  15. logfile = 'errlog.log' # path to logfile
  16. oformat = 'xml' # output format
  17. crawl = pysitemap.Crawler(url=url, logfile=logfile, oformat=oformat)
  18. print datetime.datetime.now()
  19. crawl.crawl()
  20. print datetime.datetime.now()
  21. >>>>>>> origin/master