/functions/addressbook.php

Description

functions/addressbook.php - Functions and classes for the addressbook system

Functions require SM_PATH and support of forms.php functions

Classes
Class Description
AddressBook This is the main address book class that connect all the backends and provide services to the functions above.
addressbook_backend Generic backend that all other backends extend
Functions
abook_create_form (line 179)

Display the "new address" form

Form is not closed and you must add closing form tag.

  • since: 1.5.1
void abook_create_form (string $form_url, string $name, string $title, string $button, [array $defdata = array()])
  • string $form_url: form action url
  • string $name: form name
  • string $title: form title
  • string $button: form button name
  • array $defdata: values of form fields
addressbook_cmp (line 217)

Had to move this function outside of the Addressbook Class PHP 4.0.4 Seemed to be having problems with inline functions.

Note: this can return now since we don't support 4.0.4 anymore.

void addressbook_cmp ( $a,  $b)
  • $a
  • $b
addressbook_init (line 24)

Create and initialize an addressbook object.

  • return: book object.
object address addressbook_init ([boolean $showerr = true], [boolean $onlylocal = false])
  • boolean $showerr: display any address book init errors. html page header must be created before calling addressbook_init() with $showerr enabled.
  • boolean $onlylocal: enable only local address book backends. Should be used when code does not need access to remote backends. Backends that provide read only address books with limited listing options can be tagged as remote.
alistcmp (line 250)

Sort array by the key "name"

void alistcmp ( $a,  $b)
  • $a
  • $b
getWritableBackends (line 233)

Retrieve a list of writable backends

  • since: 1.5.2
void getWritableBackends ()
get_abook_sort (line 294)

Address book sorting options

returns address book sorting order

  • return: book sorting options order
integer get_abook_sort ()
show_abook_sort_button (line 322)

This function shows the address book sort button.

  • return: html code with sorting images and urls
string show_abook_sort_button (integer $abook_sort_order, string $alt_tag, integer $Down, integer $Up)
  • integer $abook_sort_order: current sort value
  • string $alt_tag: alt tag value (string visible to text only browsers)
  • integer $Down: sort value when list is sorted ascending
  • integer $Up: sort value when list is sorted descending

Documentation generated on Sat, 07 Oct 2006 16:08:43 +0300 by phpDocumentor 1.3.0RC6