Hi Leandro so getting rid of this part would be ok then and the error
wouldn't appear again.
var loader:URLLoader=new URLLoader();
loader.dataFormat=URLLoaderDataFormat.VARIABLES;
try
{
loader.load(request);
}
catch (error:Error)
{
trace('Unable to load requested
document.');
}
Gustavo
On Aug 7, 2009, at 7:23 AM, Leandro Ferreira wrote:
As far as I know, the loader.dataFormat refers to the loaded data,
not the
one you are about to send. My guess is that the error is on trying
to decode
the variables name/value pair on the loaded data (see that the
error is
triggered by URLLoader/onComplete())
Leandro Ferreira
Sent from Brasilia, DF, Brazil
On Fri, Aug 7, 2009 at 00:12, Gustavo Duenas <
[email protected]> wrote:
Hi coders, I have this code for a flash form
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.net.*;
this.sent.addEventListener(MouseEvent.CLICK, sendMessage);
function sendMessage(e:Event):void
{
var variables:URLVariables=new URLVariables();
variables.nombre=nombre.text;
variables.email=email.text;
variables.phone=phone.text;
variables.address= address.text;
variables.eventos=eventos.text;
variables.details=details.text;
var request:URLRequest=new URLRequest();
request.url='sendMail.cfm';
request.method=URLRequestMethod.POST;
request.data=variables;
var loader:URLLoader=new URLLoader();
loader.dataFormat=URLLoaderDataFormat.VARIABLES;
try
{
loader.load(request);
}
catch (error:Error)
{
trace('Unable to load requested
document.');
}
}
the fields are on the stage and those are input text.
when I click on the button,
suddenly it sends this message Error: Error #2101: The String
passed to
URLVariables.decode() must be a URL-encoded query string containing
name/value pairs.
at Error$/throwError()
at flash.net::URLVariables/decode()
at flash.net::URLVariables()
at flash.net::URLLoader/onComplete()
does anyone knows what this means?
help here pls.
Gustavo
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders