Diff for phpPlatonLib/Platon/Platon.php between version 1.18 and 1.19
| version 1.18, 2003/02/04 21:47:39 |
version 1.19, 2003/04/19 09:28:57 |
|
|
| } /* }}} */ |
} /* }}} */ |
| |
|
| /** |
/** |
| |
* Computes MD5sum of file like `md5sum' command does it. |
| |
* |
| |
* @param string $file filename |
| |
* @return string MD5sum of file or false if file not found |
| |
*/ |
| |
function md5sum($file) |
| |
{ |
| |
if (($fhandle = @fopen($file, 'r')) === false) { |
| |
return false; |
| |
} |
| |
$data = ''; |
| |
while (($tmp_data = @fread($fhandle, 1024)) !== '') { |
| |
$data .= $tmp_data; |
| |
} |
| |
@fclose($fhandle); |
| |
return md5($data); |
| |
} |
| |
|
| |
/** |
| * Escapes e-mail address. |
* Escapes e-mail address. |
| * |
* |
| * @param string $email e-mail address |
* @param string $email e-mail address |
Platon Group <platon@platon.org> http://platon.org/
|
|