Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: PHP File and Editor Issues

For tracking: The problem is caused by bug in ascii transfers in MySecureShell.
Anonymous User

Re: PHP File and Editor Issues

prikryl, I have sent you an email with the information you requested.
martin

Re: PHP File and Editor Issues

Please download the file using binary mode to your local machine, archive it (e.g. to ZIP file) and send it to my email. Thanks. You may also try to reupload the file back under the different name and verify the the problem still appears, so I should be able to reproduce the problem on my system. Also what is your server? FTP/SCP/SFTP? What OS?
Anonymous User

Re: PHP File and Editor Issues

One more bit of clarification: It is not necessarily HTML or other PHP scripts that do not display - any text entered after the closing tag is 'truncated', but the whitespace and number of lines are both retained.
Anonymous User

Re: PHP File and Editor Issues

Sorry for the delayed response. This was attempted in both WinSCP 4.1.5 (Build 410) and WinSCP 4.1.6 (Build 412).

Yes, prikryl, what you have for the example is similar, but any addition to the end of the script will not be shown.

For example:
<?php\n

code\n
code\n
?> \n
<html here>\n
<php\n
code\n
?>


Anything that is included after the first "?>" will not be displayed in any editor if opened directly from the server through WinSCP.

Hope that clarifies.
inetbizo

edit files not in linux format

I've been using the internal editor and the files are not being saved in unix format but windows and therefor corrupts the linux file. I cannot find setting to make sure file is saved in unix format without windows EOF
martin

Re: PHP File and Editor Issues

I'm not able to reproduce this. Neither with external not internal editor. What version of WinSCP are you using? Do I understand right that the file looks like:
<?\n

code\n
code\n
?>
Anonymous User

PHP File and Editor Issues

Running a Debian server and performing modifications to a .php script on a Windows XP environment. Opening files from WinSCP either through the internal or an external editor will display blank lines after a closing PHP statement, ?>.

I have modified end-of-file settings with no positive results. This has been tested on two different machines with the same result, with files created in multiple editors.

The issue does not seem to appear in other documents, only in documents that have a closing PHP statement in the middle of the file.

Note that copying the file to a directory and opening it locally will result in the file being displayed properly.

Is this a bug or is there a setting I have missed?