Monday, 9 September 2013

Drupal: Display Custom User Profile Fields in a Block on All of Their Published Pages

Drupal: Display Custom User Profile Fields in a Block on All of Their
Published Pages

I have created a role, and have added additional fields to their profile
using Profile 2. The fields are part of the location module, and are just
basic contact info (address and phone number). They are also able to chose
a name, which is used in the url for both their profile and content.
So, when a user creates their account, the url is site.com/their-name.
When the user adds content the URL is site.com/their-name/content.
My goal is to display their contact info in a block on all pages they
publish. I was able to do this for their profile page with the following
view (see attached image). However, I would like this block to appear on
all pieces of content that they author.

No comments:

Post a Comment