Most Efficient Way of Combining Large Strings for HTML Response

In the bigger picture of this code, this function simply builds the HTML and passes it back to the http client response handler to send it to the requesting client. So it needs to be in a variable to pass around, not serial printed.

sterretje:
Why build a full string? You can print the individual parts piece by piece; they end up in a buffer before being send.

Serial.print("Hello ");

Serial.print("World!");



has the same effect as


Serial.print("Hello World!");