getURL POST & GET won't work
I've put the same variable name with the same content all over the flash movie, even inside the on(release).
Then I go:
on (release) {
var picho:String = "hola";
getURL("http://myurl/index.php", "GET");
}
Before that I used "_blank" in between, but I took it away as I read was causing problems to someone. Same thing:
The php script doesn't get anything, the address bar doesn't show any variables and I ran out of searching options for the solution.
This is a Flash 8 movie loaded into CS3.
Thanks for any suggestion.
This worked for me, except one thing
I was having similar problem, except that I NEED to get the data in POST method to prefill another webform. toltec7's code worked miracle for me, only thing I needed to change is adding "_blank" in the getURL call.
Code:
movClip.getURL("http://myurl/index.php", "_blank", "POST");
THANK YOU!
Quote:
Originally Posted by
toltec7
you should do that code in timeline I guess...
so name you button (instance name)
and do this on _root or some other timeline...
button.onRelease = function () {
var movClip:MovieClip = _root.createEmptyMovieClip("mov", _root.getNextHighestDepth());
movClip.picho = "hola";
movClip.getURL("http://myurl/index.php", "POST");
}
that really should work if you wanna send with POST.
you can send with GET by adding a query string like the other guy explained...