Referencing component packages
Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm
Re: Referencing component packages
I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq 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
RE: Referencing component packages
Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm
RE: Referencing component packages
Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm
RE: Referencing component packages
So what do you get when you use the syntax Marlon suggested? Also, are you on Windows or Unix? If Unix, the case will matter I believe. === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Blum, Jason (SAA) [mailto:Jason_Blum;saa.senate.gov] Sent: Tuesday, November 12, 2002 1:46 PM To: CF-Talk Subject: RE: Referencing component packages Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cwhatannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting.
RE: Referencing component packages
Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com
Re: Referencing component packages
Make sure that you're referencing from CF's root directory. Another option if you have DWMX is to drag the component into your code from the Application--Components toolbar Raymond Camden wrote: Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm
RE: Referencing component packages
Not CF's root dir, but one of these: Current folder Web root (I assume you meant web root, not really the cfusionmx root) A defined mapping === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 2:21 PM To: CF-Talk Subject: Re: Referencing component packages Make sure that you're referencing from CF's root directory. Another option if you have DWMX is to drag the component into your code from the Application--Components toolbar Raymond Camden wrote: Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. = == Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq 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
Re: Referencing component packages
RE from Raymond: Web root (I assume you meant web root, not really the cfusionmx root) This is the last time I'll ask, I swear, but is there a way to figure out what the web root is from CFML? I know ColdFusion must know what it is to map directories, so couldn't the CF engine just play fair and set some variable for us to reference, or at least give us a relative path so that we can figure it out ourselves...or is this some deeply rooted evil idea that should be buried and never surface again? P.S.: I ask because I do not like hard-coding references to other directories when I can help it, it keeps my sites nimble, and gives me a lot more control on shared servers, etc... Tyler Silcox email | [EMAIL PROTECTED] - Original Message - From: Raymond Camden [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Tuesday, November 12, 2002 2:23 PM Subject: RE: Referencing component packages Not CF's root dir, but one of these: Current folder Web root (I assume you meant web root, not really the cfusionmx root) A defined mapping === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 2:21 PM To: CF-Talk Subject: Re: Referencing component packages Make sure that you're referencing from CF's root directory. Another option if you have DWMX is to drag the component into your code from the Application--Components toolbar Raymond Camden wrote: Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. = == Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting.
RE: Referencing component packages
This is the last time I'll ask, I swear, but is there a way to figure out what the web root is from CFML? No, I don't think so. I know ColdFusion must know what it is to map directories, so couldn't the CF engine just play fair and set some variable for us to reference, or at least give us a relative path so that we can figure it out ourselves...or is this some deeply rooted evil idea that should be buried and never surface again? I don't know that it's an evil idea, but I also don't know that CF knows it, either - it shouldn't have to, for its own directory mappings, since it stores a logical path and its corresponding physical filesystem path for each mapping. Also, there's no need for the root mapping to correspond to the web root directory, so CF can't just assume that it does. However, if you wanted to make this assumption, you could look the root mapping value up within your code. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ voice: (202) 797-5496 fax: (202) 797-5444 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq 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
RE: Referencing component packages
I believe expandPath(/) will return it for you. === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Tyler Silcox [mailto:mail4tyler;gslsolutions.com] Sent: Tuesday, November 12, 2002 2:57 PM To: CF-Talk Subject: Re: Referencing component packages RE from Raymond: Web root (I assume you meant web root, not really the cfusionmx root) This is the last time I'll ask, I swear, but is there a way to figure out what the web root is from CFML? I know ColdFusion must know what it is to map directories, so couldn't the CF engine just play fair and set some variable for us to reference, or at least give us a relative path so that we can figure it out ourselves...or is this some deeply rooted evil idea that should be buried and never surface again? P.S.: I ask because I do not like hard-coding references to other directories when I can help it, it keeps my sites nimble, and gives me a lot more control on shared servers, etc... Tyler Silcox email | [EMAIL PROTECTED] - Original Message - From: Raymond Camden [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Tuesday, November 12, 2002 2:23 PM Subject: RE: Referencing component packages Not CF's root dir, but one of these: Current folder Web root (I assume you meant web root, not really the cfusionmx root) A defined mapping == = Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 2:21 PM To: CF-Talk Subject: Re: Referencing component packages Make sure that you're referencing from CF's root directory. Another option if you have DWMX is to drag the component into your code from the Application--Components toolbar Raymond Camden wrote: Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. = == Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting.
Re: Referencing component packages
Sure does! On Tuesday, November 12, 2002, at 01:40 PM, Raymond Camden wrote: I believe expandPath(/) will return it for you. === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Tyler Silcox [mailto:mail4tyler;gslsolutions.com] Sent: Tuesday, November 12, 2002 2:57 PM To: CF-Talk Subject: Re: Referencing component packages RE from Raymond: Web root (I assume you meant web root, not really the cfusionmx root) This is the last time I'll ask, I swear, but is there a way to figure out what the web root is from CFML? I know ColdFusion must know what it is to map directories, so couldn't the CF engine just play fair and set some variable for us to reference, or at least give us a relative path so that we can figure it out ourselves...or is this some deeply rooted evil idea that should be buried and never surface again? P.S.: I ask because I do not like hard-coding references to other directories when I can help it, it keeps my sites nimble, and gives me a lot more control on shared servers, etc... Tyler Silcox email | [EMAIL PROTECTED] - Original Message - From: Raymond Camden [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Tuesday, November 12, 2002 2:23 PM Subject: RE: Referencing component packages Not CF's root dir, but one of these: Current folder Web root (I assume you meant web root, not really the cfusionmx root) A defined mapping == = Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 2:21 PM To: CF-Talk Subject: Re: Referencing component packages Make sure that you're referencing from CF's root directory. Another option if you have DWMX is to drag the component into your code from the Application--Components toolbar Raymond Camden wrote: Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. = == Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems to be impossible without setting up a mapping in CFAdmin... I've tried dot notation, forward slashes, backward slashes, from the wwwroot, from the root drive, ExpandPath, etc., etc Anybody know what I am doing wrong??? ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com
RE: Referencing component packages
But please note Dave Watt's earlier email. I believe you can set the / mapping in CF to something that is not the web root. Therefore, this may not be the best solution. === Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Dick Applebaum [mailto:dicklacara;mac.com] Sent: Tuesday, November 12, 2002 5:15 PM To: CF-Talk Subject: Re: Referencing component packages Sure does! On Tuesday, November 12, 2002, at 01:40 PM, Raymond Camden wrote: I believe expandPath(/) will return it for you. == = Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Tyler Silcox [mailto:mail4tyler;gslsolutions.com] Sent: Tuesday, November 12, 2002 2:57 PM To: CF-Talk Subject: Re: Referencing component packages RE from Raymond: Web root (I assume you meant web root, not really the cfusionmx root) This is the last time I'll ask, I swear, but is there a way to figure out what the web root is from CFML? I know ColdFusion must know what it is to map directories, so couldn't the CF engine just play fair and set some variable for us to reference, or at least give us a relative path so that we can figure it out ourselves...or is this some deeply rooted evil idea that should be buried and never surface again? P.S.: I ask because I do not like hard-coding references to other directories when I can help it, it keeps my sites nimble, and gives me a lot more control on shared servers, etc... Tyler Silcox email | [EMAIL PROTECTED] - Original Message - From: Raymond Camden [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Tuesday, November 12, 2002 2:23 PM Subject: RE: Referencing component packages Not CF's root dir, but one of these: Current folder Web root (I assume you meant web root, not really the cfusionmx root) A defined mapping == = Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 2:21 PM To: CF-Talk Subject: Re: Referencing component packages Make sure that you're referencing from CF's root directory. Another option if you have DWMX is to drag the component into your code from the Application--Components toolbar Raymond Camden wrote: Do not use / format. This is the second time I've seen this used - any reason why? It's not in the docs. You should use foo.goo format where every item till the end is a folder name and the last item is the CFC itself. = == Raymond Camden, ColdFusion Jedi Master for Hire Email: [EMAIL PROTECTED] WWW : www.camdenfamily.com/morpheus Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Brook Davies [mailto:brook;maracasmedia.com] Sent: Tuesday, November 12, 2002 1:55 PM To: CF-Talk Subject: RE: Referencing component packages Have you tried just /components/Query ? At 01:45 PM 12/11/02 -0500, you wrote: Yeah, that's what I would have thought. And that's precisely that all the books and MX documentation say. But it isn't working for me... Thanks for the response though! -Original Message- From: Marlon Moyer [mailto:marlon;mcmoyer.com] Sent: Tuesday, November 12, 2002 12:19 PM To: CF-Talk Subject: Re: Referencing component packages I believe it should be cfinvoke Component=mySite.components.query Blum, Jason (SAA) wrote: Forta, New Riders and others all say that you can call put all your components in one folder and then reference them just as you would an include, style sheet, whatever. But I am absolutely stumped on how to do this. Have followed their instructions very carefully and played with variations but cannot seem to do it. If /MySite/index.cfm wants to instate /MySite/components/Query.cfc then CFINVOKE COMPONENT=components/Query... works great. But going back up the directory structure, say from: /MySite/admin/index.cfm CFINVOKE COMPONENT=../components/Query... seems