I am writing code where it is necessary to ftp mac files to our server. When using php's ftp_put function, it corrupts the files when transfered. What appears to be happening is that the ftp_put function is "loosing" the header id fork of the mac file format, however it does maintain the data fork. The problem is, that when the file is then on the server, or retrieved, my computer can not identify what program is required to open the file.
I have discovered that if I use the "STUFFIT" compression software before ftp'ing the file, maintains the integrity of the mac files.
Here are the questions.....
1) Does anyone know if there is anyway to maintain the mac file format without having to compress the file first with suffit, when ftp'ing files using the ftp_put php function?
2) If not, does anyone have insight as to how, and if I can call and run a c program from my php script, without making adjustments and modifications to the compiled and existing version of php that is running on our server?