0

I have a json and image files in my projecy directory:

-project
--index.html
--json
----json01.json
----json02.json

I know hot to get the file using http, but there us a way to list all files url's in json directory?

accessing local files is impossible- access-local-files, but this is also apply on project files/folders?

Thanks.

Community
  • 1
  • 1
Itsik Mauyhas
  • 3,824
  • 14
  • 69
  • 114
  • 2
    are you talking about client side or server side javascript? – eis Oct 10 '16 at 07:25
  • client(where the index, css, etc...). – Itsik Mauyhas Oct 10 '16 at 07:26
  • 1
    the only two ways are to get it is returning it from your server in some way or brute force (which is usually not acceptable :D). JavaScript cannot do it alone – smnbbrv Oct 10 '16 at 07:31
  • Yes, I belived that this will be the answer, thanks. – Itsik Mauyhas Oct 10 '16 at 07:34
  • 1
    Question looks like a duplicate of these: [1](http://stackoverflow.com/questions/27860507/listing-files-of-a-directory-in-a-webpage) [2](http://stackoverflow.com/questions/6994212/is-there-a-way-to-return-a-list-of-all-the-image-file-names-from-a-folder-using) [3](http://stackoverflow.com/questions/2924935/list-files-in-a-directory-using-only-javascript), probably lot of others as well. In short, no, it cannot be done with just client-side javascript. – eis Oct 10 '16 at 07:35

0 Answers0