From a2b193bc8c1cefe3db9f4b38ce346f0527a0ec0e Mon Sep 17 00:00:00 2001 From: jervfors Date: Sat, 4 Jun 2005 17:15:30 +0000 Subject: [PATCH] Formatting and adding FIXME to addressbook.php git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@9504 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- src/about.php | 1 + src/addrbook_search.php | 3 ++- src/addressbook.php | 19 ++++++++++--------- src/compose.php | 5 ++--- src/configtest.php | 1 + src/delete_message.php | 2 ++ src/download.php | 1 + src/folders.php | 1 + src/help.php | 1 + src/image.php | 1 + src/login.php | 29 +++++++++++++++-------------- src/mailto.php | 1 + src/options.php | 1 + src/options_highlight.php | 1 + src/options_identities.php | 1 + src/printer_friendly_bottom.php | 1 + src/printer_friendly_main.php | 1 + src/printer_friendly_top.php | 1 + src/read_body.php | 1 + src/right_main.php | 1 + src/search.php | 1 + src/signout.php | 1 + src/view_html.php | 2 ++ src/webmail.php | 3 ++- 24 files changed, 52 insertions(+), 28 deletions(-) diff --git a/src/about.php b/src/about.php index 6602325b..b048ce02 100644 --- a/src/about.php +++ b/src/about.php @@ -83,6 +83,7 @@ if ( count ($plugins) > 0 ) { } else { echo ''._("none installed")."\n\n"; } + ?>

diff --git a/src/addrbook_search.php b/src/addrbook_search.php index 05777b89..3fe8001c 100644 --- a/src/addrbook_search.php +++ b/src/addrbook_search.php @@ -308,5 +308,6 @@ if ($show == 'form' && empty($listall)) { } } + ?> - + \ No newline at end of file diff --git a/src/addressbook.php b/src/addressbook.php index 753cd2ca..a0737ee8 100644 --- a/src/addressbook.php +++ b/src/addressbook.php @@ -61,7 +61,6 @@ if($abook->localbackend == 0) { exit(); } - $defdata = array(); $formerror = ''; $abortform = false; @@ -158,6 +157,7 @@ if(sqgetGlobalVar('REQUEST_METHOD', $req_method, SQ_SERVER) && $req_method == 'P $abortform = true; list($ebackend, $enick) = explode(':', $sel[0]); $olddata = $abook->lookup($enick, $ebackend); + // FIXME: Test if $olddata really contains anything and return an error message if it doesn't /* Display the "new address" form */ abook_create_form($form_url,'editaddr',_("Update address"),_("Update address"),$olddata); @@ -175,13 +175,13 @@ if(sqgetGlobalVar('REQUEST_METHOD', $req_method, SQ_SERVER) && $req_method == 'P if (!$r) { /* Display error */ echo html_tag( 'table', - html_tag( 'tr', - html_tag( 'td', - "\n". '' . _("ERROR") . ': ' . $abook->error . '' ."\n", - 'center' ) - ), - 'center', '', 'width="100%"' ); + html_tag( 'tr', + html_tag( 'td', + "\n". '' . _("ERROR") . ': ' . $abook->error . '' ."\n", + 'center' ) + ), + 'center', '', 'width="100%"' ); /* Display the "new address" form again */ abook_create_form($form_url,'editaddr',_("Update address"),_("Update address"),$newdata); @@ -291,7 +291,7 @@ if ($showaddrlist) { } // Print backend name - echo html_tag( 'tr', + echo html_tag( 'tr', html_tag( 'td', "\n" . '' . $row['source'] . '' . "\n", 'center', $color[0] ,'colspan="5"' ) ); @@ -379,5 +379,6 @@ echo "\n"; echo "\n"; do_hook('addressbook_bottom'); echo "\n\n"; + ?> \ No newline at end of file diff --git a/src/compose.php b/src/compose.php index 20f10791..eab20f32 100644 --- a/src/compose.php +++ b/src/compose.php @@ -34,8 +34,8 @@ require_once(SM_PATH . 'functions/plugin.php'); require_once(SM_PATH . 'functions/display_messages.php'); require_once(SM_PATH . 'class/deliver/Deliver.class.php'); require_once(SM_PATH . 'functions/addressbook.php'); -require_once(SM_PATH . 'functions/identity.php'); require_once(SM_PATH . 'functions/forms.php'); +require_once(SM_PATH . 'functions/identity.php'); /* --------------------- Get globals ------------------------------------- */ /** COOKIE VARS */ @@ -1658,5 +1658,4 @@ function deliverMessage($composeMessage, $draft=false) { return $succes; } -// vim: et ts=4 -?> +?> \ No newline at end of file diff --git a/src/configtest.php b/src/configtest.php index 8e727d3e..f729624c 100644 --- a/src/configtest.php +++ b/src/configtest.php @@ -479,6 +479,7 @@ if( empty($ldap_server) ) { } } } + ?>

Congratulations, your SquirrelMail setup looks fine to me!

diff --git a/src/delete_message.php b/src/delete_message.php index 5ec635cc..2d6420b2 100644 --- a/src/delete_message.php +++ b/src/delete_message.php @@ -1,4 +1,5 @@ \ No newline at end of file diff --git a/src/download.php b/src/download.php index c5b8efb6..91de332e 100644 --- a/src/download.php +++ b/src/download.php @@ -159,4 +159,5 @@ if (isset($absolute_dl) && $absolute_dl) { mime_print_body_lines ($imapConnection, $passed_id, $ent_id, $encoding); $mailbox_cache[$aMailbox['NAME']] = $aMailbox; sqsession_register($mailbox_cache,'mailbox_cache'); + ?> \ No newline at end of file diff --git a/src/folders.php b/src/folders.php index 930148af..a040f5e7 100644 --- a/src/folders.php +++ b/src/folders.php @@ -367,6 +367,7 @@ if ($show_only_subscribed_folders) { do_hook('folders_bottom'); sqimap_logout($imapConnection); + ?> diff --git a/src/help.php b/src/help.php index 690f274d..609937d0 100644 --- a/src/help.php +++ b/src/help.php @@ -211,5 +211,6 @@ do_hook('help_bottom'); echo html_tag( 'tr', html_tag( 'td', ' ', 'left', $color[0] ) ); + ?> \ No newline at end of file diff --git a/src/image.php b/src/image.php index f08b8784..1ecf75db 100644 --- a/src/image.php +++ b/src/image.php @@ -52,6 +52,7 @@ echo ''. _("View message") . ''; $DownloadLink = '../src/download.php?passed_id=' . $passed_id . '&mailbox=' . urlencode($mailbox) . '&ent_id=' . urlencode($ent_id) . '&absolute_dl=true'; + ?> diff --git a/src/login.php b/src/login.php index 7522f69c..20393886 100644 --- a/src/login.php +++ b/src/login.php @@ -173,23 +173,24 @@ echo html_tag( 'table', addHidden('js_autodetect_results', SMPREF_JS_OFF). $rcptaddress . addHidden('just_logged_in', '1'), - 'left', '', 'width="*"' ) - ) , - 'center', $color[4], 'border="0" width="100%"' ) , - 'left', $color[4] ) - ) . - html_tag( 'tr', - html_tag( 'td', - '
'. addSubmit(_("Login")) .'
', - 'left' ) - ), - '', $color[4], 'border="0" width="350"' ) . '', - 'center' ) - ) , -'', $color[4], 'border="0" cellspacing="0" cellpadding="0" width="100%"' ); + 'left', '', 'width="*"' ) + ) , + 'center', $color[4], 'border="0" width="100%"' ) , + 'left', $color[4] ) + ) . + html_tag( 'tr', + html_tag( 'td', + '
'. addSubmit(_("Login")) .'
', + 'left' ) + ), + '', $color[4], 'border="0" width="350"' ) . '', + 'center' ) + ) , + '', $color[4], 'border="0" cellspacing="0" cellpadding="0" width="100%"' ); do_hook('login_form'); echo '' . "\n"; do_hook('login_bottom'); + ?> \ No newline at end of file diff --git a/src/mailto.php b/src/mailto.php index 75146e9a..fc1bf393 100644 --- a/src/mailto.php +++ b/src/mailto.php @@ -80,4 +80,5 @@ if($force_login == false && sqsession_is_registered('user_is_logged_in')) { session_write_close(); header('Location: ' . get_location() . '/' . $redirect); + ?> \ No newline at end of file diff --git a/src/options.php b/src/options.php index 23d4db99..a3982a7d 100644 --- a/src/options.php +++ b/src/options.php @@ -486,6 +486,7 @@ if ($optpage == SMOPT_PAGE_MAIN) { do_hook($bottom_hook_name); } } + ?> diff --git a/src/options_highlight.php b/src/options_highlight.php index d724910e..c4dfba06 100644 --- a/src/options_highlight.php +++ b/src/options_highlight.php @@ -465,5 +465,6 @@ if ($action == 'edit' || $action == 'add') { echo "\n"; } do_hook('options_highlight_bottom'); + ?> \ No newline at end of file diff --git a/src/options_identities.php b/src/options_identities.php index a8c0e653..c776c4b2 100644 --- a/src/options_identities.php +++ b/src/options_identities.php @@ -357,4 +357,5 @@ function ShowTableInfo($full_name, $email_address, $reply_to, $signature, $post) return ($return_val); } + ?> \ No newline at end of file diff --git a/src/printer_friendly_bottom.php b/src/printer_friendly_bottom.php index ffaccb00..db37b09a 100644 --- a/src/printer_friendly_bottom.php +++ b/src/printer_friendly_bottom.php @@ -186,4 +186,5 @@ function pf_clean_string ( $unclean_string, $num_leading_spaces ) { } /* end pf_clean_string() function */ /* --end pf-specific functions */ + ?> \ No newline at end of file diff --git a/src/printer_friendly_main.php b/src/printer_friendly_main.php index 4d5a703b..639671c2 100644 --- a/src/printer_friendly_main.php +++ b/src/printer_friendly_main.php @@ -40,5 +40,6 @@ if ( ! sqgetGlobalVar('mailbox',$mailbox,SQ_GET) || . '" name="bottom_frame" frameborder="0" />' . "\n"; echo "\n"; } + ?> \ No newline at end of file diff --git a/src/printer_friendly_top.php b/src/printer_friendly_top.php index 41294e82..33202e8f 100644 --- a/src/printer_friendly_top.php +++ b/src/printer_friendly_top.php @@ -39,5 +39,6 @@ echo ''. '', 'right' ); + ?> \ No newline at end of file diff --git a/src/read_body.php b/src/read_body.php index 7998c13c..f3bb0fcd 100644 --- a/src/read_body.php +++ b/src/read_body.php @@ -1009,5 +1009,6 @@ sqimap_logout($imapConnection); */ $mailbox_cache[$iAccount.'_'.$aMailbox['NAME']] = $aMailbox; sqsession_register($mailbox_cache,'mailbox_cache'); + ?> \ No newline at end of file diff --git a/src/right_main.php b/src/right_main.php index 058ff5b8..c8380e7d 100644 --- a/src/right_main.php +++ b/src/right_main.php @@ -1,4 +1,5 @@ '; sqsession_register($mailbox_cache,'mailbox_cache'); + ?> \ No newline at end of file diff --git a/src/signout.php b/src/signout.php index 77572793..eb4f9ab0 100644 --- a/src/signout.php +++ b/src/signout.php @@ -95,6 +95,7 @@ html_tag( 'table', html_tag( 'td', '
', 'center' ) , '', $color[0] ) , 'center', $color[4], 'width="50%" cellpadding="2" cellspacing="0" border="0"' ) + ?> \ No newline at end of file diff --git a/src/view_html.php b/src/view_html.php index 250bfe87..cce20eaf 100644 --- a/src/view_html.php +++ b/src/view_html.php @@ -1,4 +1,5 @@ \ No newline at end of file diff --git a/src/webmail.php b/src/webmail.php index 7417dd76..aaad5e5f 100644 --- a/src/webmail.php +++ b/src/webmail.php @@ -49,7 +49,7 @@ if (sqgetGlobalVar('startMessage', $startMessage)) { $startMessage = (int) $startMessage; } -if (!sqgetGlobalVar('mailbox',$mailbox)) { +if (!sqgetGlobalVar('mailbox', $mailbox)) { $mailbox = 'INBOX'; } @@ -180,6 +180,7 @@ if($ret != '') { $output = $ret; } echo $output; + ?> \ No newline at end of file -- 2.25.1