Put conditionals before every cfmail tag to determine the recipients based on which server environment you are in. It would help to have a wrapper class around cfmail that handles this site-wide. I would not try to monitor the spool folder. You can disable sending email entirely in cfadmin, although you would need some alternate way to test emails.
-Mike Chabot On Tue, Dec 30, 2008 at 1:30 PM, Chris Spencer <[email protected]> wrote: > On my development server, I'd like to filter all outgoing email and > replace the recipients with an arbitrary email address, in order to > prevent customers from being accidentally emailed. > > Obviously, this could be done by removing customer addresses from the > database, but I'd like to keep these intact for testing various > reports that require unique addresses for each customer. > > There doesn't seem to be any existing feature in Cfadmin for this. Any > thoughts on how I'd go about implementing this? One thought I had was > to create a script that would monitor CF's spool directory, and modify > any newly creating files, but I'm not sure how I'd guarantee the > script would see the files before CF. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;207172674;29440083;f Archive: http://www.houseoffusion.com/groups/cf-server/message.cfm/messageid:6715 Subscription: http://www.houseoffusion.com/groups/cf-server/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.10
