Buy Now
Sign in

User Registration to a higeher Level

galbur , June 13 at 10:33
G
galbur
Hi
I have a simple Form for users to register to have access to certain aerea. > Joomla User Group "specialaccess"
The registered users can also become a member of the community.
Then they have to fill out a more complex form.
When i use a new form for this, then i got an error message "this email already exist".
So i want to have the possibility that logged in users can go to a new form with the prepopulated fields from their account "specialaccess".
How can i do this?
Thank you Christoph
H
healyhatman
Don't save a new user.
You need a save data action, for the table prefix_user_usergroup_map​
​Data to insert:
user_id:{user:id}
group_id:10 <-- or whatever the id of the group you want to put them in is.
You can use a delete data action to remove them from the old user_usergroup_map if you want.
Web developer at SkySpider.com.au
I don't work for ChronoEngine but I do accept donations paypal.me/healyhatman
G
galbur
Hi healyhatman
Thank you very much for helping.
But it's a little bit more complicated than i thought ;-)
I have an extension called easy profiles. This Extension expands the possiblities of ##_users. So i can build some Extrafields.
So when a user register the first time he has to fill out
the joomla minimum (username, name, password, email)
and a few extrafields (Street, Location, Zip-Code) via Easyprofiles.
The two tables are connected via user id.
Now if a registered user is logged in and he wants to become a member, he should come to a new form with some extrafields and prepopulated "Standardfileds" with data from ##_users (joomla standard user table) and ##_jsn_users (Easy Profile Table).
After submit the usergroup should change.
Best regards
Christoph
H
healyhatman
You only need to populate and use those fields if you want the user to change them.
Either way use read data to get the value of the fields and {var:read_data#.model.field} as the field value
Web developer at SkySpider.com.au
I don't work for ChronoEngine but I do accept donations paypal.me/healyhatman
G
galbur
Hi
Thank you and sorry. I'm not really a php-crack. But i'm still trying to figure out how it works;-)
But somehting went wrong.
I did the following:
I have two DB Read Actions in the OnLoad Section before HTML Rendering
1. User Joomla Table DB Read
db_read_users.png
2. Easy Profile DB Table Read
db_read_jsn_users.png
Then i used the following as Field Value
read_data.png
And when i test the form it looks like
form.png
Attachments
db_read_users.png
db_read_users.png
(154.11 KiB)
25 Downloads/Views
db_read_jsn_users.png
db_read_jsn_users.png
(153.31 KiB)
25 Downloads/Views
read_data.png
read_data.png
(26.6 KiB)
27 Downloads/Views
form.png
form.png
(24.21 KiB)
25 Downloads/Views
H
healyhatman
Replace the hash with the right number, look at your read_data action for the name. Black label.
Web developer at SkySpider.com.au
I don't work for ChronoEngine but I do accept donations paypal.me/healyhatman
G
galbur
Hi
And thank you again!
This Number?
dbread22.png
I used
{var:read_data22.Data_EP.firstname}
as field Value, But with no effect.
Christoph
Attachments
dbread22.png
dbread22.png
(63.75 KiB)
24 Downloads/Views
H
healyhatman
Sorry I just realised you're using the old v5, I thought we were talking about V6. Can't help you with v5 you'll have to look at the instructions.
Web developer at SkySpider.com.au
I don't work for ChronoEngine but I do accept donations paypal.me/healyhatman
G
galbur
Ok
Thank you anyway....
Christoph
GreyHead
Hi Christophe,
Please see this FAQ. Once you have the User ID you can look up the corresponding data from the tables.
Bob
ChronoForms technical support
If you'd like to buy me a coffee or two, thank you very much