#159354 - 06/05/2003 12:53
Frustrated
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
Okay, I did all my web stuff in Notepad. Now, every once and a while I need to pull a file off the server and edit it instead of the file on my box. But when I open it, I guess all the new line characters have been removed, and everything's been compacted into one or two lines. What causes this? How do I avoid it? I've already had to go through several pages and put hard returns back in them so I could read them again.
It happens to all my files, too. I just looked at a CSS file I downloaded and it's all in one line.
I switched to Wordpad because I thought Notepad was causing something funky with its "word wrap" thing. I like using Wordpad better, but this still happens to some files. How can I prevent this?
_________________________
Matt
|
Top
|
|
|
|
#159355 - 06/05/2003 12:54
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Unix file conversion. Use UltraEdit instead of Notepad.
More details in the "One final note" in this FAQ entry about the player, but it counts for what you're encountering here, just in reverse.
|
Top
|
|
|
|
#159356 - 06/05/2003 13:19
Re: Frustrated
[Re: tfabris]
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
So the change comes when the files are put on the Unix server, or are all the files I've made with Note/Wordpad screwed from the start? Will Ultraedit open them in the good format or the messed up format?
*edit*
I'm also not hot on buying a program like that. Is it basically as simple as Word/Notepad? I use those programs because they don't mess with anything. I don't want something writing code for me (although it would probably better than my own )
Edited by DiGNAN17 (06/05/2003 13:20)
_________________________
Matt
|
Top
|
|
|
|
#159357 - 06/05/2003 13:27
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
Unix, DOS/Windows, and MacOS all store text files in different formats. You the end user are interested in text and where the line ends. But the OS needs to store the line end as a character, which is unlike how the user thinks of it. Each of those OSes uses a different character (or sequence of characters) to mark the end of a line.
Exactly which one was used depends on the OS and editor used. Your description of all the line splits disappearing makes it sound like it was created on a Unix machine and transferred to your Windows machine.
You can create and edit Unix-style text files on a Windows machine with the right editor. UltraEdit that Tony suggested is one. My favorite is vim, but it's a vi clone, which means it isn't beginner-friendly. But it's free and will do what you need, transparently, if the file already exists.
Edit: You might also want to check out EditPad Lite. It's also free and will do the right things.
Edited by wfaulk (06/05/2003 13:31)
_________________________
Bitt Faulk
|
Top
|
|
|
|
#159358 - 06/05/2003 13:28
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
I'm also not hot on buying a program like that. Is it basically as simple as Word/Notepad? I use those programs because they don't mess with anything. Right. Neither does UltraEdit unless you want it to.
UltraEdit is like Notepad on steroids.
It doesn't write code for you, but if you open a code file (such as HTML), it will syntax-highlight it for you.
It doesn't have the 32k file size limitation of Notepad. You can open files of any size, including many gigabytes if you wanted.
It has a binary editor mode which many people consider indespensible.
If you've been doing all your web editing in Notepad, using UltraEdit is like taking off the boxing gloves.
It can directly edit the files on the file server (no more "download, save, upload").
I never use Notepad any more, everything gets opened in UltraEdit.
|
Top
|
|
|
|
#159359 - 06/05/2003 13:29
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
One other thing to consider is how you're transferring these files. If it's by FTP, then FTP's ASCII and Binary modes do this sort of thing for you. My guess is that you're using it to upload the files to the server, but not to download them, or at least the mode is set incorrectly on the download.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#159360 - 06/05/2003 13:38
Re: Frustrated
[Re: Dignan]
|
veteran
Registered: 19/06/2000
Posts: 1495
Loc: US: CA
|
I use Komodo for PHP development, but you probably don't want to shell out any money at the moment. In that case, I suggest using TextPad or UltraEdit, as Tony mentioned. Great thing about TextPad is it has syntax highlighting for every imaginable language/file format, etc. I haven't used UltraEdit in a while, but I'm guessing it might have those features as well. <shrug>
_________________________
Donato MkII/080000565 MkIIa/010101253 ricin.us
|
Top
|
|
|
|
#159361 - 06/05/2003 13:38
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 30/10/2000
Posts: 4931
Loc: New Jersey, USA
|
Good program that converts between DOS, Unix, and Mac formats. It's pretty-much free. It's shareware, but there is no nagging (that I've ever seen).
Attached
Attachments
157502-icsnc075.zip (23 downloads)
_________________________
-Rob Riccardelli 80GB 16MB MK2 090000736
|
Top
|
|
|
|
#159362 - 06/05/2003 14:25
Re: Frustrated
[Re: tfabris]
|
pooh-bah
Registered: 25/08/2000
Posts: 2413
Loc: NH USA
|
One other excellent feature of UltraEdit is that it can also select columns of information from a text file, which can be mighty handy at times.
-Zeke
_________________________
WWFSMD?
|
Top
|
|
|
|
#159363 - 06/05/2003 14:30
Re: Frustrated
[Re: tfabris]
|
carpal tunnel
Registered: 17/01/2002
Posts: 3996
Loc: Manchester UK
|
I'll second Ultraedit, I was lucky enough to get the beeb to pay for my licence. But it's brilliant, I write almost everything in it now (apart from my windows C++ and word processing) and i've found its unix conversion tools invaluable.
_________________________
Cheers,
Andy M
|
Top
|
|
|
|
#159364 - 06/05/2003 15:05
Re: Frustrated
[Re: wfaulk]
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
One other thing to consider is how you're transferring these files. If it's by FTP, then FTP's ASCII and Binary modes do this sort of thing for you. My guess is that you're using it to upload the files to the server, but not to download them, or at least the mode is set incorrectly on the download. This is the part that's concerning me the most. I'm sure that's where it's being done. I'm just using CuteFTP to upload and download files. I create everything and store everything on my own machine, then upload it to the server.
In some instances, I've needed to edit the file on the server instead of the one on my machine, or the one on my machine has been lost for whatever reason. Sometimes I get this problem I'm talking about. Other times the file looks normal. I'm not sure what the reason is.
_________________________
Matt
|
Top
|
|
|
|
#159365 - 06/05/2003 15:08
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
There should be an option for ASCII in Cute FTP somewhere. When you're transferring text files, make sure that it's always set to ASCII.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#159366 - 06/05/2003 15:24
Re: Frustrated
[Re: wfaulk]
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
But you need binary for some files, right?
_________________________
Matt
|
Top
|
|
|
|
#159367 - 06/05/2003 15:37
Re: Frustrated
[Re: Ezekiel]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
One other excellent feature of UltraEdit is that it can also select columns of information from a text file, which can be mighty handy at times. Oh, yeah, how could I forget Column mode! That is the bidness.
|
Top
|
|
|
|
#159368 - 06/05/2003 15:55
Re: Frustrated
[Re: tfabris]
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
Okay, so I'm trying out the program. It's interesting. I do like the color coding, that always makes things a little more readable.
I also forgot how much Bitt is into tabs I'm not a tabs person myself, but I like the program. What is the keyboard shortcut to switch between tabs? I don't think I can use it without one
Also, is there a way to turn off the yellow highlighting of the line your on? I like the box that highlights the closing > or <, but the yellow bar is quite annoying, unless there's some other purpose to it than to draw your attention to which line you're on. The cursor is enough for me.
*edit*
Actually, I think I see why the yellow bar annoys me. For some reason, it turns any black text on the line blue. Why would it do that? It leaves all the other colors alone...
Edited by DiGNAN17 (06/05/2003 15:56)
_________________________
Matt
|
Top
|
|
|
|
#159369 - 06/05/2003 15:59
Re: Frustrated
[Re: tfabris]
|
carpal tunnel
Registered: 14/01/2002
Posts: 2858
Loc: Atlanta, GA
|
Oh, yeah, how could I forget Column mode! That is the bidness. Having never used UltraEdit, I don't know how it specifically works, but column mode is essential for me. It works great in Borland's IDE, but it's implementation in Visual Studio (or the last time I tried it anyway) was miserable. It's all about where the cursor ends up after a paste.
_________________________
-Jeff Rome did not create a great empire by having meetings; they did it by killing all those who opposed them.
|
Top
|
|
|
|
#159370 - 06/05/2003 16:07
Re: Frustrated
[Re: Dignan]
|
veteran
Registered: 19/06/2000
Posts: 1495
Loc: US: CA
|
What is the keyboard shortcut to switch between tabs?
Should be Ctrl-Tab.
_________________________
Donato MkII/080000565 MkIIa/010101253 ricin.us
|
Top
|
|
|
|
#159371 - 06/05/2003 16:20
Re: Frustrated
[Re: tfabris]
|
veteran
Registered: 21/01/2002
Posts: 1380
Loc: Erie, CO
|
Bah! I used UltraEdit for a while, but switched to JEdit permanantly a bit ago.
JEdit is free, open source, and has many plugins, available from it's plugin manager.
http://jedit.org/
It also highlights PHP correctly, as well as C and of course Java. It's my one-stop-shop.
|
Top
|
|
|
|
#159372 - 06/05/2003 16:28
Re: Frustrated
[Re: cushman]
|
veteran
Registered: 19/06/2000
Posts: 1495
Loc: US: CA
|
Very nice, I like it. Never heard of it before, though. I do all of my development in Linux, and Komodo is the best solution I know of. Now that I know about jEdit, I'd say that's my first choice for a non-commercial (read: free) editor/IDE.
Edit: Oh look! There's even an ebuild for it in the portage tree for Gentoo.
Edited by ricin (06/05/2003 16:31)
_________________________
Donato MkII/080000565 MkIIa/010101253 ricin.us
|
Top
|
|
|
|
#159373 - 06/05/2003 16:36
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
I'm not a tabs person myself, but I like the program. Me neither. I'm running an older version of UltraEdit and I don't have the tabs, I think you can turn them off in the options.
Also, is there a way to turn off the yellow highlighting of the line your on? I'm sure there is. My version doesn't even have that option, but I can't imagine he'd leave that non-configurable.
|
Top
|
|
|
|
#159374 - 06/05/2003 17:22
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
But you need binary for some files, right? Everything except text files.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#159375 - 06/05/2003 19:38
Re: Frustrated
[Re: wfaulk]
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
Hmm, then I think I'll keep it on auto. I don't think that's what's doing it.
So, do you think Ultraedit will, in fact, solve this? Or do I have to save the files in a Unix format?
_________________________
Matt
|
Top
|
|
|
|
#159376 - 06/05/2003 20:11
Re: Frustrated
[Re: cushman]
|
carpal tunnel
Registered: 08/03/2000
Posts: 12338
Loc: Sterling, VA
|
Bah! I used UltraEdit for a while, but switched to JEdit permanantly a bit ago I tried get that program to work, but I can't seem to get it installed. Is there a real installer for this program somewhere?
_________________________
Matt
|
Top
|
|
|
|
#159378 - 07/05/2003 07:00
Re: Frustrated
[Re: Dignan]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
I think I'll keep it on auto. But it may be the auto setting that's causing somefiles to be corrupted and others not. The only thing I can think of that could be the basis of a decision for it would be file extensions, and it might be seeing some as text and others not. do you think Ultraedit will, in fact, solve this It should at least mask it to the point where no one cares. I assume that the text files are only used on the Unix side. Keep in mind that many Unix programs that expect text files will not read them properly if they're not in Unix text file format. Some will, though. So if you see odd things happening, then non-Unix text files may be your problem. So, do you think Ultraedit will, in fact, solve this? Or do I have to save the files in a Unix format? To take a step back, the way that Ultraedit could solve the problem is by saving the files in Unix text format. But, I'm sure, you'll have to make sure that each file you create is in that format. (It'll probably retain the format for existing files unless otherwise told.) It seems to me that setting your FTP client to do the proper translation and keeping the text files in their native formats on each given platform would be easier.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#159379 - 12/05/2003 23:01
Re: Frustrated
[Re: tfabris]
|
carpal tunnel
Registered: 08/06/1999
Posts: 7868
|
It doesn't have the 32k file size limitation of Notepad.
For the record, Notepad in 2000 and XP do not have this limitation. All other points are still valid however.
I personally discovered BBEdit now that I find my time on a Mac platform is growing. I'm wishing Windows had an exact port of it.
|
Top
|
|
|
|
|
|