I currently have a cfc to handle 404's that is called by my 404.cfm.  It is
working fine, but I need to use the same cfc for different sites.

This works (very simplified, much more going on):
<cfcomponent>
<cffunction name="handle_404" access="public" returntype="void">
<cfargument name="requested_template" type="string" required="yes">
 <cfif arguments.requested_template eq "/art-cat/">
<cfmodule
 template="/index.cfm"
fuseaction="TheGallery.displayCategory"
 key="#variables.category#"
requested_template="#arguments.requested_template#"
 page_num="#variables.page_num#"
ignoresupresslayout="1">
 </cfif>
</cffunction>
</cfcomponent>


But this does not:

<cfcomponent>
<cffunction name="handle_404" access="public" returntype="void">
 <cfargument name="requested_template" type="string" required="yes">
<cfargument name="current_site_name" type="string" required="yes">
 <cfif arguments.current_site_name eq "www_domain1_com">
 <cfset variables.tmp = domain1_404(arguments.requested_template)>
</cfif>
 </cffunction>
 <cffunction name="domain1_404" access="public" returntype="void"
output="no">
 <cfargument name="requested_template" required="yes" type="string">
 <cfif arguments.requested_template eq "/art-cat/">
<cfmodule
 template="/index.cfm"
fuseaction="TheGallery.displayCategory"
 key="#variables.category#"
requested_template="#arguments.requested_template#"
 page_num="#variables.page_num#"
ignoresupresslayout="1">
 </cfif>
</cffunction>
</cfcomponent>

I don't know if I am just calling the second function improperly?  What
would be the best way to accomplish what I am doing?

-- 
Regards,
Matthew Smith


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336484
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to