While that may solve your immediate error, I don't know if I'd recommend it for long-term use.
I prefer to store my CFCs in a non-web accessible directory; and refer to them based on a mapping name.
At 07:23 PM 11/8/2004, you wrote:
Just put the CFC in the same directory as you're calling it from and don't use any path info, just the component name. You can't use any upwards paths for CFC invocation, only downwards. I don't know if that's the problem for sure, but I bet it is.
cheers, barneyb
On Mon, 8 Nov 2004 16:01:38 -0800, Daniel Short <[EMAIL PROTECTED]> wrote:
> Hi everyone,
>
> After going to MAX and having a few ahas thanks to Ray, Hal and Ben, I
> finally decided to write my own CFC for creating all of the table structure
> and sample data for Cartweaver. I worked on it on my laptop using CFMX 6.1
> developer edition. I decided to upload it to my dev server and try it there
> on CFMX 6.1 Enterprise. So I uploaded all of the files, and I get this error
> when trying to instantiate the object:
>
> Could not find the ColdFusion Component SQLCreation.CW2CFSQLCreator.
>
> I have the file in this directory:
>
> http://mysecreturl.com/sqlcreation/CW2CFSQLCreator.cfc
>
> If I browse to that file and then log in to CF Administrator, I get this
> error:
>
> Component not found
> The component definition file for component 'SQLCreation.CW2CFSQLCreator'
> cannot be found on this server.
>
> I've not set up a mapping on the server, because I need this CFC to work in
> any location whatsoever, without requiring a mapping since it will be
> distributed. I'm instantiating the CFC like so:
>
> <cfscript>
> //Clean up paths to get proper CFC path to instantiate object
> strCFCPath = Left(cgi.SCRIPT_NAME,Len(cgi.SCRIPT_NAME) -
> Len(GetFileFromPath(GetBaseTemplatePath())));
> strCFCPath = Replace(Trim(Replace(strCFCPath,"/"," ","All"))," ",".","All");
> </cfscript>
>
> <cfobject component="#strCFCPath#.CW2CFSQLCreator" name="sqlCreator">
>
> This all works perfectly on my dev laptop, but not at all on my server.
> Anyone have any ideas on where to start troubleshooting this one?
>
> Any ideas would be much appreciated...
>
> Regards,
>
> Daniel Short
> Lead Developer
> Cartweaver Development Team
> Application Dynamics, Inc.
>
--
Barney Boisvert
[EMAIL PROTECTED]
360.319.6145
http://www.barneyb.com/blog/
I currently have 0 GMail invites for the taking ---------------------------------------------------------- You are subscribed to cfcdev. To unsubscribe, send an email to [EMAIL PROTECTED] with the words 'unsubscribe cfcdev' in the message of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported by Mindtool, Corporation (www.mindtool.com).
An archive of the CFCDev list is available at [EMAIL PROTECTED]
--
Jeffry Houser, Web Developer, Writer, Songwriter, Recording Engineer
AIM: Reboog711 | Phone: 1-203-379-0773
--
My Books: <http://www.instantcoldfusion.com>
My Recording Studio: <http://www.fcfstudios.com>
My Energetic Acoustic Rock Band: <http://www.farcryfly.com>
--
When did Reality Become TV
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email
to [EMAIL PROTECTED] with the words 'unsubscribe cfcdev' in the message of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported by Mindtool, Corporation (www.mindtool.com).
An archive of the CFCDev list is available at [EMAIL PROTECTED]
