Hello,
I have a CCK field (type:decimal) that allow users to insert a value. If the value exceeds a certain amount like 5000, I would like the system to automatically alert or send a message to the accounting department via email.

I've tried the limits module and that works but no email capability. I've also tried inserting this code into the php section for the CCK field and did not do justice.

Code:

var $budget_amount decimal;

if ($budget_amount > 5000)
{
mail('nobody@example.com', 'the subject', 'the message', null, '-fwebmaster@example.com');
}

Does anyone has any suggestions?

Thank you.
J801

Comments

j801’s picture

Component: User interface » Miscellaneous
Assigned: Unassigned » j801
Category: support » feature
Status: Needs review » Reviewed & tested by the community