modified to resolve domain name