3

I have fusebox 5 application configured on lucee 5.1.0.34. There are a cfc in com/reports/ folder. When i run the remote method from cfc. It is giving me following error.

enter image description here

Here is my cfc code.

<cfcomponent displayname="Reports" output="yes">
<cffunction name="test" access="remote" output="yes">
    <cfoutput>testing</cfoutput>
</cffunction>
</cfcomponent>

I am running the method in browser like that.

http://example.com/com/reports/abc.cfc?method=test

I have checked the logs and search alot. I have not found any help about this problem. Can any body help me to resolve this

Community
  • 1
  • 1
Abdul Rauf
  • 763
  • 2
  • 8
  • 28

1 Answers1

2

Running a method remote returns the page by default with a content-type of text/xml. Your browser interprets that as broken xml. Try this instead.

<cfcomponent displayname="Reports" output="yes">
    <cffunction name="test" access="remote" output="yes">
       <cfcontent type="text/html">
       <cfoutput>testing</cfoutput>
    </cffunction>
</cfcomponent>
Jack Pilowsky
  • 2,275
  • 5
  • 28
  • 38