hi,
i´m writing a usermacro in which i want to get the username from the page on which the macro is placed.
$user.name does not work.
maybe something like:
getUserFromPage(this)
thanks for your help
i mean the creator of the macro, but because of the fact that the macro will be used on on the users personalspace (Homepage) it can also be the user of the page on which the macro is placed
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Well, the creator of the macro is always you, so why using a function for this? Just drop your name in the code of the macro.
If you want to get the name of the logged on user, just try
$action.getRemoteUser().getFullName()
If you want the creator of the page use this:
$content.getCreator().getFullName()
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.