I would like to delete the URI, that is to say what follows from a URL, as in the example in the title of the question with PHP.
http://misitio.com/uri/uri/loquesea
- > http://misitio.com
@ RobertoLeónOramas I am requesting a php sanitizer, not a rewrite htaccess rule.
@MrViKxD Returns the hostname in which the site is accessed, I need a sanitizer, that's not what I need.