BrianJones wrote: > Hello community, > > This may be a bit of an easy/stupid question, but bear with me! Is there a > way to assess what page is currently being viewed by the user (with > Velocity), so that I may be able to do something like this: > > #if (currentPage = someOtherPage) > ...do this... > #else > ... do something else... > #end > > Any input on this would be amazing! Cheers once again to the XWiki > community.
$doc is the current document, an instance of com.xpn.xwiki.api.Document, see http://maven.xwiki.org/site/xwiki-core-parent/xwiki-core/apidocs/com/xpn/xwiki/api/Document.html So, to get the name, just use: #if($doc.fullName == 'Some.Document') -- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
