<?php
-
/**
* functions/addressbook.php - Functions and classes for the addressbook system
*
* @subpackage addressbook
*/
-/** required includes */
-// FIXME, NO display code in functions files
-include_once(SM_PATH . 'templates/util_global.php');
-
/**
* Create and initialize an addressbook object.
* @param boolean $showerr display any address book init errors. html page header
/* address book functions */
require_once(SM_PATH . 'functions/addressbook.php');
include_once(SM_PATH . 'templates/util_addressbook.php');
+include_once(SM_PATH . 'templates/util_global.php');
/* form functions */
require_once(SM_PATH . 'functions/forms.php');
/* Handle error messages */
if (!$r) {
/* Display error */
- echo html_tag( 'table',
- html_tag( 'tr',
- html_tag( 'td',
- "\n". '<strong><font color="' . $color[2] .
- '">' . _("ERROR") . ': ' . $abook->error . '</font></strong>' ."\n",
- 'center' )
- ),
- 'center', '', 'width="100%"' );
+ plain_error_message( _("ERROR") .': '. $abook->error);
/* Display the "new address" form again */
abook_create_form($form_url,'editaddr',_("Update address"),_("Update address"),$newdata);