mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Add docs.
This commit is contained in:
parent
6ce4a3a1ec
commit
71507796c7
2 changed files with 20 additions and 1 deletions
|
@ -51,6 +51,20 @@ App::uses('Hash', 'Utility');
|
|||
*
|
||||
* This would allow you to have different pagination settings for `Comment` and `Post` models.
|
||||
*
|
||||
* #### Paginating with custom finders
|
||||
*
|
||||
* You can paginate with any find type defined on your model using the `findType` option.
|
||||
*
|
||||
* {{{
|
||||
* $this->Paginator->settings = array(
|
||||
* 'Post' => array(
|
||||
* 'findType' => 'popular'
|
||||
* )
|
||||
* );
|
||||
* }}}
|
||||
*
|
||||
* Would paginate using the `find('popular')` method.
|
||||
*
|
||||
* @package Cake.Controller.Component
|
||||
* @link http://book.cakephp.org/2.0/en/core-libraries/components/pagination.html
|
||||
*/
|
||||
|
|
|
@ -946,13 +946,17 @@ class CakeEmail {
|
|||
* $email->attachments(array('custom_name.png' => array(
|
||||
* 'file' => 'path/to/file',
|
||||
* 'mimetype' => 'image/png',
|
||||
* 'contentId' => 'abc123'
|
||||
* 'contentId' => 'abc123',
|
||||
* 'contentDisposition' => false
|
||||
* ));
|
||||
* }}}
|
||||
*
|
||||
* The `contentId` key allows you to specify an inline attachment. In your email text, you
|
||||
* can use `<img src="cid:abc123" />` to display the image inline.
|
||||
*
|
||||
* The `contentDisposition` key allows you to disable the `Content-Disposition` header, this can improve
|
||||
* attachment compatibility with outlook email clients.
|
||||
*
|
||||
* @param string|array $attachments String with the filename or array with filenames
|
||||
* @return array|CakeEmail Either the array of attachments when getting or $this when setting.
|
||||
* @throws SocketException
|
||||
|
@ -991,6 +995,7 @@ class CakeEmail {
|
|||
* @param string|array $attachments String with the filename or array with filenames
|
||||
* @return CakeEmail $this
|
||||
* @throws SocketException
|
||||
* @see CakeEmail::attachments()
|
||||
*/
|
||||
public function addAttachments($attachments) {
|
||||
$current = $this->_attachments;
|
||||
|
|
Loading…
Reference in a new issue