Question
Dynamic Email Message
Hey guys,
I am trying to write a small email tool that is basically a mail merge. The user types what they want, tell it what table they want it to pull user information from and it goes. however, I want the email they write to be able to use information found in the table to they specify. So if the query that pulled the info was called "UserInfo" and it had a field called firstname, I would like the user to be able to type in the box
Hello #firstname#,
blah blah blah.
and the message would be evauluated for each email that gets sent out. Right now when I type that into the textbox, and echo it out, it simple says
Hello #firstname#,
instead of actually parsing the value of firstname. How can I force it to parse the values of things in # #? I tried using evaluate on the whole message, but of course that doesnt work. Keep in mind I am using the richtext editor.
Attached is my code so far.
I am trying to write a small email tool that is basically a mail merge. The user types what they want, tell it what table they want it to pull user information from and it goes. however, I want the email they write to be able to use information found in the table to they specify. So if the query that pulled the info was called "UserInfo" and it had a field called firstname, I would like the user to be able to type in the box
Hello #firstname#,
blah blah blah.
and the message would be evauluated for each email that gets sent out. Right now when I type that into the textbox, and echo it out, it simple says
Hello #firstname#,
instead of actually parsing the value of firstname. How can I force it to parse the values of things in # #? I tried using evaluate on the whole message, but of course that doesnt work. Keep in mind I am using the richtext editor.
Attached is my code so far.
