nope. it did not make any difference.
    
    
    import htmlparser
    import xmltree
    import strtabs
    import strutils
    
    
    let allhtml:File = open("allhtml.txt")
    var line: string
    var count = 0
    while allhtml.readline(line):
      echo "HTML file: ", count, line
      var html = loadHTML(line.strip())
      for a in html.findall("a"):
        var url = a.attrs.getOrDefault("href", "/")
        if not url.isNil and url.startswith("/"):
          echo "$1\t$2" % [line, url]
      count += 1
    
    close(allhtml)
    

Reply via email to