SOLUTION: If anyone is interested I discovered that the onRequest
method in App.cfc was guilty. If you're familiar with this method
you'll know that if you choose to use it you need to include a
cfargument called "targetPage" and then you need to have a <cfinclude
template="#Arguments.targetPage#" />. So the reason my web service
wasn't working because this was returning <cfinclude template="/
test.cfc" /> which does nothing.

So it would appear that you can't use onRequest when you publish a web
service!!!! I'd almost call this a bug really.

After reading various articles it appears that there are hack work
arounds (e.g. 
http://www.bennadel.com/blog/430-My-First-ColdFusion-Web-Service.htm
or ) and it sounds like you run into the same problem when trying to
do Flash Remoting and using CFSELECT (http://www.scratty.com/
coldfusion-8-cfselect-bind-ajax/). Here's another useful article
http://www.coldfusionjedi.com/index.cfm?mode=entry&entry=ED9D4058-E661-02E9-E70A41706CD89724

The best solution (hack) I've found was to include the following code
in onRequestStart();
if (ListLast(Arguments.targetPage, ".") EQ "cfc") {
        StructDelete(this, "onRequest");
        StructDelete(variables,"onRequest");
}

Hopefully this helps someone in the future.
Cheers
Matthew

On Jun 23, 1:30 pm, "charlie arehart" <charlie_li...@carehart.org>
wrote:
> Great to hear. I'll check for more details in my morning. 'night all. :-)
>
> /charlie
>
> -----Original Message-----
> From: cfaussie@googlegroups.com [mailto:cfaus...@googlegroups.com] On Behalf
>
> Of Matthew
> Sent: Monday, June 22, 2009 11:21 PM
> To: cfaussie
> Subject: [cfaussie] Re: Web service not working after CF8 upgrade
>
> @Steve: I get you now. Yes, I can invoke the component e.g.
> CreateObject("component","test")
>
> @Kai: I don't think that issue is applicable because you're talking
> about consuming a web service. I'm talking about publishing one.
> Regardless of this the WSDL isn't being registered in the admin
> because it's not even getting to that point because it's not even
> resolving due to the error so it must be something else.
>
> @Charlie: yes I'm expecting to get the WSDL. When I view the source I
> just see 18-20 blank lines (in CF7 I used to get the XML/SOAP dumped
> to the browser as you'd expect). Calling the method via the browser
> had same effect. Calling the CFC via the browser had the same effect.
>
> I think you might be onto something Charlie because I just isolated
> the CFC in a new folder with it's own App.cfc and it worked. You must
> be right. The parent App.cfc is guilty. I need to investigate. Thanks
> a million.
>
> Cheers
> Matthew
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to cfaussie@googlegroups.com
To unsubscribe from this group, send email to 
cfaussie+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to