I'm importing a text file from an outside directory into an html paragraph tag to be displayed when a button is clicked. I'm using jQuery's .load() function to do this.
The text file gets imported no problem, but the format is not kept,
The imported text file 'banks.txt' comes through as:
"Love Poem Serene, In a world full of troubles, i.e. doing nothing about it. - Iain Banks"
instead of:
Love Poem
Serene,
In a world full of troubles,
i.e. doing nothing about it.
- Iain Banks
Is there a way to keep the text-file's formatting- newlines, tabs, and all?