auto-detect sites
work on #11 #18 #19
some corrections
fix #19