Workflow:
Is this the best way to achieve this?
{exp:member:login_form return="<?php echo
"http://{$_SERVER['SERVER_NAME']}{$_SERVER['REQUEST_URI']}" ?>"}There must be a better way, no?
You need the page previous, then, right? Not the current request, because that’s your login page. You could use flashdata for that, or even the session tracker cookie which stores the previously viewed pages in order. There’s not a global template variable to access that, though, you’ll need PHP.
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.