Thread:Project:Support desk/Permission to edit pages only if that user belongs to that group/reply (2)

Hi, First of all thanks for replying, I tried creating a custom namespace and created a page (yyy group), but even the user who belongs to "xxx" was able to edit, below is the setting that i used, please let me know where I have gone wrong.

require_once( "$IP/extensions/Lockdown/Lockdown.php" ); $wgGroupPermissions['*']['edit'] = false; $wgEmailConfirmToEdit = true; $wgGroupPermissions['user']['edit'] = false; $wgGroupPermissions['*']['createpage'] = false; $wgGroupPermissions['user']['createpage'] = false; $wgGroupPermissions['*']['createaccount'] = false;

$wgGroupPermissions['YYY'] = $wgGroupPermissions['user']; $wgGroupPermissions['YYY']['delete'] = true; $wgGroupPermissions['YYY']['protect'] = true; $wgGroupPermissions['YYY']['patrol'] = true; $wgGroupPermissions['YYY']['purge'] = true; # delete the cache of a page $wgGroupPermissions['YYY']['edit'] = true; $wgGroupPermissions['YYY']['createpage'] = true;
 * 1) Start with assigning the default permissions from group "user"

$wgGroupPermissions['XXX'] = $wgGroupPermissions['user']; $wgGroupPermissions['XXX']['delete'] = true; $wgGroupPermissions['XXX']['protect'] = true; $wgGroupPermissions['XXX']['patrol'] = true; $wgGroupPermissions['XXX']['purge'] = true; # delete the cache of a page $wgGroupPermissions['XXX']['edit'] = true; $wgGroupPermissions['XXX']['createpage'] = true;
 * 1) Start with assigning the default permissions from group "user"

define('NS_YYY', 100); define('NS_XXX', 101); $wgExtraNamespaces[NS_YYY] = 'yyy'; $wgExtraNamespaces[NS_XXX] = 'xxx'; $wgNamespacePermissionLockdown[NS_YYY]['read'] = array('yyy'); $wgNamespacePermissionLockdown[NS_YYY]['edit'] = array('yyy'); $wgNamespacePermissionLockdown[NS_YYY['createpage'] = array('yyy');
 * 1) define constants for your custom namespaces, for a more readable configuration
 * 1) define custom namespaces
 * 1) restrict "read" permission to logged in users

$wgNamespacePermissionLockdown[NS_XXX]['read'] = array('xxx'); $wgNamespacePermissionLockdown[NS_XXX]['edit'] = array('xxx'); $wgNamespacePermissionLockdown[NS_XXX['createpage'] = array('xxx');

$wgNonincludableNamespaces[] = NS_YYY; $wgNonincludableNamespaces[] = NS_XXX;
 * 1) prevent inclusion of pages from that namespace

Thanks Chethan K