Reading PHP-Session from CakePHP

Hello,

I have a Session that remembers several logins on my website. There are more than 2 scripts, that need a login. So they are bundled with one Login-System now.

Unfortunately I really need CakePHP to call an existing PHP-Session, e.g. $_SESSION[‘lang’].

echo $_SESSION[‘lang’] inside a .ctp-file provideds an empty output.

Intended workflow:

If lang==fr
include (fr.ctp)
if lang==en
include (en.ctp)

If anyone could tell me how to solve the problem or how to create a workaround, that would be great!

Did you tried $this->request->session()->read('lang') ?