Hi All .. Sorry if this has been covered,
Small problem with eform when i attach a empty file,
I assume that i would need some type of if statement to check for 0 length in the file
but not sure how to code it in myself.
Any help would be greatly appreciated
Â« MODx Parse Error Â»
MODx encountered the following error while attempting to parse the requested resource:
Â« PHP Parse Error Â»
PHP error debug
Error: fread() [function.fread]: Length parameter must be greater than 0
Error type/ Nr.: Warning - 2
Line 1095 source: $file_buffer = fread($fd, filesize($path));
$magic_quotes = get_magic_quotes_runtime();
>>>>> $file_buffer = fread($fd, filesize($path));
$file_buffer = $this->EncodeString($file_buffer, $encoding);
Funny how old a thread can get before it's answered. I just ran into this problem and after I opened the file in my editor (from CyberDuck) and re-saved it, I realized that after just backing my site up, I had exceeded my disk-quota, and thus wasn't allowed to save anything anymore. That's why the filesize($path) was reading as zero (0).