What do modern companies use to build up the actual html page using data.
And what programming languages do they use to show the data in the html.
If they use Java for example, do they use an engine to pass the data to the html, or do they just add the variable to the html as a string? (for example: "<p>Hello" + name + "!</p>"
).
And how do they loop data in the html? Using just a for loop and adding it to an string? Or via an engine?
In PHP it's simple, but what do they use in stead of PHP to generate the html?
There are many ways to build up dynamic html pages, depending on what stack you use. What you are searching for are so called "Templating engines" - on the Java example there is a good article about template engines for java web applications: https://hackernoon.com/java-template-engines-ef84cb1025a4
If you use Python and Django as example, then you'll probably end up using Jinja2 as a template engine. It varies, depending, like said, what tech stack you are using. So to answer this question directly, the question is way too vast.