This topic is locked

After Record added event

2/6/2006 12:02:29 PM
PHPRunner General questions
mcz_sepal author

I would like to send one email with the data added to notify the admin for some tasks.

I´m using the after record added event with email send function.

What is the best way to get the values recorded to include in the email ?

admin 2/7/2006

Hi,
The values recorded are available in BeforeAdded and BeforeUpated events. So you can use these events to notify administrator.

mcz_sepal author 2/7/2006

Hi Sergey,
Ok. This is clear for me.

What I want to know, is how to retrieve the values, what variable should I read and how to get the last inserted record in case of afterAdded ?

admin 2/8/2006

In BeforeAddand BeforeEditevents use $values["Field1"] to retrieve field value.
The best place to send an email is also Before... event. See sample action Send email with new data.