Re: [FlexJS] HTTP status text

2017-03-20 Thread Justin Mclean
Hi, > Sounds useful. What is the SWF equivalent? Would the same text show up > in IOError or SecurityError? As far as I can see there no easy way to get at the status text on AS only the status code. There may be a way [1] use web sockets but then again it looks like this bug [2] may stop yo

Re: [FlexJS] HTTP status text

2017-03-19 Thread Alex Harui
Sounds useful. What is the SWF equivalent? Would the same text show up in IOError or SecurityError? -Alex On 3/19/17, 2:32 AM, "Justin Mclean" wrote: >Hi, > >Perhaps an example will help showing this better. The server I’m talking >to gives: >Status Code:500 The current user is not authorized

Re: [FlexJS] HTTP status text

2017-03-19 Thread Harbs
Welcome to the joys of JS development… ;-) > On Mar 19, 2017, at 11:37 AM, Justin Mclean wrote: > > HI, > >> If there’s something in the body of the response, you should be able to get >> it from the hxr. > > Sadly there’s no content in the body that's useful - it just contains generic > “An

Re: [FlexJS] HTTP status text

2017-03-19 Thread Justin Mclean
HI, > If there’s something in the body of the response, you should be able to get > it from the hxr. Sadly there’s no content in the body that's useful - it just contains generic “An error has occurred” information. Thanks, Justin

Re: [FlexJS] HTTP status text

2017-03-19 Thread Harbs
If there’s something in the body of the response, you should be able to get it from the hxr. > On Mar 19, 2017, at 11:32 AM, Justin Mclean wrote: > > Hi, > > Perhaps an example will help showing this better. The server I’m talking to > gives: > Status Code:500 The current user is not authoriz

Re: [FlexJS] HTTP status text

2017-03-19 Thread Justin Mclean
Hi, Perhaps an example will help showing this better. The server I’m talking to gives: Status Code:500 The current user is not authorized to invoke this method. But you can also get errors like this: Status Code:500 The PROFILEID parameter to the logout function is required but was not passed i

Re: [FlexJS] HTTP status text

2017-03-19 Thread Justin Mclean
Hi, > I don’t know what you mean. It has error events with the status code on the > JS side. I use it all the time. The status code come through fine just not the status text. The AS side has additional events ie IOErrorEvent.IO_ERROR and SecurityErrorEvent.SECURITY_ERROR for instance that may

Re: [FlexJS] HTTP status text

2017-03-19 Thread Harbs
I don’t know what you mean. It has error events with the status code on the JS side. I use it all the time. > On Mar 19, 2017, at 9:31 AM, Justin Mclean wrote: > > Hi, > >> Take a look at URLBinaryLoader (which is the network class I’m using pretty >> much exclusively). The main logic is in U

Re: [FlexJS] HTTP status text

2017-03-19 Thread Justin Mclean
Hi, > Take a look at URLBinaryLoader (which is the network class I’m using pretty > much exclusively). The main logic is in URLStream which handles all kinds of > responses. HTTPService can probably be improved using similar logic. I looked ta that it seem it can only do on the AS side not on t

Re: [FlexJS] HTTP status text

2017-03-18 Thread Harbs
Take a look at URLBinaryLoader (which is the network class I’m using pretty much exclusively). The main logic is in URLStream which handles all kinds of responses. HTTPService can probably be improved using similar logic. Harbs > On Mar 19, 2017, at 7:58 AM, Justin Mclean wrote: > > Hi, > >

[FlexJS] HTTP status text

2017-03-18 Thread Justin Mclean
Hi, Using HTTPServer on the JS side it’s quite difficult to diagnose issues when you do get responses other than 200 OKs. The io errors and security errors are only supported on the AS side in that class. One of Adobe’s server side products likes returning 500 errors for just about everything