Hi Michael,
Thanks so much for your response.
I searched the CF docs,and found onMissing Template,and in my  
Application.cfc file I have:
<cfcomponent>
   <cffunction name="onMissingTemplate" returnType="boolean"  
output="false">
     <cfargument name="targetpage" type="string" required="true">
     <cflocation url="404.cfm?missingtemplate=#urlEncodedFormat 
(arguments.targetpage)#" addToken="false">
   </cffunction>
</cfcomponent>

the 404.cfm page just has:
<cfoutput>Sorry, we could not load #url.missingtemplate#</cfoutput>  
in the body tag

This works for templates in the main site, such as:
http://localhost/~johnbarrett/GotNutrients/somenonCFpage.cfm this  
shows the 404.cfm page.
However; if I test http://localhost/~johnbarrett/GotNutrients/test/ 
mycfpage.cfm it does work.
I get a error:
Too many redirects occurred trying to open “http://localhost/ 
~johnbarrett/GotNutrients/test/404.cfm?missingtemplate=%2F% 
7Ejohnbarrett%2FGotNutrients%2Ftest%2F404%2Ecfm”. This might occur if  
you open a page that is redirected to open another page which then is  
redirected to open the original page.

I am testing on my localhost. Seems like I will need to check the  
global 404 error as you say here in the CF admin.
Thanks so much for your help,
John


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
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-newbie/message.cfm/messageid:4326
Subscription: http://www.houseoffusion.com/groups/cf-newbie/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15

Reply via email to