Uploading a PHP file, cPanel adds line of gobbly guk to top of file

railx

Registered
Sep 3, 2004
2
0
151
Anyone ever heard of this happening?

When I upload a file with a ".php" extension or with no extension, a line of text including the file name and a bunch of random characters is added to the top of the file. This prints to the screen when you view the file in a browser and prevents some php functions from working.

When I use ftp this does not happen.

When I upload an ".html" file this does not happen. In fact, ".html" files are recognized as ASCII while the ".php" files are being identified as some type of Macintosh binary file.

I have not found any reference to this on the web and the support guy for my host server doesn't understand or believe that this is happening.

Am I the only one?
 

SarcNBit

Well-Known Member
Oct 14, 2003
1,001
3
168
That sounds like an ftp client problem not a cpanel issue.

Try turing off auto format detection and force ascii uploads from your client.
 

railx

Registered
Sep 3, 2004
2
0
151
Is this something I can do from cPanel? I've searched around and can't find anything about auto detection or forcing ASCII uploads.