[PHP]core.ucp.profile_on_change.php

Request hook events and what data needs to be sent for the new hook system.
Post Reply
roelandaernoudts
Registered User
Posts: 7
Joined: Sun Feb 09, 2014 6:25 pm

[PHP]core.ucp.profile_on_change.php

Post by roelandaernoudts »

Code: Select all

Identifer: core.ucp.profile_on_change.php
Location: ucp.profile.php
Parameters: before function main ($id, $mode)
Explanation: For different other platforms that attempt to integrate phpbb3, there are no hooks available that allow an update initiated from phpbb3 to another platform.
Some more explanation: I have been working on further development of rokbridge, a joomla component which bridges joomla and phpbb3, the problem I have run into is that there is no hook for updating users. For example when a user updates a password or changes username. From joomla its events it is pretty easy to make updates to the phpbb3 user using the joomla events. I am now writing a hook to fire an event in joomla to be able to change user info within joomla when user information is altered in phpbb3. However it requires changes to the phpbb3 core, which I prefer not to make. If there would be a hook available, then this could be easily used. I found an example of a hook that allows firing an event that deletes a user in for example joomla (see for example: http://www.ramonfincken.com/155/PHP+cod ... ndard.html)
I would really like to see a hook for an update user information event. I think it will be beneficial to all other platforms that try to bridge or integrate with phpbb3 (Drupal, Wordpress).
I hope I did not put this request in the wrong place, and if I did, please move it to the right place.
I first posted this in the wrong place and with the wrong information. I hope I got it right this time round (or at least did better) :D
Thanks for developing this incredible platform!

User avatar
rxu
Registered User
Posts: 168
Joined: Tue Apr 04, 2006 4:28 pm
Contact:

Re: [PHP]core.ucp.profile_on_change.php

Post by rxu »

roelandaernoudts, I think it's hardly possible to add an event before the function main() because this is the class definition area, so there's nowhere to get phpbb dispatcher object instance.
Could you take a further look at the ucp_profile.php, probably it will work if adding an event within mode cases, f.e. under case 'reg_details': block (say, after the $data and $sql_ary definitions).
Unless I've misunderstood the whole point, which is also possible.
Last edited by rxu on Thu Jan 22, 2015 3:32 pm, edited 2 times in total.

roelandaernoudts
Registered User
Posts: 7
Joined: Sun Feb 09, 2014 6:25 pm

Re: [PHP]core.ucp.profile_on_change.php

Post by roelandaernoudts »

No, you have understood it exactly! Thanks for your reply and the suggestion!


User avatar
rxu
Registered User
Posts: 168
Joined: Tue Apr 04, 2006 4:28 pm
Contact:

Re: [PHP]core.ucp.profile_on_change.php

Post by rxu »

Related to event request viewtopic.php?f=111&t=33744

Post Reply