1. blocdaddy
  2. General
  3. Friday, May 10 2019, 12:40 AM
  4.  Subscribe via email
In Easy Profile in the users map module (mod_jsnmap), I would like to change the user avatar to show three different icons/pins for three different Joomla usergroups. I found this similar post which seemed to indicate it was possible:

I created a file called "custom.php", entered the code and the links to the three new image icons at line 117, selected "custom" and "avatar" as the module selections in the backend, but the custom icons didn't appear on the map.

The code I used is below. Can you please let me know what I'm doing wrong?

Changed line 117 from:

url: '<?php echo JURI::root(true).'/'.$user->getValue('avatar_mini'); ?>'


url: '<?php
if( $user->getValue('group_id') == '13' ) echo '';
if( $user->getValue('group_id') == '12' ) echo '';
if( $user->getValue('group_id') == '11' ) echo '';

If this is not possible I would just like to change the default red location pin to my own image. I tried changing the link in default.php at line 162 from '' to my own url but it didn't change. Is there a way to do this? Thanks!!
admin Accepted Answer
getValue function return the value of the Easy Profile field, to get usergroups try with a code like this:
url: '<?php 
if( in_array( 13 , $user->getAuthorisedGroups() ) ) echo '';
if( in_array( 12 , $user->getAuthorisedGroups() ) ) echo '';
if( in_array( 11 , $user->getAuthorisedGroups() ) ) echo '';
  1. one week ago
  2. General
  3. # 1
blocdaddy Accepted Answer
This works perfectly!! Thank you so much!!

I have one last question:

I would like to have the map module in position above the search box on my user search page (page generated by users list menu item). Right now I have the backend setting to randomly display two users on the page at all times even with no search. When the map is published above the search box, if you scroll down the page to where the map is out of view and then scroll back up to the top where the map is, a popup profile display of one of the two users automatically opens. Is there a way to disable this feature? I still want the popup box to show when users click on the specific user avatar, but not popup automatically at all. Thanks!!

Although the map module is unpublished right now, you can see the page that I'm referencing here:
  1. one week ago
  2. General
  3. # 2
admin Accepted Answer
sorry for late reply, it's a weekend :D

You can do this with template overrides:
- Open your file "custom.php" from template folder (created to have 3 different avatars)
- At line 129 replace "mouseover" with "click" function.

NOTE: of course if you click to avatar or username then it open profile page.
  1. one week ago
  2. General
  3. # 3
  • Page :
  • 1

There are no replies made for this post yet.
However, you are not allowed to reply to this post.

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.


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.