alzander wrote: I would definitely recommend using our existing plugin system to do what you're looking for, unless I'm missing something. If you just want to take the user's social network profile info and store it somewhere else, that's what our SocialProfile plugins are meant for. If you just want profile information stored in the database somewhere, we already have the Custom DB plugin which lets you set what columns of data should be set from the user's profile in an existing table.
Above and beyond all that, the plugin system is not connected to JFBConnect so, if you create a plugin, your code should still work after an update and you won't need to re-do the code when the update is applied.
I hope that helps explain, but if you need anything else, just let us know. More details about what you're trying to do wouldn't hurt either if you need more assistance.
Thanks,
Alex
alzander wrote: Thanks for describing more. I'd recommend creating your own SocialProfile plugin. There's a function called onLogin that you can override and do whatever you want in there.
You can see the parent class in /libraries/sourcecoast/plugins/socialprofile. In that function, you can get access to the Joomla user, social network ID and fetch data from the user's profile.
I hope that helps, but if you need anything else, just let me know.
Thanks,
Alex
alzander wrote: By the time onLogin is called, the user has been created and mapped in JFBConnect and Joomla. You'll want to use the onLogin function to make sure everything is setup properly. It's called pretty quickly in the socialProfilesOnLogin function.
The checkNewMapping is for a special case and not something that needs to be done before the socialProfilesOnLogin call. Everything will be setup by then.
Thanks,
Alex
Join our newsletter to get alerts for Joomla releases, tips and tricks and extension updates.