Hi Helenc,
On Fri, Dec 11, 2009 at 12:54 PM, Helenc <truckfin(a)hotmail.com> wrote:
Hi,
I'm very new to xwiki. Thanks so far to everyone that is contributing...
I have created a new class. And I would like to include author as a
property
in the class, and have it automatically populate with the user's name.
You don't really need to do that since the document already stores the
page's creator name and the name of the last person who modified it.
You can access them through $doc.author and $doc.creator .
Alternatively you can add an "author" field to your class and have it
populated using the value returned by $context.user .
Hope this helps,
Guillaume
I tried looking at comment class but couldn't see
how this get's done.
Could someone help me out?
--
View this message in context:
http://n2.nabble.com/display-author-creator-as-property-tp4150822p4150822.h…
Sent from the XWiki- Users mailing list archive at
Nabble.com.
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users
--
Guillaume Lerouge
Product Manager - XWiki SAS
Skype: wikibc
Twitter: glerouge
http://guillaumelerouge.com/