I have a domain. I have two applications using this domain:
www.mydomain.com/first
www.mydomain.com/second
I do a redirect from www.mydomain.com/first to www.mydomain.com/second via the command: res.redirect('/second');
I'd like the application located at www.mydomain.com/second to then do a redirect back to www.mydomain.com/first dynamically (not via hardcoding the address).
So I was thinking that www.mydomain.com/second could get the request referrer field via the command: req.get('Referrer'). I was expecting this to return the value either www.mydomain.com/first, /first or first but it returns undefined.
How do I get a hold of the value?