It sounds like you have a folder with images within, and you want to be able to automatically display all those images on the web-page without having to manually amend the HTML.
This doesn't seem possible from Javascript because it's client-side, so you'd need have the page built using a language like PHP, Java or ASP.NET where those languages can perform operations like listing directory contents, and then render the page dynamically based on the files it's found. The
PHP scandir()[
^] function is a good example of this.
There might also be some JS server-side frameworks which might work too, though I'm not aware of them I'm afraid!