mxm Content Rules
It does not overrule the permission you set in the portal_types tool. It only limits what content types that appear in the dropdowns.
This approach also has the (dis)advantage that it is not a permission issue. It is entirely an interface tool, for making the site simpler to use for members.
You can "allow" or "deny" content by path and content type. The general syntax is:
RULE COLON PATHS SEMICOLON PORTALTYPES
- RULE is either "allow" or "deny" (case does not matter)
- PATHS is one or more paths relative to the portal. "/" is portal root. "/Members" is the member folder. Paths are seperated by commas.
- PORTALTYPES is either a valid portal_type like "Document" or "Folder", or a wildcard meaning any type.
- A line with a "#" anywhere in it, is a comment. Not only in the beginning.
The default rule is to allow all content anywhere. It looks like:
allow: /; *
If you write nothing in the "content_rules" property, this will be the effective rule. So if you are ever in doubt, just delete all rules, and the site will works af if the tool was not installed.
If you want a site where it is only possible to add Folders and Documents in member folders, you can use these rules:
# first deny all portal types in the member folders deny: /Members; * # then allow some types for all members allow: /Members; Document, Folder # and also allow news articles and images for the members "maxm" and "bob" allow: /Members/maxm, /Members/bob; News Item, Image
The rules are checked sequentially.
Download from the download section here
Last modified 2005-01-26 12:21 AM