View Full Version : Text File Help
BigTom
February 20th, 2002, 22:24
I know this may be a stupid question, but how do I format a text file so that when it displays in a browser it word-wraps?
Notepad doesn't do it, WordPad doesn't do it, and my downloaded text-editor doesn't do it either. But I've seen it done. Any ideas?
:confused:
Jan
February 20th, 2002, 22:29
Notepad has a wordwrap function if that is what you mean.
BigTom
February 20th, 2002, 22:33
Nope. I know I can turn Word-Wrap on in Notepad, but it doesn't display that way in browsers.
I believe what I'm looking for is a way to make the text into a .TXT File With Line Breaks
I believe that's what it's called.
Jan
February 20th, 2002, 22:38
Check in your html editor to see that there are no <br> except at the end of a paragraph.
BigTom
February 20th, 2002, 22:45
Sorry to keep saying this, but that's not it either.
When you save a text file as .txt in Notepad and then link to it in a website, it displays as one long text string.
I'm looking for a way to format the .txt file itself into having line breaks. I've seen it done, all the time.
Jan
February 20th, 2002, 22:51
Try using shift/enter after each line instead of just enter. That will force a line break.
meow
February 20th, 2002, 23:37
I don't think that can be done. You mean you want to put it up as it is, as .txt? What you've seen is probably hard line breaks that happened to fit your browser window.
BigTom
February 20th, 2002, 23:41
I think Word can format it correctly. Except my copy doesn't work right now. I need to re-install it.
However, if you go into Word and chose Save As it says text with line breaks, and that seems to work.
meow
February 20th, 2002, 23:55
Any text editor saves the line breaks. But that doesn't make a BROWSER wrap the text. It will just display it as it's written with hard line breaks.
BigTom
February 25th, 2002, 23:07
Saving it as TEXT WITH LINE BREAKS in MS Word corrects the problem and .txt files will wrap.
:)
meow
February 25th, 2002, 23:50
Uh, if that makes it wrap in the browser you mean something else with wrap than I do. Don't you mean that <br>'s get inserted? Making hard line breaks? Wrapping is when the long lines automatically break at the end of the window. :confused2
Powered by vBulletin® Version 4.1.7 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.