egroupware/addressbook/inc
2001-03-19 03:46:41 +00:00
..
class.contacts_ldap.inc.php For this first major rewrite sql->ldap, all but read are done 2001-03-19 01:02:07 +00:00
class.contacts_shared.inc.php Fix a call not allowing ldap, and fix the return of stock_fieldnames 2001-03-19 03:45:46 +00:00
class.contacts_sql_test.inc.php Table upgrade and changes to implement better vcard std and more useful fields 2001-03-16 01:31:25 +00:00
class.contacts_sql.inc.php Add comment to stock field array as to use of name vs. value 2001-03-19 03:46:41 +00:00
class.contacts.inc.php Fix a call not allowing ldap, and fix the return of stock_fieldnames 2001-03-19 03:45:46 +00:00
class.pdb.inc.php Very minimal palm pdb class, can write palm docs only so far 2001-03-18 07:58:44 +00:00
functions.inc.php Move most input form tags into template, add pref note next to each phone # 2001-03-18 17:22:17 +00:00
hook_addressbook_add_def_acl.inc.php Comments to tell of status 2001-02-19 12:25:52 +00:00
hook_addressbook_add_def_pref.inc.php No functional change, just reformatting 2001-02-11 04:16:18 +00:00
hook_preferences.inc.php Add ability to manage custom fields, field edit forms still need work 2001-03-16 17:56:18 +00:00
readme.txt Update readme, add sql files for table creation manually 2001-03-17 15:48:01 +00:00

function read($start,$offset,$fields,$query="",$sort="",$order="")
	$start = start of list, e.g. 1,16,31
	$offset = numrows, e.g. 15,30,etc.
	$fields = simple array of fields to return
	$query = simple string to search for
	$sort = ASC, DESC, or ""
	$order = sort on this field, e.g. N_Given

	returns an array of name/values, e.g.:
		$fields[0]["email"] => "name@domain.com"
		...
		$fields[1]["email"] => "othername@otherdomain.com"
		...

function read_single_entry($id,$fields)
	$id = id of entry you want to return
	$fields = simple array of fields to return

	returns a single array of name/value, e.g.:
		$fields[0]["email"] => "name@domain.com"
		$fields[0]["n_given"] => "Bob"

function add($owner,$fields)
	$owner = lid of user adding this data
	$fields = assoc array of fields to write into the new record

function update($id,$owner,$fields)
	$id = id of entry you want to update
	$owner = lid of user modifying this data
	$fields = assoc array of fields to update in the record

function delete_($id)
	$id = id of entry you want to delete

    	    $this->stock_contact_fields = array(
				"fn"                     => "fn",        // 'prefix given middle family suffix'
				"n_given"                => "n_given",   // firstname
				"n_family"               => "n_family",  // lastname
				"n_middle"               => "n_middle",
				"n_prefix"               => "n_prefix",
				"n_suffix"               => "n_suffix",
				"sound"                  => "sound",
				"bday"                   => "bday",
				"note"                   => "note",
				"tz"                     => "tz",
				"geo"                    => "geo",
				"url"                    => "url",
				"pubkey"                 => "pubkey",

				"org_name"               => "org_name",  // company
				"org_unit"               => "org_unit",  // division
				"title"                  => "title",

				"adr_one_street"         => "adr_one_street",
				"adr_one_locality"       => "adr_one_locality", 
				"adr_one_region"         => "adr_one_region", 
				"adr_one_postalcode"     => "adr_one_postalcode",
				"adr_one_countryname"    => "adr_one_countryname",
				"adr_one_type"           => "adr_one_type", // address is domestic/intl/postal/parcel/work/home
				"label"                  => "label", // address label

				"adr_two_street"         => "adr_two_street",
				"adr_two_locality"       => "adr_two_locality", 
				"adr_two_region"         => "adr_two_region", 
				"adr_two_postalcode"     => "adr_two_postalcode",
				"adr_two_countryname"    => "adr_two_countryname",
				"adr_two_type"           => "adr_two_type", // address is domestic/intl/postal/parcel/work/home

				"tel_work"               => "tel_work",
				"tel_home"               => "tel_home",
				"tel_voice"              => "tel_voice",
				"tel_fax"                => "tel_fax", 
				"tel_msg"                => "tel_msg",
				"tel_cell"               => "tel_cell",
				"tel_pager"              => "tel_pager",
				"tel_bbs"                => "tel_bbs",
				"tel_modem"              => "tel_modem",
				"tel_car"                => "tel_car",
				"tel_isdn"               => "tel_isdn",
				"tel_video"              => "tel_video",
				"tel_prefer"             => "tel_prefer", // home, work, voice, etc
				"email"                  => "email",
				"email_type"             => "email_type", //'INTERNET','CompuServe',etc...
				"email_home"             => "email_home",
				"email_home_type"        => "email_home_type" //'INTERNET','CompuServe',etc...
			);

			$this->adr_types = array(
				"dom"    => lang("Domestic"),
				"intl"   => lang("International"),
				"parcel" => lang("Parcel"),
				"postal" => lang("Postal")
			);

			// Used to set preferred number field
			$this->tel_types = array(
				"work"  => "work",
				"home"  => "home",
				"voice" => "voice",
				"fax"   => "fax",
				"msg"   => "msg",
				"cell"  => "cell",
				"pager" => "pager",
				"bbs"   => "bbs",
				"modem" => "modem",
				"car"   => "car",
				"isdn"  => "isdn",
				"video" => "video"
			);

	        $this->email_types = array(
				"INTERNET"   => "INTERNET",
				"CompuServe" => "CompuServe",
				"AOL"        => "AOL",
				"Prodigy"    => "Prodigy",
				"eWorld"     => "eWorld",
				"AppleLink"  => "AppleLink",
				"AppleTalk"  => "AppleTalk",
				"PowerShare" => "PowerShare",
				"IBMMail"    => "IBMMail",
				"ATTMail"    => "ATTMail",
				"MCIMail"    => "MCIMail",
				"X.400"      => "X.400",
				"TLX"        => "TLX"
			);