Is there a way to get the string out of this kind of URL:

http://localhost/test

I need to get test out of it.