0

I am trying to display a text file content in Body of the JSP Page.I used BufferedReader and StringBuilder for it. The file contents contains tab instead of spaces between words.While displaying ,the tab between words were displaying as single space between words in browser.

Thanks

1 Answers1

1

Use one of following

1. <PRE></PRE> blocks.
2. CSS - using padding
3. four times &nbsp;

After reading from file and while generating html you can use one of these options.

for more options refer this -

HTML: Tab space instead of multiple non-breaking spaces ("nbsp")?

Community
  • 1
  • 1
Ninad Pingale
  • 6,801
  • 5
  • 32
  • 55