Hi Andreas,
This was very helpful.
Indeed it requires including the document in each page. (except for pages that
are object based; like Blog) then it only requires the Sheet/Template document
I wonder if there is not a Sheet/Template like document where you could include
this
thx
Gerritjan
Op 10 mei 2011, om 22:29 heeft Andreas Hahn het volgende geschreven:
> Hi Gerrit,
>
> i can give you a partial anwer to your questions as I have also been
> struggling to adapt look & feel of one of my sites.
>
> I tried as much as possible not to change the code in the VM templates
> as this requires access to the server and makes it harder to document
> all the places and survive a version upgrade.
>
> Basically I've created a page containing a velocity macro that contains
> all the restrictions.
> This page needs to be included in all pages where the restrictions shall
> apply.
> The restrictions are just css selectors to suppress visibility:
>
> {{velocity}}
> #if (!$hasEdit)
> {{html clean="false"}}
> <style>
> #hierarchy {display:none;}
> #document-title {display:none;}
> #mainmenu .leftmenu {display: none;}
> #contentmenu {display: none;}
> </style>
> {{/html}}
> #set ($docextras= "[]")
> #end
> {{/velocity}}
>
> No hierarchy, document-title, e.t.c. if you have no editing rights ,
> e.g. you are not logged in.
> However you need to include the page on all pages where the restricitons
> shall apply:
>
> {{include document="Main.Restrictions"/}}
>
> You might have a look at the results at http://shept.org
>
> enjoy
>
> Andreas
>
>
> Am 10.05.2011 13:27, schrieb Gerritjan Koekkoek:
>> Hi,
>>
>> I'm looking into 'how to modify parts of the userinterface' of XWiki for a
>> specific site/application
>> We would like to achieve this with minimal impact/effort and stick to the
>> colibri-skin as close as possible
>>
>> the following interface elements are of interest to us;
>> The MENU-Bar's; both on the top of the screen as well as the one on top of a
>> document,
>> The Box that contains Comments, Attachments, History and Information
>> The top of the document that shows Document navigation hierarchy, the
>> document name or title the last modified and the summary of Comments,
>> Attachments
>>
>> With regard to menubar;
>> We would like to be able to add, show or hide elements depending on the Role
>> and rights of the user AND the nature of the document
>> Role; If user is a guest, author, moderator (typical roles you find in a
>> Content Management System
>> Rights; Has Edit Rights
>> Document nature; if document is only velocity (like livetables, scripted
>> page etc..) -> maybe this should be managed by rights?
>>
>> The Box that...
>> Document nature; if a document is scripted we would like to hide the box, so
>> only real content pages should show that box
>>
>> The top of a document
>> Document nature; If document nature is script; title, last modified by and
>> summary of box makes no sense
>>
>> My question is what would be the best place(s) to do these things? What is a
>> good source of information to learn about these elements and best practises
>> to learn to modify them
>> (which API functions do work on these elements)
>> The VM template "menuview" seems to contain the structure of the menubars;
>> is this the place to influence the behaviour
>> It also contains #xwikitopmenuentrystart, #submenuitem etc.. where are these
>> things defined (and/or documented)?
>>
>> thx
>> Gerritjan
>> _______________________________________________
>> users mailing list
>> [email protected]
>> http://lists.xwiki.org/mailman/listinfo/users
>>
>
> _______________________________________________
> users mailing list
> [email protected]
> http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users