I'm using rules and trying to get this workflow.

Site administrator adds new user -> redirected to the user's profile page to fill out information about the user.

I'm using the page redirect action to redirect to the profile2 edit page for the newly created user which works great. But I can't get this rule to trigger only for site administrators.

I've tried using data comparison [ roles= site administrator ] and user roles equals site administrator but neither work.

The idea is that the site administrators can add new users and fill out their profiles immediately.

  • 1
    I've figured out how to do it. In the "user has roles" condition, the parameter should be [site:current-user], Roles: Site Administrator. Before I was using the default 'account' parameter.
    – LWal
    Sep 20, 2012 at 21:08
  • Consider creating an answer from the solution you found. I'm sure others would find this useful in the future. There is nothing wrong with answering your own question and accepting it.
    – Citricguy
    Sep 21, 2012 at 3:22

1 Answer 1


Here's how to fix the problem I was having and a little more context on how to do it.

First you need the Rules module. http://drupal.org/project/rules

  • Go to the rules configuration page, usually located at example.com/admin/config/workflow/rules

    1. Add a new rule
    2. Add condition

      • User has role(s)
      • Parameters should be User: [site:current-user], Roles: roles for condition
      • in my case Parameter: User: [site:current-user], Roles: developer, site administrator
    3. add an action

      • Page redirect to new user profile
      • Parameter: URL: user/[account:uid]/edit/'profilename'
      • replace 'profilename' with whatever your profile2 profile is called

Before I was using the default 'account' parameter, changing it to the User: [site:current-user] fixed my problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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