I am now arnt i?:P -----Original Message----- From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Andrew Scott Sent: Friday, 12 September 2008 4:25 PM To: [email protected] Subject: [cfaussie] Re: default missing template error file
Cool Steve, when you going to start blogging this stuff? -- Senior Coldfusion Developer Aegeon Pty. Ltd. www.aegeon.com.au Phone: +613 9015 8628 Mobile: 0404 998 273 -----Original Message----- From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Onnis Sent: Friday, 12 September 2008 4:16 PM To: [email protected] Subject: [cfaussie] Re: default missing template error file If anyone is interested this is what I changed the "TemplateNotFoundException.cfm" to. This is CF8 by the way.... <!--- Turn off debug output ---> <cfsetting showdebugoutput="false" /> <!--- Set out own user_agest value so we can check it and stop the infinate loop ---> <cfif USER_AGENT NEQ "custom-missing-template"> <!--- Check to see if the site has its own missing template file ---> <cfhttp url="http://#server_name#/ColdfusionMissingTemplate.cfm" useragent="custom-missing-template"></cfhttp> <!--- If it does, include it ---> <cfif CFHTTP.StatusCode CONTAINS "200"> <cfinclude template="ColdfusionMissingTemplate.cfm" /> <cfelse> <!--- Otherwise see if there are any files in the directory at all. ---> <cfdirectory action="LIST" directory="#expandPath(".")#" name="site" filter="*.*" /> <!--- If there are files in the folder then the requested file is not available ---> <cfif site.recordCount> <cffile action="READ" file="E:\Inetpub\wwwroot\customErrors\noDefaultDocument.html" variable="f" /> <cfoutput>#f#</cfoutput> <!--- If there are no files, assume its a brand new site and display "new site" message ---> <cfelse> <cffile action="READ" file="E:\Inetpub\wwwroot\customErrors\new-site.html" variable="f" /> <cfoutput>#f#</cfoutput> </cfif> </cfif> </cfif> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "cfaussie" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cfaussie?hl=en -~----------~----~----~----~------~----~------~--~---
