Foren
Getting URL to user portrait from a web content template
Alain Dresse, geändert vor 12 Jahren.
Getting URL to user portrait from a web content template
Junior Member Beiträge: 95 Beitrittsdatum: 18.07.11 Neueste Beiträge
Hi,
I have a userId from my portlet's service, and would like to display that user's portrait in my web content.
I thought about using User.getPortraitURL(ThemeDisplay themeDisplay), but there is no velocity access to themeDisplay in web content templates.
How do I get that user's portraitURL ?
Thanks,
Alain
I have a userId from my portlet's service, and would like to display that user's portrait in my web content.
I thought about using User.getPortraitURL(ThemeDisplay themeDisplay), but there is no velocity access to themeDisplay in web content templates.
How do I get that user's portraitURL ?
Thanks,
Alain
Alain Dresse, geändert vor 11 Jahren.
RE: Getting URL to user portrait from a web content template (Antwort)
Junior Member Beiträge: 95 Beitrittsdatum: 18.07.11 Neueste Beiträge
The following seems to work to get the portraitURL for a given user in a web content template:
"/image/user_male_portrait?img_id=$user.getPortraitId()&t=$dateTool.getSystemTime()"
"/image/user_male_portrait?img_id=$user.getPortraitId()&t=$dateTool.getSystemTime()"
Syed Nasar, geändert vor 7 Jahren.
RE: Getting URL to user portrait from a web content template
Junior Member Beiträge: 64 Beitrittsdatum: 03.09.15 Neueste Beiträge
Hi,
In your URL, img_id_token parameter is missing. How you are fetching image?
In your URL, img_id_token parameter is missing. How you are fetching image?