For doing formatting with the printf(), there is need to wrap output in <pre> tags. Is this the best way of showing formatted plain text on a browser?
<pre> tags can be useful if you want to preserve plain-text formatting in an HTML context.
If you want to output an entire text document to the browser, however, it is neater to tell the browser to format the entire output as plain text. You can do this with the header() function:
Header (“Content-Type: Text/Plain”);
If you want to output an entire text document to the browser, however, it is neater to tell the browser to format the entire output as plain text. You can do this with the header() function:
Header (“Content-Type: Text/Plain”);
