12345678910 |
- version=pmwiki-2.1.1 ordered=1 urlencoded=1
- agent=Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.8) Gecko/20051128 SUSE/1.5-0.1 Firefox/1.5
- author=Pm
- csum=more link spacing cleanup
- host=24.1.26.255
- name=PmWiki.PerGroupCustomizations
- rev=23
- targets=PmWiki.WikiGroup,PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.PasswordsAdmin,PmWiki.WikiFarms,PmWiki.DocumentationIndex
- text=%25audience%25 administrators (intermediate)%0aOne of the purposes of [[WikiGroup]]s is to allow a [[Wiki Administrator]] to customize the features of PmWiki on a per-group basis. Here is where ''per group customizations'' come into play.%0a%0aThe ''local/'' subdirectory (in the same directory that holds ''pmwiki.php'') is used to hold local configuration files. To perform [[local customizations]] for a particular WikiGroup, place the customizations in a file called "''%3cgroupname>.php''" (where ''%3cgroupname>'' is the actual name of the page group in question) in the ''local/'' subdirectory. This file will be automatically processed after processing any local customizations in the ''config.php'' file.%0a%0aFor example, to change the image displayed in the upper-left corner of pages in the "Chess" WikiGroup, one could create ''local/Chess.php'' containing%0a%0a %3c?php%0a $PageLogoUrl = "/myimages/chess.gif";%0a%0aThis would cause all pages in the Chess [[Wiki Group]] to use "/myimages/chess.gif" as the logo image instead of the default.%0a%0aAlmost any customization that would be placed in ''config.php'' can be used as a per-group customization.%0a%0a[[#PerPage]] PmWiki also allows per-page customizations, simply use the full name of the page to be customized instead of the group. For example, one can use the file ''local/Chess.`HomePage.php'' to set local customizations for Chess.`HomePage.%0a%0aFor all local customizations, PmWiki first processes the ''local/config.php'' file, and then looks for a per-page customization file in the ''local/'' subdirectory to process, followed by any per-group customization file. If no per-page or per-group customizations are loaded, then PmWiki loads ''local/default.php''.%0a%0aAny customization file can set $EnablePGCust=0; to prevent later page/group/default customizations from being automatically loaded. If a per-page customization needs to have the per-group customizations loaded first, it can do so directly by using PHP's [@include_once()@] function.%0a%0aAny passwords required for a group should be set in the group's `GroupAttributes page (see [[PasswordsAdmin]]) and not in a group customization file. %0a%0a[[Wiki Group]]s are an easy way to host multiple sites in a single PmWiki installation by giving each site its own group. Another approach is to use [[Wiki Farms]], which allows each site to have its own set of WikiGroup and local customization files. If you're hoping to add several levels of groups, [[PmWiki:HierarchicalGroups|read this first]].%0a%0a%25trail%25 %3c%3c|[[Documentation Index]]|>>
- time=1142464534
|