I posted this question on StackOverflow a couple of weeks ago, but since it hasn't got very much attention I'm posting it here instead.
I'm building a Content Query Web Part that is supposed to show a link to a user page (userdisp.aspx). I get the user name from a custom list containing a column named 'Member' of the type 'Person or Group'.
To build the link in the ItemStyle.xsl, I need both the name and the Id of the user:
<a href="http://<site>/_layouts/userdisp.aspx?ID=@ID"> <xsl:value-of select="@Name" /> </a>
However, I'm only able to get the name OR the Id from the Content Query. E.g. if I set "Show field: Name (with presence)" for the Member column I get the name, and if I set "Show field: ID" I obviously get the Id. But I need both!
I should probably also point out that I'm building the solution on a very stripped down version of SharePoint, so all I have to play with is .xsl and .webpart files, and whichever settings I can make in the online editor (no access to SharePoint Designer).
Last but not least, my SharePoint knowledge level is noob. :)