Drupal hook_user example: redirect user after login

Redirect a user after logging into a Drupal website with the use of the functions hook_user() and drupal_goto()!

yadaDROP Admin
3,549
01.06.10

Saving the world, one website at a time.

rate it:

Your rating: None Average: 4 (1 vote)

Comments

try this instead

Were you using switch($op)/case 'login': with $op or were you using if($op=='login')?

That does not work for me on

That does not work for me on drupal 6.17. Another op='load' occurs after 'login' and seems to supress the drupal_goto...

Add comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.

More information about formatting options