FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » How To » API to programatically add moderators and group leaders ?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
API to programatically add moderators and group leaders ? [message #35430] Wed, 10 January 2007 18:19 Go to previous message
syl20 is currently offline  syl20   France
Messages: 7
Registered: January 2007
Karma:
Junior Member
Hi,

I'm looking for an API or suggestions to add moderators and leaders via scripting.

I need to synchronize users and moderators from an external app.

Reading mysql logs when adding a moderator shows this :

DELETE FROM fud26_mod WHERE user_id=96;
INSERT INTO fud26_mod (forum_id, user_id) VALUES(3, 96);
UPDATE fud26_forum SET moderators=NULL;
UPDATE fud26_forum SET moderators='a:1:{i:96;s:32:\"display name\";}' WHERE id=3;
UPDATE fud26_users SET users_opt=users_opt & ~ 524288 WHERE users_opt>=524288 AND (users_opt & 524288) > 0;
UPDATE fud26_users SET users_opt=users_opt|524288 WHERE id IN(96) AND (users_opt & 1048576)=0;

It seems to be quite complicated. I'm wondering if there's a function to call to do that ?

Thanks,
Sylvain
[Message index]
 
Read Message
Read Message
Previous Topic: Sending pm's via the fud api
Next Topic: backup without database
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Mon Nov 25 04:08:47 GMT 2024

Total time taken to generate the page: 0.04128 seconds