If http://foo.com redirects to 1.2.3.4 which then redirects to http://finalurl.com, how can I use Ruby to find out the landing URL “http://finalurl.com”?
If http://foo.com redirects to 1.2.3.4 which then redirects to http://finalurl.com , how can I
Share
Here’s two ways, using both HTTPClient and Open-URI: