RE: [flexcoders] Problem with post

2007-05-16 Thread Petro Bochan
Hi,

 

Try not to use the HTTPService with the URLVariables class. The latter
is best used with the URLLoader class. I had fairly good experience with
that. That might be the reason why the first variable is not being sent
properly.

 

Cheers,

Petro

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Guillermo Villasana
Sent: Tuesday, May 15, 2007 8:14 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Problem with post

 

Is there any reason why if i send with method post, one variable will 
not be sent ?

var params:URLVariables=new URLVariables();
var myservice:HTTPService=new HTTPService();

params.var1=event.values[0];
params.var2=event.values[1];
params.var3=event.values[2];

myservice.method=post;
myservice.url.etc

myservice.send(params);

the odd things is that var1 no matter where I put it, is not sent, but 
if I just change .method=post to .method=get
then everything is sent correctly...
any thoughts?

Terius

 



[flexcoders] Problem with post

2007-05-15 Thread Guillermo Villasana
Is there any reason why if i send with method post, one variable will 
not be sent ?

var params:URLVariables=new URLVariables();
var myservice:HTTPService=new HTTPService();

params.var1=event.values[0];
params.var2=event.values[1];
params.var3=event.values[2];

myservice.method=post;
myservice.url.etc

myservice.send(params);

the odd things is that var1 no matter where I put it, is not sent, but 
if I just change .method=post to .method=get
then everything is sent correctly...
any thoughts?

Terius


RE: [flexcoders] Problem with post

2007-05-15 Thread Tracy Spratt
I have never typed the request object as URLVariables, always as a plain
Object.  Try that to see if it has any effect.

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Guillermo Villasana
Sent: Tuesday, May 15, 2007 1:14 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Problem with post

 

Is there any reason why if i send with method post, one variable will 
not be sent ?

var params:URLVariables=new URLVariables();
var myservice:HTTPService=new HTTPService();

params.var1=event.values[0];
params.var2=event.values[1];
params.var3=event.values[2];

myservice.method=post;
myservice.url.etc

myservice.send(params);

the odd things is that var1 no matter where I put it, is not sent, but 
if I just change .method=post to .method=get
then everything is sent correctly...
any thoughts?

Terius

 



RE: [flexcoders] Problem with post

2007-05-15 Thread Seth Hodgson
Take a look at the ASDoc comments for HTTPService.send(). The method requires 
that you pass an XML instance or an anonymous Object of name-value pairs to 
form encode.

Seth

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Tracy 
Spratt
Sent: Tuesday, May 15, 2007 11:02 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Problem with post

I have never typed the request object as URLVariables, always as a plain 
Object.  Try that to see if it has any effect.
Tracy
 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of 
Guillermo Villasana
Sent: Tuesday, May 15, 2007 1:14 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Problem with post
 
Is there any reason why if i send with method post, one variable will 
not be sent ?

var params:URLVariables=new URLVariables();
var myservice:HTTPService=new HTTPService();

params.var1=event.values[0];
params.var2=event.values[1];
params.var3=event.values[2];

myservice.method=post;
myservice.url.etc

myservice.send(params);

the odd things is that var1 no matter where I put it, is not sent, but 
if I just change .method=post to .method=get
then everything is sent correctly...
any thoughts?

Terius