Support

  1. loft1974
  2. Support
  3. Monday, September 14 2015, 06:00 AM
I have the Jvitals Agora Pro forum installed on my website, and I want to be able to use my easyprofile avatar in the forum component. I figure I am going to manage user Avatars only with the easyprofile component, and therefore I would like to upload the Avatar parameters to the SQL field where Agora Pro stores the avatar.
Is this possible by including an UPDATE or INSERT to this field by modifying the eadyprofile edit profile form?
Thanks
admin Accepted Answer
Admin
Hi,
if there is no integration between Easy Profile and Jvitals Agora Pro you can considering these alternatives:

1. if Jvitals Agora Pro have integration with Jomsocial you can try our to install Jomsocial bridge (here docs: https://www.easy-profile.com/docs/43-jomsocial-bridge.html) and set Agora to catch jomsocial avatar and profile link.

2. You can make a simple plugin to sync avatar when user update his image, try to see this docs: https://www.easy-profile.com/docs/44-triggers.html
- Download, install and enable our skeleton plugin, you can download from https://www.easy-profile.com/docs/44-triggers.html
- open file /plugins/jsn/skeleton/skeleton.php
- remove samples functions: triggerFieldAvatarUpdate, triggerProfileUpdate
- add you function like this:
triggerFieldAvatarUpdate($user,&$data,$changed,$isNew){
$db=JFactory::getDbo();
$query='UPDATE #__your_table SET avatar=' . $db->quote( $data[ 'avatar' ] ) . ' WHERE user_id='. ( int ) $user->id;
$db->setQuery($query)->execute();
}

NOTE: this code is not tested and not supported, this is only for example purpose.
  1. more than a month ago
  2. Support
  3. # 1
loft1974 Accepted Answer
Pro
Thanks for the quick reply.
I can however not get it to work. I am also trying with the Kunena forum, I use:

class PlgJsnSkeleton extends JPlugin
{
Public function triggerFieldAvatarUpdate($user,&$data,$changed,$isNew){
$db=JFactory::getDbo();
$query='UPDATE #__kunena_users,Name SET avatar=' . $db->quote( $data[ 'avatar' ] ) . ' WHERE user_id='. ( int ) $user->id;
$db->setQuery($query)->execute(); }
}
?>

If I do not insert "Public function" I just get a white screen error. When I insert the code above the Avatar image is not inserted into the Kunena Avatar field, and also it is not inserted into the EasyProfile, it says image uploaded but it does not appear.

As for the Jomsocial bridge, that does not seem to work unless I install a complete Jomsocial extension

Any suggestions?

Thanks
  1. more than a month ago
  2. Support
  3. # 2
admin Accepted Answer
Admin
Hi,
sorry for late reply,
If I do not insert "Public function" I just get a white screen error
this is just a sample code to get you on the right way :)

As for the Jomsocial bridge, that does not seem to work unless I install a complete Jomsocial extension
Jomsocial bridge not work with Jomsocial, read docs at https://www.easy-profile.com/docs/43-jomsocial-bridge.html, at this link you will find steps to configure Kunena.

$query='UPDATE #__kunena_users,Name SET avatar=' . $db->quote( $data[ 'avatar' ] ) . ' WHERE user_id='. ( int ) $user->id;
I see an error, you have write "#__kunena_users,Name" instead only "#__kunena_users"
  1. more than a month ago
  2. Support
  3. # 3
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.
Sorry, the discussion is currently locked. You will not be able to post a reply at the moment.

Request Support

Support is currently Offline

Support Availability

Working days: Monday to Friday. The support staff is not available on weekends; in the most of cases tickets will not be answered during that time.

Reply time: Depending on the complexity of your support issue it's usually between a few minutes and 24 hours for paid members and about one week for free members. When we expect longer delays we will notify you.

Guidelines

Before you post: read the documentation and search the forums for an answer to your question.

When you post: include Site Details if you request a support (you can use the form below the reply in Site Details tab).

Auto Solved Question: If after a week the author of the post does not reply to a request by moderator, the question will be marked as resolved.

Language: only English

Search Users

Easy Profile® is not affiliated with or endorsed by Open Source Matters or the Joomla Project. Joomla is Free Software released under the GNU/GPL License.