just a thing that I thought of when I wrote my .pun.. actually I really miss that you can't make punmod replace ALL occurence of a string

If PunMod finds your search text in more than one    location, it will produce an error

which is good if that's not what you intended, but you should be able to do it.. maybe a command like: "FINDALL" or something?

XuMiX wrote:

well, probably it would be better to make so, to maintain original structure, or punmod does not support this kind of expressions ?
multigroup.pun...

##SQL PGSQL
        ALTER TABLE <prefix>users ADD membergroupids VARCHAR(64)
##SQL MYSQL
ALTER TABLE `<prefix>users` ADD `membergroupids` VARCHAR(64) AFTER `group_id`

whops, I didn't read that far in the readme roll

mindplay wrote:

neat smile

I'll integrate these changes into the next release of PunMod, thanks.

Please note that PunMod is still in beta phase, and some things will change - you will probably need to update the mod for the next version of PunMod ... as a minimum, you will be required to add ##UNSQL commands, you can read more about that in this thread, if you're not already following it:

http://punbb.org/forums/viewtopic.php?pid=30716#p30716

well, I kinda followed it, but I thought I'll let you guys decide what the format smile

added one sql for mysql and one for pg now..

ahh.. I've only tested it on mysql, not used to things that works on more than one DBMS smile thanks!
(fixed in version 0.11b)

What?
ok, this is the first punbb mod I ever release, so use it at your own risk wink anyways, this mod enables you to make a user member of more than one group, if you couldn't make that out from the topic smile the user still has a primary group that is "his/her group", the only time punbb uses the additional groups you have selected is for the read/post reply/post topic permission (i.e it's only used for forum permissions).. because of this you cannot select "Moderator" or "Administrator" as an additional group, they have to be the primary one..

How?
To install the mod you'll need:
* PunBB 1.2 (final, not the beta)
* punmod (tested with version 0.9.4)

I had to tweak punmod to make it work properly with PunBB 1.2 (if you're really wild n crazy you can try punmod 0.95beta). The things I needed to change was in _punmod/_punmod.php:
After (line 10-15)

$PUNMOD_MODE = -1;
$PUNMOD_ERROR = null;

$pun_root = './';

add

define('PUN_ROOT', $pun_root);

and after (line 20?)

define('PUN_TURN_OFF_MAINT', 1); // circumvent maintenance mode.

add

error_reporting(E_ALL ^ E_NOTICE);

which makes the first part of the file look like:

<?php

define('PUNMOD_FOLDER',   'punmods');
define('PUNMOD_REGISTRY', PUNMOD_FOLDER.'/_installed_mods.txt');
define('PUNMOD_APPLY',    0);
define('PUNMOD_VERIFY',   1);
define('PUNMOD_GETINFO',  2);
define('PUNMOD_ENGINE',   1);

$PUNMOD_MODE = -1;
$PUNMOD_ERROR = null;

$pun_root = './';

require $pun_root.'include/common.php';

if (!defined('PUN_DEBUG'))
    define('PUN_DEBUG', 1); // complete error message from PunBB on failure.

define('PUN_TURN_OFF_MAINT', 1); // circumvent maintenance mode.

error_reporting(E_ALL ^ E_NOTICE);

$mod_registry = array();

Then just follow the punmod instructions in the readme.txt:

1. Copy everything from the "upload" folder to your PunBB root folder.
2. Copy any mods you wish to apply into the "punmods" folder.
3. Ensure that PHP has write access permissions in PunBB folder and subfolders.
4. Open your browser to "punmod.php" and follow the on-screen instructions.

After the installation is finished you'll end up with a new listbox under the "Administration" page of the user profile. Hold down ctrl and select the group(s) the user should be member of, click "Save" and hopefully it works wink

Where?
Grab it here!

Disclaimer
This mod changes the PunBB source heavily and it might:
1) destroy your forum totally
2) crash your server
3) steal your girlfriend

although this didn't happen to me you never know wink


and btw, post here if you have any ideas or if it doesn't work...

5

(5 replies, posted in Feature requests)

Cornflake wrote:

Maybe you should write it as a mod, that way people who want it could use it, but people who didn't could use the current system.

true.. i'll submit it if i end up using punbb then..

Rickard wrote:

That wasn't what I meant. I meant that most people want PunBB to remain light and fast and that the more features we add, the further away from that we end up. I suspect very few of PunBB's current users will have any use for the feature you speak of and that will make it a hard sell. You should know I was sceptical towards adding the user groups at all initially.

yeah, i read about how you wanted punBB, but i thought you liked user groups since you added them, and my suggestion would "just" add 1 extra column/user and a few lines of php.. but i know, that's what everyone says smile

6

(5 replies, posted in Feature requests)

ok, will you add it if i submit a patch?

7

(5 replies, posted in Feature requests)

Just installed 1.2-beta and the first thing i really miss is that a user can't be member of more than one group.. really irritating if you for example have > 1 forums that are restricted to a group and some users need access to > 1 of these..

one way to do it is like VB does: you have one column (usergroupid) for the primary user group and another column (membergroupids) with a comma separated list of other groups..