request array

Aug 18, 2007 at 3:05 PM
Edited Aug 18, 2007 at 3:08 PM
Hi,
This probably a stupid question but i can't figure out how to request an array that's been POSTed. In particular the array from the fb:multi-friend-input.
I know for a string variable, for instance it would be: string y = request"x";
So i undestand the array is called "ids". But could someone advise me how to request it... Sorry, I'm a noob and can't seem to find the answer on google.
Many thanks in advance,
Kane
Aug 24, 2007 at 5:19 PM
Edited Aug 24, 2007 at 5:52 PM
Request.Form("ids[0]") will retrieve the first user id in the array POST by fb:multi-friend-input

you could loop through the array and get the ids using something like the following... (note: multi-friend-input allows a maximum of 20 friends at one time)

Dim uid As String
Dim i As Integer

For i = 0 To 19

If Request.Form("ids[" & i & "]") <> "" Then

uid = Request.Form("ids[" & i & "]")

Response.Write(uid)

End If

Next