1. dikau
  2. Presales Question
  3. Monday, October 01 2018, 10:51 AM
Hi,
I'm interested on buying your component, but need to know some features first.

So basically I want a field that auto generated based on other field, example:
We have a "User event number" field that we want the value (string) based on combining joomla user id and register date and etc...

is that possible with Easy profile?
admin Accepted Answer
Admin
Hi,
sorry but Easy Profile does not do this natively, anyway you can build a simple plugin that do this, you can also try it in free version, please follow these steps:
- Download, Install and Enable Skeleton Plugin (you will find it at http://docs.easy-profile.com/index.php/article/triggers)
- Open file /plugins/jsn/skeleton/skeleton.php
- remove samples functions: triggerFieldAvatarUpdate, triggerProfileUpdate
- add function like this:
public function triggerProfileUpdate($user,&$data,$changed,$isNew){ 
$user_id = $user->id ;
$user_date = $user->registerDate ;
$data['ALIAS_OF_CUSTOM_FIELD'] = md5( $user_id . $user_date ) ;
}
This code will be triggered when user update/register own profile.
This code will store in field with alias "ALIAS_OF_CUSTOM_FIELD" a simple hash of value that depends from ID and Registration Date of the user.

NOTE: This code is not tested and not supported, this is only for example purpose. You need to have a minimum of PHP knowledges
  1. more than a month ago
  2. Presales Question
  3. # 1
dikau Accepted Answer
Hi,
That's awesome... Im gonna try it tonight when i got home.

One last question: Can we disabled editing of some fields? So, user can only edit their profile on selected field only?

Thank you
  1. more than a month ago
  2. Presales Question
  3. # 2
admin Accepted Answer
Admin
Hi,
you can set some fields to not be available in Edit Profile page.
  1. more than a month ago
  2. Presales Question
  3. # 3
  • Page :
  • 1


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