refactored url generating code so that it reads more clearly
download the selenium server version appropriate for the current verison of nodewebkit