Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
WBJP01 #1
Cfusion_VerifyMail
I'm finally converting from CF5 to MX 6 I have discovered that the
Cfusion_VerifyMail() function is no longer supported. Does anyone know of
another way to determine if the mail server is up before attempting to send an
email?
WBJP01 Guest
-
Mountain Lover #2
Re: Cfusion_VerifyMail
this should work for you:
<cfscript>
factory = CreateObject("java", "coldfusion.server.ServiceFactory");
smtpMailServer = factory.MailSpoolService.getServer();
if (Len(smtpMailServer)) {
isMSup = factory.MailSpoolService.verifyServer();
}
else {
isMSup = 0;
}
if (isMSup) {
MailRoot = factory.RuntimeService.getRootDir() ;
}
else {
vErrorMessage = "The emailserver #smtpMailServer# is not up." ;
}
</cfscript>
HTH
--
Tim Carley
[url]www.recfusion.com[/url]
[email]info@NOSPAMINGrecfusion.com[/email]
Mountain Lover Guest
-
Tom Jordahl #3
Re: Cfusion_VerifyMail
Warning: Unsupported!
Check out the new Admin API in CFMX 7. I think we have this function in
there.
--
Tom Jordahl
Macromedia Server Development
Tom Jordahl Guest
-
Mountain Lover #4
Re: Cfusion_VerifyMail
Sorry I don't have CFMX7 (neither does the OP)..so I hacked at it since
CFMX6 didn't give us an admin API AFAIK ;-)
--
Tim Carley
[url]www.recfusion.com[/url]
[email]info@NOSPAMINGrecfusion.com[/email]
Mountain Lover Guest



Reply With Quote

