I am creating a message profile system, when the system performs a certain action it picks up a certain profile and triggers the message as email , however I would like it in the message body when writing {{variavel}}
would like it to take the value of $variavel
corresponding (automatically), however I do not know how to call this method and I still have not found any solution, could anyone help?
Explanation :
I have the following message:
{{name}} Lorem Ipsum is simply dummy text of the printing and typesetting industry {{email}}
To replace these values I would have to do the following:
str_replace("{{nome}}", $nome, $mensagem);
str_replace("{{email}}", $email, $mensagem);
I just wanted to do this so that it would be automatic.