I'd like to create a template html file that loads content from a text file so that I don't have to change the html if I want to change text content. I'd like this text to be interspersed with images so I'd like to be able to reference each paragraph from the text individually. Thus, I'm looking for something along the lines of:
<div><p txt= [first paragraph from file.txt]></p></div>
<div><p txt= [second paragraph from file.txt]></p></div>
<div><p txt= [third paragraph from file.txt]></p></div>
<div><p txt= [fourth paragraph from file.txt]></p></div>
...
where file.txt is specified once at the beginning of the html file and the number of paragraphs in the text file might be variable. I suspect I'll need to use javascript. Is there a way to load each paragraph into some variable that I can reference to change each text attribute? To my knowledge [previous solutions][1] have loaded the entire text file as a single text chunk.