Displaying content based on logged in or not

hello,

I have 2 buttons on a page 1 of which I need to show only if logged in, and display other one if not logged in, how is this done CakePHP 4?

Regards

Mal

If you are using the middlware - there are helpers available.

https://book.cakephp.org/authentication/1/en/view-helper.html

1 Like