we now pass nicely structured information to the theme layer for profile pages. but it makes sense to give modules a chance to alter the profile fields. for example, i will committing to Contrib a module which lets end users choose which fields to show on their public profile page (and maybe even a 'buddies only' level too). another use would be for modules to reorder or regroup fields without needing to edit source module or theme layer. this is analogous to hook_form_alter() but for the profile view page.

this patch follows the code and functionality patttern set by hook_link_alter() and hook_mail_alter().

i will update the docs if this gets committed.

i also added an array key in the user_user('view') which got lost during the fapi upgrade.

CommentFileSizeAuthor
#4 patch_691.56 KBmoshe weitzman
#2 patch_661.46 KBmoshe weitzman
patch_63734 bytesmoshe weitzman

Comments

m3avrck’s picture

Sounds like a solid idea!

"AS" should be lowercase, otherwise code looks solid to me.

moshe weitzman’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new1.46 KB

fixed that AS.

drumm’s picture

Status: Reviewed & tested by the community » Needs work

- Lets properly capitalize and punctuate the comment. And add a space after the //.
- And the real reason I'm not fixing that myself and committing- I assume this is not using module_invoke_all() since it needs to be pass by reference; if that is true, please add a brief comment to explain that.

moshe weitzman’s picture

Status: Needs work » Reviewed & tested by the community
StatusFileSize
new1.56 KB

code comment enhanced and punctuation/capitalization fixed.

drumm’s picture

Status: Reviewed & tested by the community » Fixed

Committed to HEAD.

moshe weitzman’s picture

Status: Fixed » Active

thanks ... i just added docs to the upgrfading page. setting to active so i remember to do the api.drupal.org docs.

moshe weitzman’s picture

Status: Active » Fixed

api docs updated

Anonymous’s picture

Status: Fixed » Closed (fixed)