Code:
function getHTML(link, ...){
local trying = 3, output = null;
if(vargv.len()>0) trying = vargv[0];
system(format("wget -t %d -O getHTML -a getHTMLLog %s -q -F", trying, link));
local file = io.file("getHTML", "r");
if(file.isOpen){
output = file.read(io_type.ALL);
file.close();
}
system("rm getHTML");
return output;
}
local servers = getHTML("http://185.5.97.181:8000/master/public_servers/");
Simple script to download html code with any www. it using only wget for GNU/Linux. Published as curiosity.