EDIT FOR THE ADMINS: IT IS NOT THE SAME QUESTION AS THE ONE ALREADY ASKED, SINCE THE ORIGIN OF THE ISSUE IS DIFFERENT!!!
I am trying to display the current language selected, which is saved in the sessions table. What I did first was the simple statement:
<?php echo $this->session->userdata("language"); ?>
which works quite well. The problem here is, that the language is saved into the session table in English and lower case, means: "english", "german", "spanish", etc
I then tried to resolve this using an if statement as follows:
<?php if ($this->session->userdata("language") = spanish) { echo 'Español'; } else if ($this->session->userdata("language") = english) { echo 'English'; } else echo 'Deutsch'; ?>
unfortunately, this returns:
Fatal error: Can't use method return value in write context in /home/.../.../.../app/views/header.php on line 270
Any hint on what I am doing wrong? Thanks for your quick help ;)