Log In    |    Knowledge Base    |    4D Home
Tech Tip: Dynamic emailing from your store
PRODUCT: 4D Business Kit | VERSION: 1.0 | PLATFORM: Mac & Win
Published On: February 14, 2003

To set up dynamic emailing from your store to the current shopper for each session, use the command 4DBKMail. This command takes in up to 5 parameters. The acceptable parameters are: Sender's email address, Recipient's email address, Subject, Form or page to send, format. The last parameter is optional. The 4DBKMail command will accept other 4DBK commands as parameters, thus allowing for dynamic emailing. By default, if the format of the form or page to send is omitted, the format will be in html format. Here is an example of how to use this command:

(a) <!--#4DBKMail/4DBKField/StoreMainEmail,4DBKField/CusEmail,Your Order,Orderform.html-->


- 4DBKField/StoreMainEmail: is the email address of the store set in the Stores table
- 4DBKField/CusEmail: is the email address of the currently logged in shopper for this session
- Orderform.html: is the html file I wish to send as an email to the customer.

This has the same effect as if I typed in:

(b) <!--#4DBKMail/,,Your Order,Orderform.html-->

The main difference between (a) and (b) is that everything is dynamic, meaning that whenever a new shopper logs in, the value of 4DBKField/CusEmail will be specific to each shopper.