House of Fusion
Search over 2,500 ColdFusion resources here
  
Home of the ColdFusion Community

Mailing Lists
Home /  Groups /  ColdFusion Talk (CF-Talk)

Returning XML via webservice, cont

  << Previous Post |  RSS |  Tree View |  Sort Oldest First |  Subscribe to this Group Next >> 

Returning XML via webservice, cont

Tom, Chris Dempsey 06/03/2004 11:43 PM
Tom, Chris Dempsey 06/03/2004 11:29 PM
Yes, I see the same thing when I view the source, it is a WDDX pocket. It is Tom Kitta 06/03/2004 09:40 AM
Tom, Christopher Dempsey 06/02/2004 04:50 PM
I tryed the links you supplied and I got what I expected. Can you send me Tom Kitta 06/02/2004 02:06 PM
Tom, Christopher Dempsey 06/02/2004 01:35 PM
I have tryed your function, with code: Tom Kitta 06/02/2004 12:29 PM
Oops, wrong version of the function.  Here is the right code: Christopher Dempsey 06/02/2004 11:05 AM
Why is your function return type "void" it should be "string" if you want to Tom Kitta 06/02/2004 10:33 AM
Dear List, Chris Dempsey 06/02/2004 10:26 AM

06/03/2004 11:43 PM
Author: Chris Dempsey Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165489 Tom, I think you mean why do I not call the XML directly?  Ie., have the user hit http://www.graddiv.ucsb.edu/ssoNavigation.xml instead of /sso.cfc?method=getNavigation The reason why I'd like to work out going through the CFC is that a future version will return a customized XML based on some input parameters, such as userID. Thanks, Chris On Jun 3, 2004, at 6:37 AM, Tom Kitta wrote: ----- Excess quoted text cut - see Original Post for more ----- --                                                                                *********************** Chris Dempsey Director, Information Services UCSB Graduate Division Quis custodiet ipsos custodies
06/03/2004 11:29 PM
Author: Chris Dempsey Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165487 Tom, I think you mean why do I not call the XML directly?  Ie., have the user hit http://www.graddiv.ucsb.edu/ssoNavigation.xml instead of /sso.cfc?method=getNavigation The reason why I'd like to work out going through the CFC is that a future version will return a customized XML based on some input parameters, such as userID. Thanks, Chris On Jun 3, 2004, at 6:37 AM, Tom Kitta wrote: ----- Excess quoted text cut - see Original Post for more -----
06/03/2004 09:40 AM
Author: Tom Kitta Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165362 Yes, I see the same thing when I view the source, it is a WDDX pocket. It is the way CF is sending the XML to the browser as XML encapsulated in WDDX. You can always write the XML to a file and then you get straight XML. Why this would be  problem for your application? TK   Tom,   The displayed output is correct, but when I view the source, I see the   <wddx> tags.  Is that the same with you?   Chris      > I tryed the links you supplied and I got what I expected. Can you send me   > what you get as your browser response? Maybe you need to clear browser cache   > or something. I looked at the XML raw and one returned by your CFC call and   > they are the same minus the formatting of the actual XML (mine doesn't have   > the line feeds). Check it out and tell me whatever it works now, if it works   > for me it should for you, right?   >   > TK   >   Tom,   >   >   I tried what you recommended,   >   >   I have tried your method below, and it didn't work quite right.  It still   >   returns a WDDX packet, but now all of the XML is escaped.  The XML file is   >   at http://www.graddiv.ucsb.edu/ssoNavigation.xml and I am calling the   >   below code with http://www.graddiv.ucsb.edu/sso.cfc?method=getNavigation   >   >   Here is the code now.  I tried it without using the closing /> and it had   >   no effect.   >   >   <cffunction name="getNavigation" access="remote"   >     returntype="any" displayname="Get SSO navigation XML document"   >     hint="This method retrieves an XML document used for SSO navigation   > bar."   >     output="false">   >       <cffile action="read" file="D:\inetpub\wwwroot\ssoNavigation.xml"   > variable="myString" />   >     <cfreturn toString(myString) />   >   </cffunction>   >   >   Totally bizarre.  Also tried restarting the CF service and clearing the   >   browser cache, no effect.   >   >   Thanks,   >   >   Chri   >   >   >   >
06/02/2004 04:50 PM
Author: Christopher Dempsey Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165329 Tom, The displayed output is correct, but when I view the source, I see the <wddx> tags.  Is that the same with you? Chris ----- Excess quoted text cut - see Original Post for more -----
06/02/2004 02:06 PM
Author: Tom Kitta Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165313 I tryed the links you supplied and I got what I expected. Can you send me what you get as your browser response? Maybe you need to clear browser cache or something. I looked at the XML raw and one returned by your CFC call and they are the same minus the formatting of the actual XML (mine doesn't have the line feeds). Check it out and tell me whatever it works now, if it works for me it should for you, right? TK   Tom,   I tried what you recommended,   I have tried your method below, and it didn't work quite right.  It still   returns a WDDX packet, but now all of the XML is escaped.  The XML file is   at http://www.graddiv.ucsb.edu/ssoNavigation.xml and I am calling the   below code with http://www.graddiv.ucsb.edu/sso.cfc?method=getNavigation   Here is the code now.  I tried it without using the closing /> and it had   no effect.   <cffunction name="getNavigation" access="remote"     returntype="any" displayname="Get SSO navigation XML document"     hint="This method retrieves an XML document used for SSO navigation bar."     output="false">       <cffile action="read" file="D:\inetpub\wwwroot\ssoNavigation.xml" variable="myString" />     <cfreturn toString(myString) />   </cffunction>   Totally bizarre.  Also tried restarting the CF service and clearing the   browser cache, no effect.   Thanks,   Chri
06/02/2004 01:35 PM
Author: Christopher Dempsey Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165306 Tom, I tried what you recommended, I have tried your method below, and it didn't work quite right.  It still returns a WDDX packet, but now all of the XML is escaped.  The XML file is at http://www.graddiv.ucsb.edu/ssoNavigation.xml and I am calling the below code with http://www.graddiv.ucsb.edu/sso.cfc?method=getNavigation Here is the code now.  I tried it without using the closing /> and it had no effect. <cffunction name="getNavigation" access="remote"   returntype="any" displayname="Get SSO navigation XML document"   hint="This method retrieves an XML document used for SSO navigation bar."   output="false">     <cffile action="read" file="D:\inetpub\wwwroot\ssoNavigation.xml" variable="myString" />   <cfreturn toString(myString) /> </cffunction> Totally bizarre.  Also tried restarting the CF service and clearing the browser cache, no effect. Thanks, Chris ----- Excess quoted text cut - see Original Post for more ----- -- *********************** Chris Dempsey Director, Information Services UCSB Graduate Division Quis custodiet ipsos custodies
06/02/2004 12:29 PM
Author: Tom Kitta Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165289 I have tryed your function, with code: <cffunction name="getNavigation" access="remote" returntype="any" output="false"> <cffile action="read" file="c:\inetpub\wwwroot\tk\gb\data\data1.xml" variable="myString"> <cfreturn xmlFormat(toString(myString))> </cffunction> Works fine. Try to copy above exactly, maybe it is your /> at the tag ends. Check the actual XML file, what is in it. Etc. Function works fine on CF6.1 TK http://www.tomkitta.com   Oops, wrong version of the function.  Here is the right code:   <cffunction name="getNavigation2" access="remote" returntype="any" output="false">   <cffile action="read" file="D:\inetpub\wwwroot\ssoNavigation.xml" variable="myString" />   <cfreturn toString(myString) />   </cffuncti   > Why is your function return type "void" it should be "string" if you want to   > return a string[Tom Kitta] . Change it to string and give it a go.   >   > TK   >   Dear List,   >   >   I saw this thread a few days ago, about returning an XML document as a   >   string from a CFC.  I tried using returntype="any" and the toString()   >   function - neither worked.  What ends up happening is that the XML   >   document gets returned as a WDDX packet.  Is it possible to just return   >   it as a string, with no further changes?   >   >   Here is the XML doc: http://www.graddiv.ucsb.edu/ssoNavigation.xml   >   >   Here is the simplified CFC code:   >   >   <cfcomponent extends="base">   >   <cffunction name="getNavigation" access="remote"   >   returntype="void" output="false">   >   <cffile action="read" file="#path#ssoNavigation.xml"   >   variable="myString" />   >   >   <cfreturn toString(myString) />   >   </cffunction>   >   </cfcomponent>   >   >   The cfc is located here: http://www.graddiv.ucsb.edu/sso.cfc   >   >   Thanks!   >   >   Chris
06/02/2004 11:05 AM
Author: Christopher Dempsey Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165268 Oops, wrong version of the function.  Here is the right code: <cffunction name="getNavigation2" access="remote" returntype="any" output="false">   <cffile action="read" file="D:\inetpub\wwwroot\ssoNavigation.xml" variable="myString" />   <cfreturn toString(myString) /> </cffuncti ----- Excess quoted text cut - see Original Post for more -----
06/02/2004 10:33 AM
Author: Tom Kitta Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165258 Why is your function return type "void" it should be "string" if you want to return a string[Tom Kitta] . Change it to string and give it a go. TK   Dear List,   I saw this thread a few days ago, about returning an XML document as a   string from a CFC.  I tried using returntype="any" and the toString()   function - neither worked.  What ends up happening is that the XML   document gets returned as a WDDX packet.  Is it possible to just return   it as a string, with no further changes?   Here is the XML doc: http://www.graddiv.ucsb.edu/ssoNavigation.xml   Here is the simplified CFC code:   <cfcomponent extends="base">   <cffunction name="getNavigation" access="remote"   returntype="void" output="false">   <cffile action="read" file="#path#ssoNavigation.xml"   variable="myString" />   <cfreturn toString(myString) />   </cffunction>   </cfcomponent>   The cfc is located here: http://www.graddiv.ucsb.edu/sso.cfc   Thanks!   Chris   --   ***********************   Chris Dempsey   Director, Information Services   UCSB Graduate Division   Quis custodiet ipsos custodies
06/02/2004 10:26 AM
Author: Chris Dempsey Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32935#165253 Dear List, I saw this thread a few days ago, about returning an XML document as a string from a CFC.  I tried using returntype="any" and the toString() function - neither worked.  What ends up happening is that the XML document gets returned as a WDDX packet.  Is it possible to just return it as a string, with no further changes? Here is the XML doc: http://www.graddiv.ucsb.edu/ssoNavigation.xml Here is the simplified CFC code: <cfcomponent extends="base">   <cffunction name="getNavigation" access="remote"     returntype="void" output="false">     <cffile action="read" file="#path#ssoNavigation.xml" variable="myString" />     <cfreturn toString(myString) />   </cffunction> </cfcomponent> The cfc is located here: http://www.graddiv.ucsb.edu/sso.cfc Thanks! Chris --                                                                                *********************** Chris Dempsey Director, Information Services UCSB Graduate Division Quis custodiet ipsos custodies
<< Previous Thread Today's Threads Next Thread >>

Search cf-talk

May 24, 2012

<<   <   Today   >   >>
Su Mo Tu We Th Fr Sa
     1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31     

Designer, Developer and mobile workflow conference