Documentation

IMP_Ajax_Application extends Horde_Core_Ajax_Application
in package

Defines the AJAX interface for IMP.

Global tasks:

  • msgload: (string) BUID of a message to load in the background (mailbox is located in 'mailbox' parameter).
  • poll: (string) The list of mailboxes to process (JSON encoded array; mailboxes are base64url encoded). If an empty array, polls all mailboxes.

Global parameters (in viewport parameter):

  • force: (integer) If set, always return viewport information if changed.
Tags
author

Michael Slusarz slusarz@horde.org

category

Horde

copyright

2010-2017 Horde LLC

license

http://www.horde.org/licenses/gpl GPL

Table of Contents

Properties

$indices  : IMP_Indices_Mailbox
The IMP_Indices_Mailbox object based on form data.
$queue  : IMP_Ajax_Queue
Queue object.

Methods

changed()  : bool
Determine if the cache information has changed.
checkUidvalidity()  : mixed
Check the UID validity of the mailbox.
composeSetup()  : array<string|int, mixed>
Setup environment for compose actions.
deleteMsgs()  : mixed
Processes delete message requests.
getAddrFields()  : array<string|int, mixed>
Return address field data from the browser form.
getTasks()  : array<string|int, mixed>
Get the list of tasks.
initCompose()  : object
Initialize the objects needed to compose.
previewUids()  : array<string|int, mixed>
Return the list of preview UIDs for the current index.
send()  : mixed
viewPortData()  : IMP_Ajax_Application_Viewport
Generate the information necessary for a ViewPort request from/to the browser.
_init()  : mixed

Properties

Methods

changed()

Determine if the cache information has changed.

public changed([bool $rw = null ]) : bool

Variables used:

  • cacheid: (string) The browser (ViewPort) cache identifier.
  • forceUpdate: (integer) If 1, forces an update.
Parameters
$rw : bool = null

Open mailbox as READ+WRITE?

Return values
bool

True if the server state differs from the browser state.

checkUidvalidity()

Check the UID validity of the mailbox.

public checkUidvalidity() : mixed

See the list of variables needed for viewPortData().

composeSetup()

Setup environment for compose actions.

public composeSetup(string $action) : array<string|int, mixed>

Variables used:

  • bcc: (string) Bcc address to use.
  • bcc_ac: (string) Bcc address to use (autocompleter JSON data).
  • cc: (string) Cc address to use.
  • cc_ac: (string) Cc address to use (autocompleter JSON data).
  • composeCache: (string) The IMP_Compose cache identifier.
  • from: (string) From address to use.
  • from_ac: (string) From address to use (autocompleter JSON data).
  • identity: (integer) The identity to use
  • redirect_to: (string) To address to use (for redirect).
  • redirect_to_ac: (string) To address to use (for redirect) (autocompleter JSON data).
  • to: (string) To address to use.
  • to_ac: (string) To address to use (autocompleter JSON data).
Parameters
$action : string

AJAX action.

Tags
throws
Horde_Exception
Return values
array<string|int, mixed>

An array with the following values:

  • (object) AJAX base return object (with action and success parameters defined).
  • (IMP_Compose) The IMP_Compose object for the message.
  • (array) The list of headers for the object.
  • (Horde_Prefs_Identity) The identity used for the composition.

deleteMsgs()

Processes delete message requests.

public deleteMsgs(IMP_Indices $indices, bool $changed[, bool $force = false ]) : mixed

See the list of variables needed for viewPortData().

Parameters
$indices : IMP_Indices

An indices object.

$changed : bool

If true, add full ViewPort information.

$force : bool = false

If true, forces addition of disappear information.

getAddrFields()

Return address field data from the browser form.

public getAddrFields() : array<string|int, mixed>
Return values
array<string|int, mixed>

Keys are header names, values are arrays with two keys:

  • addr: (array) List of addresses.
  • map: (boolean) If true, addr keys are autocomplete IDs.

getTasks()

Get the list of tasks.

public getTasks() : array<string|int, mixed>
Return values
array<string|int, mixed>

Task list.

initCompose()

Initialize the objects needed to compose.

public initCompose() : object
Return values
object

Object with the following properties:

  • ajax: IMP_Ajax_Application_Compose object
  • compose: IMP_Compose object
  • contents: IMP_Contents object

previewUids()

Return the list of preview UIDs for the current index.

public previewUids() : array<string|int, mixed>
Return values
array<string|int, mixed>

List of objects. Each object has 2 properties: mbox and uid.

viewPortData()

Generate the information necessary for a ViewPort request from/to the browser.

public viewPortData(bool $change) : IMP_Ajax_Application_Viewport

Variables used (contained in 'viewport' object):

  • applyfilter
  • cache
  • cacheid
  • delhide
  • initial
  • qsearch
  • qsearchfield
  • qsearchfilter
  • qsearchflag
  • qsearchflagnot
  • qsearchmbox
  • rangeslice
  • sortby
  • sortdir
Parameters
$change : bool

True if cache information has changed.

Return values
IMP_Ajax_Application_Viewport

Viewport data object.


        
On this page

Search results