We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 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