array in html header
- Started
- Last post
- 11 Responses
- cram
working page:
i want to be able to send someone a link to this page and have their seats highlighted. to do this i believe that i need to be able to pass an array of variables to flash from the link. how can i do this? any help would be appreciated...
if i can get the data from the link into flash, i know how to manipulate the data to mark the seats.
cheers...
matt
- slappy0
If you link directly to the swf you can just put the variables on the end of the url
ie flashMovie.swf?Variable1=02
otherwise you might need to dynamically add this query to the embed src= in the page.
hope that helps
- cram0
i didn't know that. what about an array of variables? is that possible?
- cram0
ok, that creates new problems... i need the html scrollbars. directly linking seems to make it 100%.
- acescence0
you've got mail
- cram0
thanks, acescence. i might be able to get that to work.
still, i am curious about sending an array. maybe it isn't possible?
- UndoUndo0
its not possible to send data as arrays via a URL
- colag0
send all your seat id's into flash like this:
.swf?seatid=1,2,4,5,6,7
where the numbers are the relevant seats to be highlighted. once the variable is in flash you can split it into array. therefore, in a round-aabout way it is possbile to send an "array" via URL.
- tomkat0
1. make the file a php file
2. where you embed the swf make it "file.swf?myArr={$myArr}"
(outputting a php var)3. before the embed:
$myArr = $_GET["params"]4. call the url like this:
myfile.php?params=1,2,3,45. in Flash:
arrSeats = myArray.split(',');there you have it.
- eu770
I have no idea if this might be a suitable alternative (sounds like youve done all the work in flash already) - but if you fancied doing it with CSS...
- ldww0
why do you have that in flash? there is nothing... flashy about it. you could just make that in php with html an highlight the seat easier
- colag0
not everyone has access to a server that has server-side scripting such as PHP and ASP. flash is ideal!