Joomla User Registration form with custom fields

M.Abletech 04 Apr, 2018
Hi,

I wish I can add also custom fields ( as Company ) in Chronoform ( v5 or v6) to Joomla user registration.

Any tips?

Miriam
healyhatman 04 Apr, 2018
Answer
1 Likes
In your joomla menu, go Users->Fields and add the fields you want. Take note of the id of the field, on the right.

It's stored in [prefix]_fields_values.
field_id: the id number I told you to look for
item_id: the user's id
value: the value you want to save.
In your chronoforms submit event, AFTER you have saved the user, you need a save data action - database table [prefix]_fields_values, data override on Insert field_id:id_you_want
item_id:{user:id}
value:{data:fieldyouwant}


And do it in CF6
M.Abletech 04 Apr, 2018
Thanks!

I've done as you said: only on issue.
item_id:{user:id} is not getting any value.

http://prntscr.com/j0q62t

I'm probably missing something... How can I pass it ?
I've put the SAVE DATA action after SAVE USER action

http://prntscr.com/j0q9hd

Thank you @healyhatman !
healyhatman 04 Apr, 2018
1 Likes
Maybe Save User, then Log In user, THEN save data?

OR: {var:joomla_user2.id} replacing "joomla_user2" with the name in the black label of your save user action? (looking at your screenshot, should just be joomla_user2). Put a debug after Save User and see if there's a user id in the data.
M.Abletech 04 Apr, 2018
1 Likes
GREAT healyhatman!!!!!!

I've used {var:joomla_user2.id} because users are not unable by default but they need admin validation, so no login is possible.

Thank you so much, you helped a lot!
mediandmore 23 Apr, 2018
Hi there,
I have the same problem.
Can't figure out how to put the custom fields in the Data Override -> Save User Action.
And, the activation link/user, how to add on the email the activation link?

Thanks and best regards
This topic is locked and no more replies can be posted.