$_params
$_params : array
Hash containing connection parameters.
Wicked storage implementation for the Horde_Db database abstraction layer.
getAttachedFiles(string $pageId, boolean $allversions = false) : array
Retrieves data on files attached to a page.
string | $pageId | This is the Id of the page for which we'd like to find attached files. |
boolean | $allversions | Whether to include all versions. If false or omitted, only the most recent version of each attachment is returned. |
An array of key/value arrays describing the attached files.
attachFile(array $file, string $data)
Attaches a file to a page or update an attachment.
array | $file | This is a key/value array describing the attachment: 'page_id' => This is the id of the page to which we would like to attach the file. 'attachment_name' => This is the filename of the attachment. 'change_log' => A change log entry for this attach or update operation. (Optional) 'change_author' => The user uploading this file. If not present, the currently logged-in user is assumed. |
string | $data | This is the contents of the file to be attached. |
removeAttachment(integer $pageId, string $attachment, string $version = null)
Removes a single version or all versions of an attachment from $pageId.
integer | $pageId | The Id of the page the file is attached to. |
string | $attachment | The name of the file. |
string | $version | If specified, the version to delete. If null, then all versions of $attachment will be removed. |
getAttachmentContents(string $pageId, string $filename, string $version) : string
Retrieves the contents of an attachment.
string | $pageId | This is the name of the page to which the file is attached. |
string | $filename | This is the name of the attachment. |
string | $version | This is the version of the attachment. |
The file's contents.
_attachFile(array $file) : integer
Handles the driver-specific portion of attaching a file.
Wicked_Driver::attachFile() calls down to this method for the driver- specific portion, and then uses VFS to store the attachment.
array | $file | See Wicked_Driver::attachFile(). |
The new version of the file attached.
_retrieve(string $table, array|string $where, string $orderBy = null, integer $limit = null) : array
Retrieves a set of pages matching an SQL WHERE clause.
string | $table | Table to retrieve pages from. |
array|string | $where | Where clause for sql statement (without the 'WHERE'). If an array the 1st element is the clause with placeholder, the 2nd element the values. |
string | $orderBy | Order results by this column. |
integer | $limit | Maximum number of pages to fetch. |
A list of page hashes.