mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Remove readBase64() from File utility, since it is not commonly used.
This commit is contained in:
parent
987c01856a
commit
b42a2d45e7
2 changed files with 1 additions and 12 deletions
|
@ -1386,7 +1386,7 @@ class CakeEmail {
|
|||
*/
|
||||
protected function _readFile($path) {
|
||||
$File = new File($path);
|
||||
return $File->readBase64();
|
||||
return chunk_split(base64_encode($File->read()));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -180,17 +180,6 @@ class File {
|
|||
return trim($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the contents of this File as a base64 version of the file contents.
|
||||
* The string is split into smaller chunks to match RFC 2045 semantics.
|
||||
*
|
||||
* @return string File contents in base64 encoding
|
||||
* @link http://book.cakephp.org/2.0/en/core-utility-libraries/file-folder.html#File::readBase64
|
||||
*/
|
||||
public function readBase64() {
|
||||
return chunk_split(base64_encode($this->read()));
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets or gets the offset for the currently opened file.
|
||||
*
|
||||
|
|
Loading…
Add table
Reference in a new issue