Hi,
Can we create different home pages for the different group USERs created. so that each group’s users see a different page as Home when they login.
If the above can be done then, If an Admin is part of both the groups then which page will be displayed as Home page.
Regards,
Vishal Gagar
There’s only 1 home for the wiki but you can easily add some script to it to include or display or redirect to the page you wish based on the user belonging to a given group.
Something like
{{velocity}}
#if ($xwiki.hasAdminRights())
{{display reference="MyContent.AdminHome"/}}
#else
{{display reference="MyContent.NormalUserHome"/}}
#end
{{/velocity}}
See also isUserInGroup()
, https://www.xwiki.org/xwiki/bin/view/FAQ/HowCanIMakeContentAppearOnlyForASpecificGroup
Thanks Vincent !!
I am not sure if its a valid question but where do i need to make this change like in which file or something??
This code is supposed to be pasted into the wiki home page that you want to customize.
Use the “Wiki editor” to paste the code in the place where it fits your needs. (if you paste this in the WYSIWYG-Editor, this will automatically escape the macro markers {{ … }} so the code to include the content is not executed but displayed verbatim.
You probably want to use the “Preview” and move the code snippet around a few times before it appears where and how you want it. At least that usually is the case when I add code snippets like these.