Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

This is one thing that has been annoying me for sometime.

For some files, whenever I download them via Filezilla, and opening them up in Eclipise/Dreamweaver IDE, it will result in double line spacing. On the server, it is single line-spacing, and in Notepad as well.

Checking a hex editor, it seems that the newlines got mangled. Instead of

\r\n

or just a

\r

I get a \r\n\n

And I have to use the hex editor to fix the problem. Any ideas what may be wrong here? Maybe some settings in Filezilla?

Thanks!

share|improve this question

1 Answer 1

up vote 5 down vote accepted

Unix, Windows and Mac systems all have their own newline characters. When transferring files as ASCII, most FTP clients convert these newlines if applicable. So: one could set up Filezilla to handle text files as ASCII.

However, it seems that the newlines in the files on the server do not match the operating system of that server. Hence, when using automatic conversion, things get messed up. So, like @Manni suggested: you need to ensure all files are handled as "binary", not as ASCII.

(Note that many other files, such as program files, Word documents, music and images always need to be transferred as "binary", to ensure no automatic conversion is done.)

share|improve this answer
    
My recommendation would have been the exact opposite: tell your client to handle all files as binary so it won't mess with them. –  innaM Sep 11 '09 at 8:20
    
Ah, I missed the "\r\r\n" –  Arjan Sep 11 '09 at 8:23
    
Much better. Thank you. –  innaM Sep 11 '09 at 9:07

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.