Filezilla removes line breaks on php files [duplicate] - ftp

This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
How can I stop Filezilla changing my linebreaks?
For some reason Filezilla sometimes removes line breaks on my php files making the code appear on a single line giving me a bunch of errors when I upload my projects, I was looking around and changed my transfer type to Binary but I still have the same issues, downloaded CuteFTP as well but same problem.
Does anyone know what can I do to fix this?
Thanks in advance!
EDIT: Now that I check, when I upload the files to my hosting they look in one line as well, but it doesn't give me any errors, the problem is when I upload to my clients host, could it be some configuration on the hosting or something?

change the "Transfer" to "Binary" (Do not keep it as a "Auto"). Restart Filezilla and upload files as it is.

Well, I managed to solve my problem, I dont exactly know how I just deleted the folder, uploaded as ASCII again, changed to Binari, restarted Filezilla, deleted the files again, and re-upload it as Binari again. For some reason it works now, maybe you have to restart Filezilla to apply the changes correctly.

Sounds like it may not be the FTP that is entirely the issue. If you're saving these files using the wrong encoding, this undesired result can be achieved. What program are you saving these files in?
If you have a file on the server in question that is formatted properly, download it with the FTP programs, then upload it without re-saving it. Check the downloaded copies and the uploaded copies to see if the issue is still occurring.

Related

VScode: how to setup for local edit and ftp-deplyment

I used to use Dreamweaver. I've a huge Classic ASP website. I edit the files on my local system, and when done, I can upload the file(s) via ftp to the remote webserver. Now, I try to switch to VSCode. I've installed ftp-simple, ftp-sync and deploy. But can't find the set-up to get a Dreamweaver like behaviour. Eg, I have to locate for each file I want to upload/deploy, the exact location in the remote file tree.
I really feel like deploy deserves more attention. I spent the past 4 days or so to find an extension that does just that. Auto-upload to an ftp-folder from a local folder. I wanted to make git work for my website, but couldn't get that to work on the server with ftp-simple or ftp-sync because those extensions only download the opened files or open in a different temporary folder each time. I set up deploy now and got exactly what I wanted thanks to your tiny comment, thank you!
(I'm sorry if this post is too old to comment on, but I browsed Stack overflow for days to find this, so I thought it might help others in the future to point this out.)
it sounds like your just missing your mapping configuration. Most text editor FTP packages include a configuration file where you specify the server, your credentials, and the root folder of your ftp server. Have you specified this?

Intermittent instances of 0 byte file downloads

I've been having issues lately with a VBScript that will download files from an FTP server. It's been working ok for some years, but recently it's been downloading 0-byte files, they're just empty. This should never be the case.
In troubleshooting, I tried downloading a batch of files using the FTP command in CMD, and a different set of files were downloaded that were 0 bytes. (Btw, this is why I didn't add WINSCP and VBScript tags). Upon re-attempting the download of these empty files, I notice they download ok without issue, they come with data. What could be the issue here? What else can I try? Specifically, while keeping the OS, as I do not really have control over this.
Thanks.
I wrapped the download code into a loop, and in each iteration confirmed the file's existence and size by calling a function, and passing it the filename. Doing this allows me to log more and see that the 0-byte downloads happen more often than I thought.

Files uploaded via FTP aren't showing changes on Squarespace Developer Mode

My squarespace site is in developer mode. I download files, like the .region, .less, and .conf files and edit them locally. I upload these files and expect to see a change on the squarespace site.
Up until yesterday this was working, then I made a mistake in one of the LESS files and got an error about incorrectly parsed JSON in the .conf file where the LESS file was included. I got a whole ton of errors from this, and have since then fixed both the LESS file and the .conf file.
However, the issue is that my squarespace site is now not registering that any changes have been uploaded, despite the fact that my FTP files are successfully being uploaded and downloaded from the FTP server.
I have also not seen any updates to my Git on the developer mode tab since this error was registered.
My question is how to fix this, and how to start seeing edits done locally to region, etc, files again.
You can try to turn off the developer mode and then turn it on back.

Filezilla not updating files

I made a modification in a php file and uploaded it via Filezilla. It always worked fine for me, even if sometimes it would not upload immediately. This time, however, it's not working anymore in any way. I upload the file with the same name and it looks like it overwrites the old one, but the size of the file doesn't change. When I open the site on the browser (I've been testing in Chrome and Firefox and already cleaned their caches many times since then, and still nothing happens) and look at the source code, it shows the new code with the modification, but even so the site is still the same old one. When I open the file directly from Filezilla it also shows the modified file, but the file size doesn't change. It started yesterday, before the upgrading to version 3.7.3. It's updated now, but the files are still not being updated. I also tried renaming the file, deleting it from the ftp and uploading again, uploading it to another folder and then moving it to the root, but nothing happens. Any idea of what can be causing this?
It turns out it was a problem with the permissions with the host. I contacted them and the issue was solved.

How do I schedule for all the files of one folder to be moved to another server?

I did a quick search and couldn't see anything that was relevant which I found strange as this seems like it'd be a common question. Maybe I'm just going the wrong way about it or being thick? Who knows.
Anyway, I am trying to set up a scheduled task that moves all the files in a folder from Server A to a folder in Server B. If this was a simple matter of copying them it would be fine as I'd already got that working using Core FTP and a batch file but I'd like them to be removed from Server A after the copy has taken place.
I was looking at the windows ftp commands but although I managed to log onto Server A successfully from Server B whenever I tried to do a command it just took a very long time and then disconnected.
Any help in this would be appreciated, I need it to be a schedule-able file but it doesn't matter whether it is a .bat, .vbs or anything else that I haven't though of?
Thanks,
Harry
You could use www.Dropbox.com
Why? For stability. Any home-brew ftp script that moves files, is prone to an undetected error in transmission, resulting in deleted files.

Resources