revised code to take in web address