How to make a email field clickable?

Make the new email field clickable (as a mailto: link) in the leads module?

I made a new text field so we can record the more generic email addresses too. But when i enter a email to that new field it is not clickable but just treated as normal text. How can i fix this?
Example of this below:

Thanks! :smiley: :+1:

Hi

You should add a CustomCode entry in file custom/modules/Leads/metadata/detailsviewdefs.php.
Something like that (assuming the field name is alt_email_c).
So, change alt_email_c to the actual name of your custom field.

          array (
            'name' => 'alt_email_c',
            'label' => 'LBL_ALT_EMAIL',
            'customCode' => '<a href="mailto:{$fields.alt_email_c.value}">{$fields.alt_email_c.value}</a>',
          ),
1 Like

Awesome, thank yo so much @blqt for the help!

Have a wonderful weekend. :smiley: :+1: :facepunch:

Kind regards

This custom code won’t open the Emails modules in SuiteCRM but instead opens Windows 10 Mail. What custom code will allow opening of SuiteCRM’s builtin Emails module ?
Thanks in advance