2

I've started learning Drupal (I'm starting with Drupal 7) and the best way to do that seemed to me to be in creating a custom theme from scratch.

I'm trying to create a menu in which the login form is displayed if the users are not logged in and the user menu if they are logged in. How do I go about doing this in proper Drupal fashion?

1

Drupal already has a login block, which displays the login form, which by default only is displayed for anynomous users. So all you really need to do is add a block with the User menu (all menus has a block with the items) next to the login block and have it show for only authenticated users.

This is one of the things where configuration will get you all the way.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.