By Abi on Thursday, 05 May 2016
Posted in General
Replies 4
Likes 0
Views 431
Votes 0
Hi Folks,


(1) How can I create a badge from friends.registered (userpoints) so that a badge is given after 20 friends registered?

(2) I’d like a situation whereby a user will only feature on the leaderboard if s/he has a badge Id 27. i.e. this badge must be in place before the amount of points are considered. How can I achieve this?
../modules/mod_easysocial_leaderboard/tmpl/default.php
../components/com_easysocial/themes/wireframe/leaderboard/default.php


(3) I have a profile type called ‘Patriotic’ and it uses the global Country List, so that a user who selects Patriotic will have to choose one country from the list.
I’d like a situation whereby:-
If profile type chosen is patriotic and country list selection = japan then display japan.png.
If profile type chosen is patriotic and country list selection = China then display china.png etc.

I will have these png files displayed in ../modules/mod_easysocial_leaderboard/tmpl/default.php
.. /components/com_easysocial/themes/wireframe/leaderboard/default.php
../components/com_easysocial/themes/wireframe/profile/default.header.php


Which lines of code can help me to do this?

thd_social_profiles shows that the id is for ‘patriotic’ is 7.

The following is helpful but does not deal with selection from “country List” http://stackideas.com/forums/how-to-check-if-user-have-a-specific-profile-type


(4) I noticed that if User A clicks on the profile of User B and then clicks on Points, s/he is able to see the history of how user B gained points. I want to prevent others from viewing the history of how a person gained their points – how can I do this?
You're welcome.
·
Thursday, 05 May 2016 17:37
·
0 Likes
·
0 Votes
·
0 Comments
·
(1) How can I create a badge from friends.registered (userpoints) so that a badge is given after 20 friends registered?

It sound good to implement this badge in the Easysocial.

By the way, you can try download my attached file and replace into following file location and see how it goes.
JoomlaFolder\administrator\components\com_easysocial\defaults\badges\friends.badge
You have to open this file and look for this badge "friends.registered", change the image name to use your custom image name.

JoomlaFolder\administrator\components\com_easysocial\tables\friendinvite.php

Add following language string into this language file.
JoomlaFolder\administrator\language\en-GB\en-GB.com_easysocial.ini

COM_EASYSOCIAL_BADGES_FRIEND_INVITED_TO_REGISTERED="Friend Registered"
COM_EASYSOCIAL_BADGES_FRIEND_INVITED_TO_REGISTERED_DESC="Loves to invite new friend to join community."
COM_EASYSOCIAL_BADGES_FRIEND_INVITED_TO_REGISTERED_HOWTO="To unlock this badge, you need to get more than 10 of your invited friends to register on the site."


Add following language string into this language file.
JoomlaFolder\language\en-GB\en-GB.com_easysocial.ini

COM_EASYSOCIAL_FRIENDS_BADGE_INVITED_FRIEND_REGISTERED="Invited friend registered on the site"


(2) I’d like a situation whereby a user will only feature on the leaderboard if s/he has a badge Id 27. i.e. this badge must be in place before the amount of points are considered. How can I achieve this?
../modules/mod_easysocial_leaderboard/tmpl/default.php
../components/com_easysocial/themes/wireframe/leaderboard/default.php

Unfortunately that was not possible to achieve this at this point of system.

(3) I have a profile type called ‘Patriotic’ and it uses the global Country List, so that a user who selects Patriotic will have to choose one country from the list.
I’d like a situation whereby:-
If profile type chosen is patriotic and country list selection = japan then display japan.png.
If profile type chosen is patriotic and country list selection = China then display china.png etc.

I will have these png files displayed in ../modules/mod_easysocial_leaderboard/tmpl/default.php
.. /components/com_easysocial/themes/wireframe/leaderboard/default.php
../components/com_easysocial/themes/wireframe/profile/default.header.php


Which lines of code can help me to do this?

thd_social_profiles shows that the id is for ‘patriotic’ is 7.

The following is helpful but does not deal with selection from “country List” http://stackideas.com/forums/how-to-check-if-user-have-a-specific-profile-type

I am really sorry but we are actually quite tied up with our own internal development Easydiscuss 4 + Easysocial 2.0 and we wouldn't be able to assist you with these customizations right now

(4) I noticed that if User A clicks on the profile of User B and then clicks on Points, s/he is able to see the history of how user B gained points. I want to prevent others from viewing the history of how a person gained their points – how can I do this?

You can open this file Joomlafolder\\components\com_easysocial\themes\wireframe\profile\default.header.php

//line 93
<a href="<?php echo FRoute::points( array( 'userid' => $user->getAlias() , 'layout' => 'history' ) );?>" class="btn btn-clean btn-block">

// Replace with
<a href="<?php echo FRoute::points( array( 'userid' => $user->getAlias() , 'layout' => 'history' ) );?>" class="btn btn-clean btn-block" style="pointer-events:none">

So use only can see their personal point history through the drop down toolbar menu.
·
Thursday, 05 May 2016 12:49
·
0 Likes
·
0 Votes
·
0 Comments
·
It seems like my above code for this file is incorrect.
[b]Joomlafolder\\components\com_easysocial\themes\wireframe\profile\default.header.php[/b]

You can download my attached file and replace into above file location.
·
Thursday, 05 May 2016 12:50
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Arlex. As usual, your support is superb thank you. I'll try your solutions. Have a great day. Abi. :-)
Abi
·
Thursday, 05 May 2016 17:28
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post