Tags:
access_control1Add my vote for this tag skin1Add my vote for this tag users1Add my vote for this tag create new tag
, view all tags

Question

Would it be possible to set a skin specific to a group rather than to a user?

Example:

  • default skin for myweb = customskin
  • skin for members of group AuthorGroup = customskin1
  • skin for members of group PowerGroup = customskin2
  • etc.
And would it be possible to override the group specific skin through a per usersetting?

So the desired order (lowest to highest priority) would be:

  • skin set in TWikiPreference
  • skin set in WebPreference
  • skin set in TopicPreference
  • skin set in GroupPreference
  • skin set in UserPreference

Note: This question was raised in HowToDisableEditIfNoLogin

Environment

TWiki version: TWikiRelease02Sep2004
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS:  
Web server:  
Perl version:  
Client OS:  
Web Browser:  
Categories: Installation, Permissions, Authentication, Security, Authorisation, Skin

-- WolfgangAlper - 23 Feb 2005

Answer

I solved this by creating a custom skin with the following:

ALERT! Note: I reformatted this to make it readable, but it needs to all be on one line in the code!

%TMPL:INCLUDE{"view"}%

%TMPL:DEF{"topbarcontents:logo"}%<span id="twikiLogo" class="twikiImage"><a href="%WEBLOGOURL%">
<img src="%WEBLOGOIMG%" border="0" alt="%WEBLOGOALT%" style="border:none;" /></a></span>%TMPL:END%

%TMPL:DEF{"topbarcontents"}%<div class="twikiTop">%TMPL:P{"topbarcontents:logo"}%%TMPL:END%

%TMPL:DEF{"topicactionbuttons"}%
%IF{"$WIKINAME ingroup 'ContributorGroup'" then='$percntTMPL:P{"action_activatable_edit_or_create"}$percnt' else=""}%
%IF{"$WIKINAME ingroup 'ContributorGroup'" then='$percntTMPL:P{"action_activatable_attach"}$percnt' else=""}%
%TMPL:P{"action_printable"}%%TMPL:P{"action_revisions"}%
%IF{"$WIKINAME ingroup 'EmployeeGroup'" then='$percntTMPL:P{"action_backlinks_simple"}$percnt' else=""}%
%IF{"$WIKINAME ingroup 'EmployeeGroup'" then='$percntTMPL:P{"action_raw_or_view"}$percnt' else=""}%
%IF{"$WIKINAME ingroup 'ContributorGroup'" then='$percntTMPL:P{"action_activatable_raw_edit"}$percnt' else=""}%
%IF{"$WIKINAME ingroup 'ContributorGroup'" then='$percntTMPL:P{"action_activatable_more"}$percnt' else=""}%
%TMPL:END%

%TMPL:DEF{"top:toolbarbuttons"}%
%IF{"$WIKINAME ingroup 'ContributorGroup'" then='$percntTMPL:P{"activatable_edit_or_create"}$percnt' else=""}%
%IF{"$WIKINAME ingroup 'ContributorGroup'" then='$percntTMPL:P{"activatable_attach"}$percnt' else=""}%
%TMPL:END%

The Revisions don't work in an IF Statement, though. If anyone firgures that part out, I'd love to see it!

-- JamieBenjamin - 2009-04-09

Can somebody give me a advise, where is this code located? I guess it is the same place, where should be written the command %TMPL:DEF{"viewleftbar"}%%TMPL:END% from the topic TWiki/PatternSkinCustomization#I_want_to_hide_the_left_bar but where is it ??? Thanks Jaromir Houdek

-- JaromirHoudek - 2009-04-24

Jaromir: Per the instructions in PatternSkinCustomization , I created a new template. Then I looked at (but did not modify) the pattern.view.tmpl file to get the syntax and I copied the parts I needed into my new template before making any modifications. When I was finished, I uploaded my new template to the template directory, and changed the WebPreferences to point to mytemplate,pattern.

-- JamieBenjamin - 2009-04-27

Thank you Jamie, I obtained the rights for work inside PC where TWiki is installed and the things improved. The admin rights for TWiki are not sufficient for the page customization smile

-- JaromirHoudek - 2009-04-28

My question from 4/9/2009 still stands. Anyone know how to restrict view access to the Revision History? Many thanks.

-- JamieBenjamin - 2009-05-11

Closing this question after more than 30 days of inactivity. Feel free to reopen if needed. Consider a subscription for support or engage one of the TWiki consultants if you need timely help.

Best to open a new support question with details.

-- PeterThoeny - 2009-07-05

 
Topic revision: r9 - 2009-07-05 - 19:34:05 - PeterThoeny
 

Support

share: Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon
Twiki, Inc.
This site is powered by the TWiki collaboration platform
Ideas, requests, problems regarding TWiki? Send feedback
Copyright © 1999-2010 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.