I have a text field with a select list with a names and email addresses, in the format of:

johndoe@johndoe.com|John Doe
janedoe@janedoe.com|Jane Doe

The 'token' display setting for this field is set to output as 'key'. When the value of this field is input as the 'To' field of an email action, it is not evaluated correctly if I use the direct input mode. It appears that the first and last name are returned, not the email address. If data selection mode is used, the token is evaluated correctly and the email is sent. I started to dig into the code and did not get very far when trying to fix this issue. Thanks in advance.

Comments

TR’s picture

Status: Active » Closed (works as designed)

I gave a complete example on how to do this in #2364443-3: Send email to the Roles which are selected by user in the form. It does work, this is not a bug, at least in the current versions of Rules.