I wanted to render the user session information on the header of every page. At the moment the header is written as a layout and I unable to create a function in which every controller can call automatically so that the header can retrieve the session and display the user name.
My current method is to call a function in every action to render the name and it seems this is a dirty solution to me. Any help or approach on this will be greatly appreciated. Thanks.