Easiest solution is to use CF mappings instead of relative paths. -----Original Message----- From: heirophant mm [mailto:[EMAIL PROTECTED]] Sent: vrijdag 12 april 2002 4:11 To: CF-Talk Subject: CFINCLUDE tag and relative paths
I have a display template, called as a custom tag through CFMODULE. The caller tags pass it an attribute called "navigation", which is the path of a navigation template to display. The custom tag displays it using <cfdisplay template="#attributes.navigation#">. I want the caller to be able to pass a path relative from itself (for ease of use) - so the value you pass for the "navigation" attribute would be the same as the value that a CFINCLUDE right inside the caller template would use. However, since the display template is in a different folder, just doing <cfinclude template="#attributes.navigation#"> does not work, since it expects the path to be relative from the current template, NOT the caller template. I wrote some UDFs that convert the value of attributes.navation so the path is instead relative to the display template, allowing the CFINCLUDE tag to work correctly. This solution is not very elegant, though. Nor is it efficient. Am I missing an easier way to do this? To summarize, I want a CFINCLUDE tag to correctly find a path that is relative to the caller template, instead of the current [custom tag] template. Note: For reasons unknown to me, we aren't allowed to use the Custom Tags folder on our server. So this display template I'm talking about is actually below the wwwroot folder. I don't know if that makes any difference in my problem. This brings me to my second question: Do custom tags actually in the Custom Tags folder behave differently concerning tags such as CFINCLUDE? In this case, would the CFINCLUDE tag look for a template relative to the caller template instead? ------------------- Mike Mertsock Web Applications Programmer Alfred University [EMAIL PROTECTED] See Dave Matthews Band live or win a signed guitar http://r.lycos.com/r/bmgfly_mail_dmb/http://win.ipromotions.com/lycos_020201/splash.asp FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists ______________________________________________________________________ Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

