Getting user principal attributes in header.vm
Ron McNulty <[email protected]> Sun, 04 Nov 2012 21:55:47 +1300
| Newsgroups | gmane.comp.jakarta.jetspeed.user |
|---|---|
| Message-ID | <997C2B31702F42188038B8F8CB8540AA@Conservatory> |
Hi All I am setting up some new themes for our applications, which means creating new files for header.vm and footer.vm. Unfortunately I am not a Velocity expert :) I would like to put something like "Logged in as jsmith: Joe Smith" in the header. The jsmith loginId is easy (principal.getName()), but I can't seem to pull the user.name.family and user.name.given attributes from the attributes map structure - either I get an empty string, or the line of velocity code appears verbatim. The attributes are present, as I can access them from portlet Java code. Can some Velocity guru point me in the right direction? Regards Ron