Use LoadVars to get array into Flash

I’m trying to use a LoadVars object to load in an array from a php script that reads the filenames of all jpg files in a certain directory.

Would this be possible, or would I have to pass all filenames as one string and split it within Flash afterwards?