Posted on: 12/06/04 02:57pm
By: NeoNecro
Hey,
I'm having some questions about plugin development (again).
So, the problem is that every user of one group has a profile (not the geeklog profile, but a new one). When a user of this group enters a page for the first time, his profile is created. This also happens when an admin opens his profiel for the first time. I think this is a rather bad way to do this. Now my question is: is there away to make this profile when a user is added to this group?
Another question I have is: is there a way to delete this profile when the user is deleted?
It would be nice if there's an easy way to do this.
Grtz
Automated action when a user is added to a group.
Posted on: 12/06/04 03:04pm
By: Blaine
There are plugin API calls that are called for all user admin actions.
- create user
- delete user
- user changes there preferences
- user group changed
- user logging in
- user logging out
You can extend the user account info page with your plugins profile options as well.
Automated action when a user is added to a group.
Posted on: 12/07/04 01:02pm
By: NeoNecro
Ok, thank you.
Who do I use these functions? Do I put them in functions.inc and do I call them like this?
plugin_user_create_[pluginname]($uid){code}
So, it are the functions that are used in lib-plugins.php?
Thank you for your help!
Automated action when a user is added to a group.
Posted on: 12/07/04 02:21pm
By: Dirk
Simply implement those functions (only those that you need) in your plugin's functions.inc. Geeklog will call them automatically when e.g. a new user is added.
bye, Dirk
Automated action when a user is added to a group.
Posted on: 12/07/04 03:02pm
By: Blaine
Also - you may want to review the Plugin Developers Guide. It may not have all the updates for the new API's but will explain the basics of plugin development that you need to know.
Automated action when a user is added to a group.
Posted on: 12/07/04 03:59pm
By: NeoNecro
Thank you guys
You're all very helpfull.
I've allready red the plugin developers guide (several times), but I didn't learn much with it. But I really found the Universal Plugin Kit very helpfull (to bad it's so old) and I learnt a lot by looking at other plugins.
I even allready made a plugin, but there was no interest for it and I stopped using it on my site. So I also stopped the develpment of it. But I'm thinking of giving it a new lifen, some day ...
grtz
Automated action when a user is added to a group.
Posted on: 12/12/04 05:47am
By: NeoNecro
I've another question:
If a user is deleted, would this just call the delete user function? Or will it call the delete user function and the group changed function?
grtz