To clarify slightly:

http://mysite/project/test.cfm works
http://mysite/project/myCFC.cfc works

The CFC path is project.myCFC.function. I can use this path
successfully on the server-side.

The problem is that when I bind cfgrid to the path of
project.myCFC.function, the generated JavaScript that is sent to the
browser instructs the Ajax call to look here:
http://mysite/myCFC.cfc
instead of here:
http://mysite/project/myCFC.cfc

If I move the /project virtual directory so that it is a phycial
subdirectory of the Web root, the problem goes away, but I don't want
to set things up that way for security reasons.

-Mike Chabot

On 9/12/07, Mike Chabot <[EMAIL PROTECTED]> wrote:
> Thanks Gary,
> I confirmed that the CFC is accessible over a standard URL by loading
> it in the Web browser.
>
> Turing the Ajax debugging on, I can see the exact request that is
> being made. I take that request, fix the URL so that it now looks in
> the correct location, paste the corrected URL into the browser, and
> the CFC returns a result.
>
> -Mike Chabot
>
> On 9/12/07, gary gilbert <[EMAIL PROTECTED]> wrote:
> > Hi Mike,
> >
> > if you are using a virtual directory and your cfc is located somewhere else 
> > you still need to be able to get to the cfc using a standard URL.
> >
> > I have found the the bind always starts at the webroot and goes from there 
> > so in your example you have.
> >
> > http://mysite/projects
> >
> > Your bind attribute would need to be "cfc:mysite.projects.mycfc.myfunction" 
> > if your cfc's are located in another virtual directory your bind attribute 
> > should be.
> >
> > "cfc:myVirtualDir.myCFC.myfunction"
> >
> > A good test is to see use a standard URL to get to your CFC if you reach it 
> > then you know what the path will be.
> >
> > example url
> > http://mysite/projects/mycfc.cfc?method=myfunction&returnformat=json&argumentcollection=...
> >
> > Regards,
> >
> > Gary Gilbert
> > http://www.garyrgilbert.com/blog
> >
> >
> > 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Create robust enterprise, web RIAs.
Upgrade to ColdFusion 8 and integrate with Adobe Flex
http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJP

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:288279
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to