Add get_networks() to replace pre-3.9 $sites

Sets the global $sites for compatibility.
Merge pull request #4 from johnjamesjacoby/get-networks-function

Add get_networks() to replace pre-3.9 $sites