Currently, using profile fields with pathauto doesn't work. For example, here is my user pattern:
people/[content-profile-profile-profile_firstname-raw]-[content-profile-profile-profile_lastname-raw]
When registering, no user alias is created because pathauto is invoked by hook_user, which fires before the content_profile_registration_user_register_submit callback. At first I thought this could be handled by adjusting module weights, but realized this doesn't help because hook_user (and thus pathauto) will always run before the form's other #submit callbacks.
Here is a patch that invokes hook_user_update after the profile node is saved. This allows pathauto (and any other interested module) to react to the new profile node.
Comment | File | Size | Author |
---|---|---|---|
registration_pathauto.patch | 883 bytes | grendzy |
Comments
Comment #1
YK85 CreditAttribution: YK85 commentedsubscribing
Comment #2
kelvincool CreditAttribution: kelvincool commentedHad the same problem, can confirm above patch fixes the issue.
Comment #3
rootworkThis works for me. Would be great to see this get into dev.