I have built a site with user authentication, following this tutorial from the cookbook
Login of registered users works.
Now, I want to show the username of the logged in user in the menu bar, using code like this in my templates:
<?php echo ($user->username()) ?>
Always get an error: Undefined variable: User
Kind of perplexed, should definitely work.