Read data from external file and write to html table incl. images

Is it possible to read data from a file, for example txt, xml and so on, and write it into an html table? Different data should be read out per line in the file. For example:
Name, NameBaseID, BaseID, Code

The table should be divided as follows:
3 columns, in the first line there is a ‘Name’ in each column.
In the second line, images should appear for the names above them (the images have exactly the same name as ‘NameBaseID’ in the file to be read).
In the third line there is a button under each image that is supposed to display the ‘Code’ from the external file.
When you click on the button, the ‘Code’ is copied to the clipboard (I’ve already got this part figured out).
The fourth line consists of the 3 columns that should be joined together into one and should only contain a dividing line.

PHP is not an option here as this html should only be used for offline use. JavaScript shouldn’t be a problem here as long as no external JS files on the Internet are accessed.

I hope I was able to explain my intention well enough. I apologize for any typographical errors and thank you in advance for your help and support 🙂