X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Faddressbook.php;h=f81ae4eff092c11772a5eca868f1410a8c92bebd;hb=e4c6fe416876dabfcddf636bb7dd8af11cd064a6;hp=9f55e23884cf4a8f41b760e3cd37ee7234dc36d6;hpb=355861846a51d35efe50848869d680fd3b4a5316;p=squirrelmail.git
diff --git a/src/addressbook.php b/src/addressbook.php
index 9f55e238..f81ae4ef 100644
--- a/src/addressbook.php
+++ b/src/addressbook.php
@@ -3,7 +3,7 @@
/**
* addressbook.php
*
- * Copyright (c) 1999-2001 The Squirrelmail Development Team
+ * Copyright (c) 1999-2002 The SquirrelMail Project Team
* Licensed under the GNU GPL. For full terms see the file COPYING.
*
* Manage personal address book.
@@ -11,117 +11,81 @@
* $Id$
*/
-/*****************************************************************/
-/*** THIS FILE NEEDS TO HAVE ITS FORMATTING FIXED!!! ***/
-/*** PLEASE DO SO AND REMOVE THIS COMMENT SECTION. ***/
-/*** + Base level indent should begin at left margin, as ***/
-/*** the require_once below looks. ***/
-/*** + All identation should consist of four space blocks ***/
-/*** + Tab characters are evil. ***/
-/*** + all comments should use "slash-star ... star-slash" ***/
-/*** style -- no pound characters, no slash-slash style ***/
-/*** + FLOW CONTROL STATEMENTS (if, while, etc) SHOULD ***/
-/*** ALWAYS USE { AND } CHARACTERS!!! ***/
-/*** + Please use ' instead of ", when possible. Note " ***/
-/*** should always be used in _( ) function calls. ***/
-/*** Thank you for your help making the SM code more readable. ***/
-/*****************************************************************/
-
require_once('../src/validate.php');
require_once('../functions/array.php');
require_once('../functions/display_messages.php');
require_once('../functions/addressbook.php');
-
- // Sort array by the key "name"
- function alistcmp($a,$b) {
- if($a['backend'] > $b['backend'])
- return 1;
- else if($a['backend'] < $b['backend'])
- return -1;
-
- return (strtolower($a['name']) > strtolower($b['name'])) ? 1 : -1;
+require_once('../functions/strings.php');
+require_once('../functions/html.php');
+
+/* Make an input field */
+function adressbook_inp_field($label, $field, $name, $size, $values, $add) {
+ global $color;
+ $td_str = '\n" .
- "
\n";
-
- // Display the "new address" form again
- printf("';
-
- $abortform = true;
+ if ($delfailed) {
+ $showaddrlist = true;
+ $defselected = $orig_sel;
}
- }
-
- // Should not get here...
- else {
- plain_error_message(_("Unknown error"), $color);
- $abortform = true;
- }
- } // End of edit address
-
-
- // Some times we end output before forms are printed
- if($abortform) {
- print "