How can I iterate through files in Javascript

前端 未结 4 1846
小蘑菇
小蘑菇 2021-01-21 05:08

Is it possible to iterate through a collection of files in Javascript? I am writing a jQuery plugin that takes either an array of images or, I was hoping, a directory containin

4条回答
  •  时光取名叫无心
    2021-01-21 05:59

    You should use server side language to provide array of images in JSON or similar. There is no way Javascript can access local files. That would be serious security issue.

提交回复
热议问题