all groups > flash actionscript > december 2007 >
You're in the

flash actionscript

group:

posting variables to an asp page from flash


posting variables to an asp page from flash Concept Guy
4/30/2004 6:36:09 PM
flash actionscript: I tried asking this earlier on im my project but I think I'm far enough along
toask it a bit clearer now...
I have a a flash movie with a map...
when you click on the map it highlights a region or multiple clicks will
highlight multiple regions.
when a region is highlighted it switches a variable named grid1( or
corressponding grid number) to 1. there are 25 regions on the map.
I have build a send button that will be used to send the highlighted regions
to an asp page. the asp programmer will then take my variables (the highlighted
map regions)and serve up the requested info...

does anyone have experience sending variables from flash to an asp page....
I need help with the button code that executes this command.

any help is appreciated
Re: posting variables to an asp page from flash forareason
4/30/2004 7:20:18 PM
try using something like this

mybutton_mc.on(release) {
getURL(default.asp[url variables here], "_blank", "get");
}
Re: posting variables to an asp page from flash Concept Guy
4/30/2004 8:06:49 PM
Thank you for the help...just to clarify,

where you say [url variables here] thats where I list the variables I want to
send and the values, right ?
( variable1=1&variable2=1&variable3=1...etc?)
and do I need to include the[ ] brackets?

thanks again

Re: posting variables to an asp page from flash forareason
5/1/2004 12:08:19 AM
Yes where it says url variables you would put the information that you want to
send to the asp page. Then the asp page would request the information from
those variables and poof....its magic!

no you do not need to include the brackets, i just put them there to show you
where the variables would go.

well get will display the variables in the URL string of your browser and the
post will keep it hidden until requested through code. Whether you need to use
"get" really depends on if you are using a flash form and then having them hit
submit and then transfer the information. If you are doing this then you need
to use "get". If you already have the information in your flash application
and are just wanting to send it then you can simply just use variables in the
URL string and leave the method ("get") blank

hope this helps.
Re: posting variables to an asp page from flash Concept Guy
5/1/2004 11:20:47 AM
RE: posting variables to an asp page from flash Chandresh Kumar Chhatlani
12/6/2007 5:49:14 AM
Use as follows:

test1 = New LoadVar();
test1.var1 = "Text Variable"
test1.var2 = 123456;

test1.OnLoad = function(success);
{
if (success)
{
trace("Sent Data")l
}
else
{
trace("some err")
}

test1.send("http://www.a.com/a.asp?id=" + getTimer());
}

From http://www.developmentnow.com/g/69_2004_4_0_0_340979/posting-variables-to-an-asp-page-from-flash.htm

Posted via DevelopmentNow.com Groups
AddThis Social Bookmark Button