Question for everyone:
I want to use LoadFromFile('html.txt') to set the body of an Indy TIdMessage Body property to HTML that will be sent once some forms in my program are filled out and submitted.
The problem I'm having is that I need to be able to pass data from my InterBase database to the text file so the html email contains the data the user has just entered and I don't have to store a bunch of files on our server.
Is there any way to set place holders in a text file so variables can write to them? Or will I have to write the text file as I go in order to make sure the data is displayed correctly in the HTML?
I'm using a component that allows HTML in the body so I just need to get the variables passed correctly. I want to use the text file as a template so I don't have to put a couple hundred lines of HTML code in my Delphi source.
I hope this made sense. Thanks in advance.
I want to use LoadFromFile('html.txt') to set the body of an Indy TIdMessage Body property to HTML that will be sent once some forms in my program are filled out and submitted.
The problem I'm having is that I need to be able to pass data from my InterBase database to the text file so the html email contains the data the user has just entered and I don't have to store a bunch of files on our server.
Is there any way to set place holders in a text file so variables can write to them? Or will I have to write the text file as I go in order to make sure the data is displayed correctly in the HTML?
I'm using a component that allows HTML in the body so I just need to get the variables passed correctly. I want to use the text file as a template so I don't have to put a couple hundred lines of HTML code in my Delphi source.
I hope this made sense. Thanks in advance.