From: philippe_mingo Date: Mon, 24 Jun 2002 13:05:25 +0000 (+0000) Subject: r2l by Yoav X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=commitdiff_plain;h=50ed645bfb9c43868ea808995235a3d6b9152e1b r2l by Yoav git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@2998 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/src/folders.php b/src/folders.php index 5c023af1..4a72114b 100644 --- a/src/folders.php +++ b/src/folders.php @@ -18,6 +18,7 @@ require_once('../functions/imap_utf7_decode_local.php'); require_once('../functions/imap.php'); require_once('../functions/array.php'); require_once('../functions/plugin.php'); +require_once('../functions/html.php'); displayPageHeader($color, 'None'); @@ -37,23 +38,25 @@ displayPageHeader($color, 'None'); if ((isset($success) && $success) || (isset($sent_create) && $sent_create == 'true') || (isset($trash_create) && $trash_create == 'true')) { - echo "\n" . - " \n"; - "
\n"; if ($success == "subscribe") { - echo "" . _("Subscribed successfully!") . "
"; + $td_str = "" . _("Subscribed successfully!") . "
"; } else if ($success == "unsubscribe") { - echo "" . _("Unsubscribed successfully!") . "
"; + $td_str = "" . _("Unsubscribed successfully!") . "
"; } else if ($success == "delete") { - echo "" . _("Deleted folder successfully!") . "
"; + $td_str = "" . _("Deleted folder successfully!") . "
"; } else if ($success == "create") { - echo "" . _("Created folder successfully!") . "
"; + $td_str = "" . _("Created folder successfully!") . "
"; } else if ($success == "rename") { - echo "" . _("Renamed successfully!") . "
"; + $td_str = "" . _("Renamed successfully!") . "
"; } - echo " " . _("refresh folder list") . "". - "

\n"; + echo html_tag( 'table', + html_tag( 'tr', + html_tag( 'td', $td_str . + "" . _("refresh folder list") . "" , + 'center' ) + ) , + 'center', '', 'width="100%" cellpadding="4" cellspacing="0" border="0"' ) . "
\n"; } else { echo "
"; } @@ -61,11 +64,13 @@ $imapConnection = sqimap_login ($username, $key, $imapServerAddress, $imapPort, $boxes = sqimap_mailbox_list($imapConnection); /** CREATING FOLDERS **/ -echo "\n". - "". - "\n"; -echo "\n"; - +echo html_tag( 'tr', + html_tag( 'td', ' ', 'left', $color[4] ) + ) ."\n"; /** count special folders **/ $count_special_folders = 0; @@ -136,10 +142,12 @@ for ($p = 0; $p < count($boxes) && $count_special_folders < $num_max; $p++) { /** RENAMING FOLDERS **/ -echo "". - "\n"; + "\n"; } else { echo _("No folders found") . "

"; } $boxes_sub = $boxes; -echo "\n"; +echo html_tag( 'tr', + html_tag( 'td', ' ', 'left', $color[4] ) + ) ."\n"; /** DELETING FOLDERS **/ -echo ""; -echo ""; } -echo "
". - _("Create Folder"). - "
". +echo html_tag( 'table', '', 'center', '', 'width="70%" cols="1" cellpadding="4" cellspacing="0" border="0"' ) . + html_tag( 'tr', + html_tag( 'td', '' . _("Create Folder") . '', 'center', $color[9] ) + ) . + html_tag( 'tr' ) . + html_tag( 'td', '', 'center', $color[0] ) . + "
\n". "
\n". _("as a subfolder of"). @@ -105,8 +110,9 @@ if ($show_contain_subfolders_option) { echo "\n"; echo "
 
". - _("Rename a Folder"). - "
"; +echo html_tag( 'tr', + html_tag( 'td', '' . _("Rename a Folder") . '', 'center', $color[9] ) + ) . + html_tag( 'tr' ) . + html_tag( 'td', '', 'center', $color[0] ); + if ($count_special_folders < count($boxes)) { echo "
\n" . "\n". - "
 
"; -echo _("Delete Folder"); -echo "
"; +echo html_tag( 'tr', + html_tag( 'td', '' . _("Delete Folder") . '', 'center', $color[9] ) + ) . + html_tag( 'tr' ) . + html_tag( 'td', '', 'center', $color[0] ); if ($count_special_folders < count($boxes)) { echo "
\n" @@ -205,14 +216,20 @@ if ($count_special_folders < count($boxes)) { } else { echo _("No folders found") . "

 
\n"; + +echo html_tag( 'tr', + html_tag( 'td', ' ', 'left', $color[4] ) + ) ."\n"; + /** UNSUBSCRIBE FOLDERS **/ -echo "\n"; -echo "\n"; -echo "\n"; + echo "\n"; } else { echo _("No folders were found to unsubscribe from!") . ""; } $boxes_sub = $boxes; /** SUBSCRIBE TO FOLDERS **/ -echo "
"; -echo _("Unsubscribe") . "/" . _("Subscribe"); -echo "
\n"; +echo html_tag( 'table', '', 'center', '', 'width="70%" cols="2" cellpadding="4" cellspacing="0" border="0"' ) . + html_tag( 'tr', + html_tag( 'td', '' . _("Unsubscribe") . '/' . _("Subscribe") . '', 'center', $color[9], 'colspan="2"' ) + ) . + html_tag( 'tr' ) . + html_tag( 'td', '', 'center', $color[0], 'width="50%"' ); + if ($count_special_folders < count($boxes)) { echo "\n"; echo "\n"; - echo ""; +echo html_tag( 'td', '', 'center', $color[0], 'width="50%"' ); $imap_stream = sqimap_login ($username, $key, $imapServerAddress, $imapPort, 1); $boxes_all = sqimap_mailbox_list_all ($imap_stream); @@ -272,7 +289,7 @@ if ($box && $box2) { } echo "

"; echo "\n"; - echo "

\n"; + echo "
\n"; } else { echo _("No folders were found to subscribe to!") . ""; }