Photo Picker

The photo picker module allows the user to select, crop, and upload a group photo.

It is used in two places:

  1. The Create a group page. The user has the option to choose their group photo when they create a new group.
  2. The Members toolbox. The user can change their group photo via an option in the members toolbox.

#Technical Notes

The photo picker is required for groups as the group profile is managed by the admin user. The admin user doesn't have direct access to edit the group profile settings via the Nationbuilder website.

The workaround is to use the Nationbuilder API to upload the photo as a page attachment and then store the url of the uploaded photo in a custom field on the group profile.

All group photos are uploaded as a page attachment to a single page with the slug: group_photo_uploads. Search for this basic page, and then click the Files tab to see all attached photos.

Once the photo is uploaded, the URL is stored in the group custom field: profile_image_url.