Yup, but why are you needing a copy of the email address in a second field? You should be able to just use a [FIELD_NAME] substitution for email anywhere that supports substitutions. Example as follows on how to copy 1 field value to another on login.
Global
Triggers: onAfterLogin
Type: Field
User: Automatic
Access: Everybody Action
Field: Email
Operator: Set
Value:
Code:
[email]
You may also want to add a condition so it's not saving the user object on every login. Example as follows.
Conditions
1: [cb_email] Not Equal To
Code:
[email]
Kyle (Krileon) Community Builder Team Member Before posting on forums:
Read FAQ thoroughly
+
Read our Documentation
+
Search the forums CB links:
Documentation
-
Localization
-
CB Quickstart
-
CB Paid Subscriptions
-
Add-Ons
-
Forge
-- If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
-- If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please
send me a private message
with your thread and will reply when possible!
-- Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
-- My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
Thanks! I knew how to do it... should have followed my instincts and tried it. The reason for the second field is that I wanted to display this on a separate tab that is only visible to moderators. I also wanted to display the email address and not just a blind link to email them.
Since you only need it for display purposes I suggest just using a Custom HTML field with the below substitution.
Code:
[email]
You then won't need to deal with storing it twice.
Kyle (Krileon) Community Builder Team Member Before posting on forums:
Read FAQ thoroughly
+
Read our Documentation
+
Search the forums CB links:
Documentation
-
Localization
-
CB Quickstart
-
CB Paid Subscriptions
-
Add-Ons
-
Forge
-- If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
-- If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please
send me a private message
with your thread and will reply when possible!
-- Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
-- My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.