News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Group Moderators 1.4

Started by Dannii, July 25, 2005, 04:24:08 PM

Previous topic - Next topic

perplexed

hello

I am on RC2 now and I tried to install this today via package manager and it gave me 'test failed' in /sources/managemembergroups.php so I didnt continue as I was not sure what it would do to the forum.

I tried the latest version and then the two previous versions, all with the same error message.  I only installed RC2 today so there should be no problems?

Can you please advise how to fix this?

Thanks

Dannii

FairyPrincess, eventually I would like to, but I'm rather busy right now.
perplexed, do you have any other mods installed?
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

perplexed

Quote from: eldacar on February 12, 2006, 05:58:10 AM
FairyPrincess, eventually I would like to, but I'm rather busy right now.
perplexed, do you have any other mods installed?


yes, lots lol:

1. Ad Managment 1.4.1   [ Uninstall ] [ List Files ] [ Delete ] 
2. Board Notes 1.0.4   [ Uninstall ] [ List Files ] [ Delete ] 
3. Enhanced Move Tag 1.0   [ Uninstall ] [ List Files ] [ Delete ] 
4. Karma On Memberlist 1.0   [ Uninstall ] [ List Files ] [ Delete ] 
5. SMFShop 2.0   [ Uninstall ] [ List Files ] [ Delete ] 
6. Gmail Field 1.1   [ Uninstall ] [ List Files ] [ Delete ] 
7. PJIRC Integrated Chat Mod 2.0   [ Uninstall ] [ List Files ] [ Delete ] 
8. PaypalDonations 1.4   [ Uninstall ] [ List Files ] [ Delete ] 
9. Streaming 4.2.1b 4.2.1b   [ Uninstall ] [ List Files ] [ Delete ] 
10. Show Multiple Badges (Aka Stars) 1.0   [ Uninstall ] [ List Files ] [ Delete ] 
11. Ultimate Shoutbox 1.33   [ Uninstall ] [ List Files ] [ Delete ] 
12. Fly Tag 1.0   [ Uninstall ] [ List Files ] [ Delete ] 
13. Invisible Tag 1.1   [ Uninstall ] [ List Files ] [ Delete ] 
14. EmailFlash 1.0   [ Uninstall ] [ List Files ] [ Delete ] 
15. MessagePreviewOnHover 1.0   [ Uninstall ] [ List Files ] [ Delete ] 
16. Group Moderators 1.2  [ List Files ] [ Delete ] 
17. Enhanced Quick Reply 1.1RC2   [ Uninstall ] [ List Files ] [ Delete ] 
18. Thank You Mod 1.01  [ Apply Mod ] [ List Files ] [ Delete ]   NOT INSTALLED
19. TinyPortal 0.86  [ Apply Mod ] [ List Files ] [ Delete ]  NOT INSTALLED
20. Location Mod 1.2   [ Uninstall ] [ List Files ] [ Delete ] 
21. Karma Description Mod 1.9.4   [ Uninstall ] [ List Files ] [ Delete ] 
22. Sticky First Post (extends sticky topic) 1.2   [ Uninstall ] [ List Files ] [ Delete ] 
23. Users Online Today Mod 1.3.1   [ Uninstall ] [ List Files ] [ Delete ] 
24. Location Mod - Additional Maps 1.2   [ Uninstall ] [ List Files ] [ Delete ] 
25. Location Mod - Who Flags 1.2   [ Uninstall ] [ List Files ] [ Delete ] 





Dannii

#123
One of those are clashing with my mod - I suspect Show Multiple Badges.

There are only 4 (mostly small changes) made to the ManageMembergroups.php file, so you should be able to make them manually:
<operation>
<search position="before"><![CDATA[
// Set variables to their proper value.
]]></search>
<add><![CDATA[
$options = $_POST['elgm_primary'] == '1' ? 'P' : '';
]]></add>
</operation>
That one is simply an extra line. Can't see problems with that.
<operation>
<search position="replace"><![CDATA[
// Do the update of the membergroup settings.
db_query("
UPDATE {$db_prefix}membergroups
SET groupName = '$_POST[group_name]', onlineColor = '$_POST[online_color]',
]]></search>
<add><![CDATA[
// Do the update of the membergroup settings.
db_query("
UPDATE {$db_prefix}membergroups
SET groupName = '$_POST[group_name]', onlineColor = '$_POST[online_color]', GroupModOptions = '$options',
]]></add>
</operation>
That one adds the last option. You can simple add GroupModOptions = '$options', to the end of the line.
<operation>
<search position="replace"><![CDATA[
// There might have been some post group changes.
]]></search>
<add><![CDATA[
// Reset current moderators for this group - if there are any!
db_query("
DELETE FROM {$db_prefix}groupmods
WHERE ID_GROUP = " . (int) $_REQUEST['group'], __FILE__, __LINE__);

// Validate and get the IDs of the new moderators.
if (isset($_POST['groupmods']) && trim($_POST['groupmods']) != '')
{
require_once($sourcedir . '/Groups.php');
insertGroupMods($_POST['groupmods'], $_REQUEST['group'], 1);
}

// There might have been some post group changes.
]]></add>
</operation>
That one is simple, shouldn't have any problems.
<operation>
<search position="replace"><![CDATA[
// Fetch the current group information.
$request = db_query("
SELECT groupName, minPosts, onlineColor, maxMessages, stars
]]></search>
<add><![CDATA[
// Fetch the current group information.
$request = db_query("
SELECT groupName, minPosts, onlineColor, maxMessages, stars, GroupModOptions
]]></add>
</operation>
This one is easy.
<operation>
<search position="replace"><![CDATA[
'allow_delete' => $_REQUEST['group'] == 2 || $_REQUEST['group'] > 4
);
]]></search>
<add><![CDATA[
'allow_delete' => $_REQUEST['group'] == 2 || $_REQUEST['group'] > 4,
'allow_primary' => substr_count($row['GroupModOptions'], 'P') == 1
);

// Group Mods.
$request = db_query("
SELECT mem.memberName
FROM {$db_prefix}groupmods AS mods, {$db_prefix}members AS mem
WHERE mods.ID_GROUP = " . (int) $_REQUEST['group'] . "
AND mem.ID_MEMBER = mods.ID_MEMBER", __FILE__, __LINE__);
$context['group']['moderators'] = array();
while ($row = mysql_fetch_assoc($request))
$context['group']['moderators'][] = $row['memberName'];
mysql_free_result($request);
]]></add>
</operation>
This one is kind of major. Firstly add 'allow_primary' => substr_count($row['GroupModOptions'], 'P') == 1 to the array. If you have others there after allow_delete, do NOT remove them. Then add the bottom code block straight after. Shouldn't be any problems there.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."


Harelin

Requesting to join membergroups is a good idea.

I'd have to say my wish list for this mod is, in order of preference,
1) Ability for group moderators to mass PM/email their groups
2) Ability for members to request to join groups
3) Ability to cluster membergroups under categories, so that if you have a large number of membergroups... changes can be made on a mass scale rather than having to go through each membergroup and adjust the group moderator manually.
4) Ability for group moderators to have their own static page (like the static page mod) that they can edit, would tie in nicely with the join request feature.

Just some ideas.

Ohmer

Oh, if it's the requesting day, I will request one thing also :)

I would like to assign a group as moderator of a board instead of a member name.

Dannii

#127
Harelin, already had all of those, except for the cluster idea. interesting...
Ohmer, you can do that already through local board permissions. They won't get stars, but they will still be able to mod the board.

Perplexed, you could do so, but it's unlikely that the other mod would install properly if you install this one first.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

Ohmer

Quote from: eldacar on February 12, 2006, 10:01:44 PM
Ohmer, you can do that already through local board permissions. They won't get stars, but they will still be able to mod the board.

Yes I know.  But local permissions with many forums is not the ideal solution.  It's what I do, but I would like use only global permissions and groups moderators.

perplexed

Quote from: eldacar on February 12, 2006, 10:01:44 PM
Harelin, already had all of those, except for the cluster idea. interesting...
Ohmer, you can do that already through local board permissions. They won't get stars, but they will still be able to mod the board.

Perplexed, you could do so, but it's unlikely that the other mod would install properly if you install this one first.

I had to uninstall nearly all the mods so  I could install the arcade yesterday lol so I reinstalled group moderators first and now it works perfectly.  Thanks

FairyPrincess

#130
Quote from: eldacar on February 12, 2006, 05:58:10 AM
FairyPrincess, eventually I would like to, but I'm rather busy right now.

Eldacar, I understand how that can be (getting very busy). You seem to spend lots of time sharing your help for the SMF community, and I appreciate your efforts! If you do ever get the time and create it I'll be one happy camper. Thanks again!

That which we persist in doing becomes easier, not that the task itself has become easier, but that our ability to perform it has improved.
   -Ralph Waldo Emerson

passenger

#131
Hello im hoping to get some help with installing the mod.

Just upgraded to 1.0.6, no other mods installed, i get the same problem as ruth before when running the install package some files are success and the others nothing. Same chmod problem asking for ftp access which by the way dosent do anything. Only change i made to the files was adding the install for 1.0.6 in the info xml.

The thing is even the installation of smf caused me problems, ive only been able to install themes without a problem, all other files ive been installing and chmoding them manually . So i take it is a bug.

Also I uploaded the remaining files and changed the permissions to 777 and tried to run GroupMods_install.php manually and the following error happend:

Fatal error: Call to undefined function: db_query() in /GroupMods_install.php on line 5

So big question is... how can i install the mod manually, and which files must set permissions?

Thanks a lot

Dannii

"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

dracomiconia

Waiting for upgrade to 1.06... I have almost 50 membergroups.... :D :D :D :D

dracomiconia

Is there any new in this mod?

Dannii

Version 1.3c has been released
el_groupmods_13c_r13.tar.gz
changelog.txt

This should be 1.0.6. I haven't tested it though. Let me know if you have any problems.
This also should be MySQL 5 compatible.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

dracomiconia

Thank u very much.

This afternoon it will be installed (I will tell u)

MadPax

OK my question about this is:

There's no menu coming up after installation to access the mod. Where's the actual link to access it if you're admin or moderator?

I managed to get to it by doing action=groups, but there should certainly be a place to get there. I checked the code and didn't find anything that would display a link on the main menu. Is that possible to do?

Thnks.

Otherwise I might have to get rid of the smf menu and use the Joomla one.

Dannii

There is a menu button in bablyon (default for < 1.1RC2) and core.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

dracomiconia

Runs in 106 with no problem....

Advertisement: