I am having a problem saving something into a session variable and
struggling to make any progress.
I have a login screen that I want to display differing logo’s
dependent on the URL that people use.
However, I now need to show the same logo on the logout screen, so I
thought I would save the details in a session variable in my login
method of AccountController. As follows:
session[:logo] = params[:id]
However this doesn’t work. When the view executes and i check
session[:logo] it is empty. If I move the above line into the view
then the session variable is saved, but it doesn’t seem the right
place to be doing it.
What am I doing wrong?