I have list of URLs like this:
http://example.com/sdfsdf/sdfsa
https://example2.com/53lasfd/asdfs
http://www.example3.com/asdfas/asdfasdf.php?=asdfa
https://subdomain.example4.com/index.php?id=sadfa
https://www.subdomain.example5.com/asdfas/asdfasd
I need to extract only domains (and subdomains) without http, https, www and all after /:
exmaple.com
exmaple2.com
example3.com
subdomain.example4.com
subdomain.example5.com