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

To get back url

Everybody is good, phalcon is there a way to get back the url I want to request an error is returned if the user requests before the address, please each elder grant instruction

edited Oct '14

I think you can use in plain php


In phalcon you should use

$this->request->getServer('REFERER_URI', '\');

Read more about Phalcon Request https://docs.phalcon.io/en/latest/api/Phalcon_Http_Request.html#class-phalcon-http-request

Attention REFERER_URI sometimes can be null and provided by user browser

Another suggestion you can use hidden input

<input type="hidden" name="backurl" value="/fdsfsd/dsfsdfsd/sdfsd">

And get it after post for example