Logic Machine Forum
CC in mail - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8)
+--- Thread: CC in mail (/showthread.php?tid=4509)



CC in mail - PassivPluss - 18.01.2023

In the common mail function is it possible to also have a reciever in copy?

An csv export is made but the import system doesnt get it so we try to put another mailadress on copy to se if it comes..


RE: CC in mail - admin - 18.01.2023

Just specify multiple recipients, it's the same as CC.


RE: CC in mail - PassivPluss - 18.01.2023

(18.01.2023, 13:49)admin Wrote: Just specify multiple recipients, it's the same as CC.

no. Then the to field contains more than one email. And the importsystem( Energinet) doesnt support that.

The import system doesnt get any of the mails from the LM.


RE: CC in mail - admin - 18.01.2023

You can cc header after to in smtp.message(...). The format is the same as to, emails should be escaped using this format: <user@example.com>


RE: CC in mail - PassivPluss - 18.01.2023

Tried this and the email comes up in the cc field when recieved on to mail adress. But the cc doesnt get the mail?


RE: CC in mail - admin - 19.01.2023

You can put multiple emails into to table but set the "to" header only to the first recipient:
Code:
settings.source = smtp.message({
  headers = {
    to = to[ 1 ],
    subject = subject,
    ['From'] = from,
    ['Content-type'] = 'text/html; charset=utf-8',
  },
  body = message
})