We are moving our forum in GitHub Discussions. For questions about Phalcon v3/v4 you can visit here and for Phalcon v5 here.

How to get URL segments

Hi How can I get URL segments in phalcon?



8.1k
$uri_segments = explode("/", $this->request->getUri());


125.7k
Accepted
answer

Phalcon doesn't have anything for parsing a URL, because PHP already has it built in: https://www.php.net/manual/function.parse-url.php