PDA

View Full Version : Array Help


fitz
10-09-2002, 02:33 PM
I have written a javascript function that automatically builds a table with images and text taken from two arrays.

What I want to know is this:

Is it possible to write a script that automatically builds an array by scanning a folder's content and adding the necessary files to the array.

I want to do this so someone can just drop files in a folder and not worry about updating the arrays.

So, if a folder contains 7 images one day and someone puts in 3 more than the array would automatically be built by using the names of the images when accessed by the calling script.

Is this possible? If so, could you give an example of what the function would look like? I am a novice in coding btw, so please excuse anything that seems like stupidity on my part!

Thanks in advance for any help you can give.

Alekz
10-09-2002, 02:52 PM
Hi,
If the images are in the local computer, this could probably be done with IE with low security settings, as You can create a Scripting.FileSystem object...
In general, You'll have to use some server side scripting to get this done...

Alex