From 55b00688ec61efc6d4b74eb5d7bd928ffb9a541a Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Mon, 15 Mar 2010 21:14:47 -0600 Subject: [PATCH] More coherent organization of IMP templates Better separates the three views. --- imp/acl.php | 2 +- imp/compose-dimp.php | 2 +- imp/compose-mimp.php | 2 +- imp/compose.php | 4 ++-- imp/config/hooks.php.dist | 2 +- imp/contacts.php | 2 +- imp/filterprefs.php | 2 +- imp/folders-mimp.php | 2 +- imp/folders.php | 14 ++++++------- imp/index-dimp.php | 2 +- imp/lib/Crypt/Pgp.php | 2 +- imp/lib/Crypt/Smime.php | 2 +- imp/lib/IMP.php | 2 +- imp/lib/Ui/Compose.php | 2 +- imp/lib/Views/Compose.php | 2 +- imp/mailbox-mimp.php | 4 ++-- imp/mailbox.php | 24 +++++++++++----------- imp/message-dimp.php | 2 +- imp/message-mimp.php | 4 ++-- imp/message.php | 12 +++++------ imp/pgp.php | 2 +- imp/search-basic.php | 2 +- imp/search.php | 2 +- imp/stationery.php | 2 +- imp/templates/common-header.inc | 4 ++-- imp/templates/{ => dimp}/chunks/compose.php | 0 imp/templates/{ => dimp}/chunks/message.php | 0 imp/templates/{imp => dimp/compose}/compose.html | 0 .../{index/index-dimp.inc => dimp/index.inc} | 0 imp/templates/{ => dimp}/javascript_defs_dimp.php | 0 imp/templates/{imp => dimp/portal}/portal.html | 0 imp/templates/{ => imp}/acl/acl.html | 0 imp/templates/{ => imp}/compose/compose.html | 0 imp/templates/{ => imp}/compose/redirect.html | 0 imp/templates/{ => imp}/compose/success.html | 0 imp/templates/{ => imp}/contacts/contacts.html | 0 imp/templates/{ => imp}/folders/actions.html | 0 imp/templates/{ => imp}/folders/folders.html | 0 .../{ => imp}/folders/folders_confirm.html | 0 imp/templates/{ => imp}/folders/folders_size.html | 0 imp/templates/{ => imp}/folders/head.html | 0 imp/templates/{ => imp}/folders/import.html | 0 imp/templates/{ => imp}/javascript_defs.php | 0 imp/templates/{ => imp}/mailbox/actions.html | 0 .../{ => imp}/mailbox/actions_deleted.html | 0 imp/templates/{ => imp}/mailbox/empty_mailbox.html | 0 imp/templates/{ => imp}/mailbox/header.html | 0 imp/templates/{ => imp}/mailbox/mailbox.html | 0 .../{ => imp}/mailbox/message_footers.html | 0 .../{ => imp}/mailbox/message_headers.html | 0 imp/templates/{ => imp}/mailbox/navbar.html | 0 imp/templates/{ => imp}/mailbox/searchfolder.html | 0 imp/templates/{ => imp/menu}/menu.html | 0 imp/templates/{ => imp}/message/message.html | 0 .../{ => imp}/message/navbar_actions.html | 0 .../{ => imp}/message/navbar_navigate.html | 0 imp/templates/{ => imp}/message/navbar_top.html | 0 imp/templates/{ => imp}/search/search-basic.html | 0 imp/templates/{ => imp}/search/search.html | 0 imp/templates/{ => imp}/thread/thread.html | 0 .../compose/compose.html} | 0 .../folders/folders.html} | 0 .../mailbox/mailbox.html} | 0 .../search-mimp.html => mimp/mailbox/search.html} | 0 .../message/message.html} | 0 .../part-mimp.html => mimp/message/part.html} | 0 .../prefs.html => prefs/filters/filters.html} | 0 imp/templates/{ => prefs}/pgp/import_key.html | 0 imp/templates/{ => prefs}/pgp/pgp.html | 0 imp/templates/{ => prefs}/smime/import_key.html | 0 imp/templates/{ => prefs}/smime/smime.html | 0 .../{ => prefs}/stationery/stationery.html | 0 imp/thread.php | 2 +- 73 files changed, 52 insertions(+), 52 deletions(-) rename imp/templates/{ => dimp}/chunks/compose.php (100%) rename imp/templates/{ => dimp}/chunks/message.php (100%) rename imp/templates/{imp => dimp/compose}/compose.html (100%) rename imp/templates/{index/index-dimp.inc => dimp/index.inc} (100%) rename imp/templates/{ => dimp}/javascript_defs_dimp.php (100%) rename imp/templates/{imp => dimp/portal}/portal.html (100%) rename imp/templates/{ => imp}/acl/acl.html (100%) rename imp/templates/{ => imp}/compose/compose.html (100%) rename imp/templates/{ => imp}/compose/redirect.html (100%) rename imp/templates/{ => imp}/compose/success.html (100%) rename imp/templates/{ => imp}/contacts/contacts.html (100%) rename imp/templates/{ => imp}/folders/actions.html (100%) rename imp/templates/{ => imp}/folders/folders.html (100%) rename imp/templates/{ => imp}/folders/folders_confirm.html (100%) rename imp/templates/{ => imp}/folders/folders_size.html (100%) rename imp/templates/{ => imp}/folders/head.html (100%) rename imp/templates/{ => imp}/folders/import.html (100%) rename imp/templates/{ => imp}/javascript_defs.php (100%) rename imp/templates/{ => imp}/mailbox/actions.html (100%) rename imp/templates/{ => imp}/mailbox/actions_deleted.html (100%) rename imp/templates/{ => imp}/mailbox/empty_mailbox.html (100%) rename imp/templates/{ => imp}/mailbox/header.html (100%) rename imp/templates/{ => imp}/mailbox/mailbox.html (100%) rename imp/templates/{ => imp}/mailbox/message_footers.html (100%) rename imp/templates/{ => imp}/mailbox/message_headers.html (100%) rename imp/templates/{ => imp}/mailbox/navbar.html (100%) rename imp/templates/{ => imp}/mailbox/searchfolder.html (100%) rename imp/templates/{ => imp/menu}/menu.html (100%) rename imp/templates/{ => imp}/message/message.html (100%) rename imp/templates/{ => imp}/message/navbar_actions.html (100%) rename imp/templates/{ => imp}/message/navbar_navigate.html (100%) rename imp/templates/{ => imp}/message/navbar_top.html (100%) rename imp/templates/{ => imp}/search/search-basic.html (100%) rename imp/templates/{ => imp}/search/search.html (100%) rename imp/templates/{ => imp}/thread/thread.html (100%) rename imp/templates/{compose/compose-mimp.html => mimp/compose/compose.html} (100%) rename imp/templates/{folders/folders-mimp.html => mimp/folders/folders.html} (100%) rename imp/templates/{mailbox/mailbox-mimp.html => mimp/mailbox/mailbox.html} (100%) rename imp/templates/{mailbox/search-mimp.html => mimp/mailbox/search.html} (100%) rename imp/templates/{message/message-mimp.html => mimp/message/message.html} (100%) rename imp/templates/{message/part-mimp.html => mimp/message/part.html} (100%) rename imp/templates/{filters/prefs.html => prefs/filters/filters.html} (100%) rename imp/templates/{ => prefs}/pgp/import_key.html (100%) rename imp/templates/{ => prefs}/pgp/pgp.html (100%) rename imp/templates/{ => prefs}/smime/import_key.html (100%) rename imp/templates/{ => prefs}/smime/smime.html (100%) rename imp/templates/{ => prefs}/stationery/stationery.html (100%) diff --git a/imp/acl.php b/imp/acl.php index b4e03adc2..5588927d4 100644 --- a/imp/acl.php +++ b/imp/acl.php @@ -186,7 +186,7 @@ $t->set('width', round(100 / (count($rightsval) + 1)) . '%'); $t->set('prefsurl', $prefs_url); Horde::addScriptFile('acl.js', 'imp'); -echo $t->fetch(IMP_TEMPLATES . '/acl/acl.html'); +echo $t->fetch(IMP_TEMPLATES . '/imp/acl/acl.html'); if (!$chunk) { require $registry->get('templates', 'horde') . '/common-footer.inc'; } diff --git a/imp/compose-dimp.php b/imp/compose-dimp.php index ce11c81d8..33044736b 100644 --- a/imp/compose-dimp.php +++ b/imp/compose-dimp.php @@ -205,7 +205,7 @@ $scripts = array( IMP::status(); IMP_Dimp::header(_("Message Composition"), $scripts); -echo $t->fetch(IMP_TEMPLATES . '/imp/compose.html'); +echo $t->fetch(IMP_TEMPLATES . '/dimp/compose/compose.html'); Horde::includeScriptFiles(); Horde::outputInlineScript(); echo $compose_result['jsappend']; diff --git a/imp/compose-mimp.php b/imp/compose-mimp.php index 73bb8db02..e4ed60310 100644 --- a/imp/compose-mimp.php +++ b/imp/compose-mimp.php @@ -348,4 +348,4 @@ $t->set('title', $title); require IMP_TEMPLATES . '/common-header.inc'; IMP::status(); -echo $t->fetch(IMP_TEMPLATES . '/compose/compose-mimp.html'); +echo $t->fetch(IMP_TEMPLATES . '/mimp/compose/compose.html'); diff --git a/imp/compose.php b/imp/compose.php index 483674a89..5e89cdfe8 100644 --- a/imp/compose.php +++ b/imp/compose.php @@ -731,7 +731,7 @@ if ($redirect) { $t->set('input_value', htmlspecialchars($header['to'])); $t->set('help', Horde_Help::link('imp', 'compose-to')); - $template_output = $t->fetch(IMP_TEMPLATES . '/compose/redirect.html'); + $template_output = $t->fetch(IMP_TEMPLATES . '/imp/compose/redirect.html'); } else { /* Prepare the compose template. */ $tabindex = 0; @@ -1037,7 +1037,7 @@ if ($redirect) { } $t->set('status', Horde_Util::bufferOutput(array('IMP', 'status'))); - $template_output = $t->fetch(IMP_TEMPLATES . '/compose/compose.html'); + $template_output = $t->fetch(IMP_TEMPLATES . '/imp/compose/compose.html'); } if ($rtemode && !$redirect) { diff --git a/imp/config/hooks.php.dist b/imp/config/hooks.php.dist index b5de25f38..1bd35a58f 100644 --- a/imp/config/hooks.php.dist +++ b/imp/config/hooks.php.dist @@ -674,7 +674,7 @@ class IMP_Hooks /** * DIMP: Allow additional information to be added to the array that is * passed to the message text display template: - * imp/templates/chunks/message.php. + * imp/templates/dimp/chunks/message.php. * * @param array $msg The current entry array (see the showMessage() * function in lib/Views/ShowMessage.php for the diff --git a/imp/contacts.php b/imp/contacts.php index f391af752..30b91048f 100644 --- a/imp/contacts.php +++ b/imp/contacts.php @@ -105,5 +105,5 @@ Horde::addInlineScript(array( 'ImpContacts.formname = \'' . $formname . '\'', 'ImpContacts.to_only = ' . intval($to_only), )); -echo $template->fetch(IMP_TEMPLATES . '/contacts/contacts.html'); +echo $template->fetch(IMP_TEMPLATES . '/imp/contacts/contacts.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; diff --git a/imp/filterprefs.php b/imp/filterprefs.php index 25e3432af..cbda88b78 100644 --- a/imp/filterprefs.php +++ b/imp/filterprefs.php @@ -120,7 +120,7 @@ if (!$blacklist_link && !$whitelist_link && !$filters_link) { } } -echo $t->fetch(IMP_TEMPLATES . '/filters/prefs.html'); +echo $t->fetch(IMP_TEMPLATES . '/prefs/filters/filters.html'); if (!$chunk) { require $registry->get('templates', 'horde') . '/common-footer.inc'; } diff --git a/imp/folders-mimp.php b/imp/folders-mimp.php index 92a85b851..ff960c005 100644 --- a/imp/folders-mimp.php +++ b/imp/folders-mimp.php @@ -74,4 +74,4 @@ $t->set('title', $title); require_once IMP_TEMPLATES . '/common-header.inc'; IMP::status(); -echo $t->fetch(IMP_TEMPLATES . '/folders/folders-mimp.html'); +echo $t->fetch(IMP_TEMPLATES . '/mimp/folders/folders.html'); diff --git a/imp/folders.php b/imp/folders.php index 50893b5d8..c31261409 100644 --- a/imp/folders.php +++ b/imp/folders.php @@ -281,7 +281,7 @@ case 'folders_empty_mailbox_confirm': $template->set('folders', $loop); $template->set('folders_url', $folders_url); $template->set('folders_token', Horde::getRequestToken('imp.folders')); - echo $template->fetch(IMP_TEMPLATES . '/folders/folders_confirm.html'); + echo $template->fetch(IMP_TEMPLATES . '/imp/folders/folders_confirm.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; exit; @@ -321,7 +321,7 @@ case 'mbox_size': $template->set('folders', $loop); $template->set('folders_url', $folders_url); $template->set('folders_sum', sprintf(_("%.2fMB"), $sum / (1024 * 1024))); - echo $template->fetch(IMP_TEMPLATES . '/folders/folders_size.html'); + echo $template->fetch(IMP_TEMPLATES . '/imp/folders/folders_size.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; exit; @@ -350,7 +350,7 @@ if ($_SESSION['imp']['file_upload'] && ($actionID == 'import_mbox')) { $i_template->set('import_folder', $folder_list[0]); $i_template->set('folder_name', htmlspecialchars(Horde_String::convertCharset($folder_list[0], 'UTF7-IMAP'), ENT_COMPAT, $charset)); $i_template->set('folders_token', $folders_token); - echo $i_template->fetch(IMP_TEMPLATES . '/folders/import.html'); + echo $i_template->fetch(IMP_TEMPLATES . '/imp/folders/import.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; exit; } @@ -475,12 +475,12 @@ IMP::menu(); IMP::status(); IMP::quota(); -echo $head_template->fetch(IMP_TEMPLATES . '/folders/head.html'); -echo $a_template->fetch(IMP_TEMPLATES . '/folders/actions.html'); -echo $template->fetch(IMP_TEMPLATES . '/folders/folders.html'); +echo $head_template->fetch(IMP_TEMPLATES . '/imp/folders/head.html'); +echo $a_template->fetch(IMP_TEMPLATES . '/imp/folders/actions.html'); +echo $template->fetch(IMP_TEMPLATES . '/imp/folders/folders.html'); if (count($rows) > 10) { $a_template->set('id', 1); - echo $a_template->fetch(IMP_TEMPLATES . '/folders/actions.html'); + echo $a_template->fetch(IMP_TEMPLATES . '/imp/folders/actions.html'); } /* No need for extra template - close out the tags here. */ diff --git a/imp/index-dimp.php b/imp/index-dimp.php index 3fe736455..4acf8dbc1 100644 --- a/imp/index-dimp.php +++ b/imp/index-dimp.php @@ -62,7 +62,7 @@ foreach (IMP_Dimp::menuList() as $app) { } echo "\n"; -require IMP_TEMPLATES . '/index/index-dimp.inc'; +require IMP_TEMPLATES . '/dimp/index.inc'; Horde::includeScriptFiles(); Horde::outputInlineScript(); echo "\n"; diff --git a/imp/lib/Crypt/Pgp.php b/imp/lib/Crypt/Pgp.php index b8f940f84..7d4de5e9f 100644 --- a/imp/lib/Crypt/Pgp.php +++ b/imp/lib/Crypt/Pgp.php @@ -648,7 +648,7 @@ class IMP_Crypt_Pgp extends Horde_Crypt_Pgp $t->set('import_public_key', $target == 'process_import_public_key'); $t->set('import_personal_public_key', $target == 'process_import_personal_public_key'); $t->set('import_personal_private_key', $target == 'process_import_personal_private_key'); - echo $t->fetch(IMP_TEMPLATES . '/pgp/import_key.html'); + echo $t->fetch(IMP_TEMPLATES . '/prefs/pgp/import_key.html'); } /** diff --git a/imp/lib/Crypt/Smime.php b/imp/lib/Crypt/Smime.php index b094c3cc9..fd9756605 100644 --- a/imp/lib/Crypt/Smime.php +++ b/imp/lib/Crypt/Smime.php @@ -483,7 +483,7 @@ class IMP_Crypt_Smime extends Horde_Crypt_Smime $t->set('forminput', Horde_Util::formInput()); $t->set('import_public_key', $target == 'process_import_public_key'); $t->set('import_personal_certs', $target == 'process_import_personal_certs'); - echo $t->fetch(IMP_TEMPLATES . '/smime/import_key.html'); + echo $t->fetch(IMP_TEMPLATES . '/prefs/smime/import_key.html'); } /** diff --git a/imp/lib/IMP.php b/imp/lib/IMP.php index ec4510b8b..ea6b13a56 100644 --- a/imp/lib/IMP.php +++ b/imp/lib/IMP.php @@ -545,7 +545,7 @@ class IMP static public function menu() { self::prepareMenu(); - echo self::$_menuTemplate->fetch(IMP_TEMPLATES . '/menu.html'); + echo self::$_menuTemplate->fetch(IMP_TEMPLATES . '/imp/menu/menu.html'); } /** diff --git a/imp/lib/Ui/Compose.php b/imp/lib/Ui/Compose.php index 87f009b4b..378764503 100644 --- a/imp/lib/Ui/Compose.php +++ b/imp/lib/Ui/Compose.php @@ -288,7 +288,7 @@ class IMP_Ui_Compose require IMP_TEMPLATES . '/common-header.inc'; $success_template = $GLOBALS['injector']->createInstance('Horde_Template'); $success_template->set('menu', $menu->render()); - echo $success_template->fetch(IMP_TEMPLATES . '/compose/success.html'); + echo $success_template->fetch(IMP_TEMPLATES . '/imp/compose/success.html'); IMP::status(); require $GLOBALS['registry']->get('templates', 'horde') . '/common-footer.inc'; } diff --git a/imp/lib/Views/Compose.php b/imp/lib/Views/Compose.php index f78e1cc8c..16c6c1f54 100644 --- a/imp/lib/Views/Compose.php +++ b/imp/lib/Views/Compose.php @@ -97,7 +97,7 @@ class IMP_Views_Compose // Buffer output so that we can return a string from this function ob_start(); - require IMP_TEMPLATES . '/chunks/compose.php'; + require IMP_TEMPLATES . '/dimp/chunks/compose.php'; $result['html'] .= ob_get_contents(); ob_clean(); diff --git a/imp/mailbox-mimp.php b/imp/mailbox-mimp.php index 95f863494..9c6e106b8 100644 --- a/imp/mailbox-mimp.php +++ b/imp/mailbox-mimp.php @@ -99,7 +99,7 @@ case 's': require_once IMP_TEMPLATES . '/common-header.inc'; IMP::status(); - echo $t->fetch(IMP_TEMPLATES . '/mailbox/search-mimp.html'); + echo $t->fetch(IMP_TEMPLATES . '/mimp/mailbox/search.html'); exit; // 'rs' = run search @@ -272,4 +272,4 @@ try { require_once IMP_TEMPLATES . '/common-header.inc'; IMP::status(); -echo $t->fetch(IMP_TEMPLATES . '/mailbox/mailbox-mimp.html'); +echo $t->fetch(IMP_TEMPLATES . '/mimp/mailbox/mailbox.html'); diff --git a/imp/mailbox.php b/imp/mailbox.php index df0cd0c2f..2463f6724 100644 --- a/imp/mailbox.php +++ b/imp/mailbox.php @@ -34,7 +34,7 @@ function _outputSummaries($msgs) } $template->set('messages', $msgs, true); - echo $template->fetch(IMP_TEMPLATES . '/mailbox/mailbox.html'); + echo $template->fetch(IMP_TEMPLATES . '/imp/mailbox/mailbox.html'); } @@ -438,7 +438,7 @@ if ($pageOb['pagecount'] > 1) { $hdr_template->set('page', sprintf(_("Page %d of %d"), $pageOb['page'], $pageOb['pagecount'])); } -echo $hdr_template->fetch(IMP_TEMPLATES . '/mailbox/header.html'); +echo $hdr_template->fetch(IMP_TEMPLATES . '/imp/mailbox/header.html'); /* If no messages, exit immediately. */ if (empty($pageOb['end'])) { @@ -450,13 +450,13 @@ if (empty($pageOb['end'])) { if (!$readonly) { $del_template->set('purge', Horde::widget($refresh_url->copy()->add(array('actionID' => 'expunge_mailbox', 'mailbox_token' => $mailbox_token)), _("Purge Deleted"), 'widget purgeAction', '', '', _("Pur_ge Deleted"))); } - echo $del_template->fetch(IMP_TEMPLATES . '/mailbox/actions_deleted.html'); + echo $del_template->fetch(IMP_TEMPLATES . '/imp/mailbox/actions_deleted.html'); } $empty_template = $injector->createInstance('Horde_Template'); $empty_template->setOption('gettext', true); $empty_template->set('search_mbox', $search_mbox); - echo $empty_template->fetch(IMP_TEMPLATES . '/mailbox/empty_mailbox.html'); + echo $empty_template->fetch(IMP_TEMPLATES . '/imp/mailbox/empty_mailbox.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; exit; } @@ -498,7 +498,7 @@ if ($pageOb['msgcount']) { $n_template->set('page_size', Horde_String::length($pageOb['pagecount'])); } - echo $n_template->fetch(IMP_TEMPLATES . '/mailbox/navbar.html'); + echo $n_template->fetch(IMP_TEMPLATES . '/imp/mailbox/navbar.html'); /* Prepare the actions template. */ $a_template = $injector->createInstance('Horde_Template'); @@ -547,7 +547,7 @@ if ($pageOb['msgcount']) { $a_template->set('view_messages', Horde::widget('#', _("View Messages"), 'widget viewAction', '', '', _("View Messages"))); - echo $a_template->fetch(IMP_TEMPLATES . '/mailbox/actions.html'); + echo $a_template->fetch(IMP_TEMPLATES . '/imp/mailbox/actions.html'); } /* Define some variables now so we don't have to keep redefining in the @@ -669,7 +669,7 @@ if ($pageOb['msgcount']) { if (!$search_mbox) { $mh_template->set('mh_count', $mh_count++); - echo $mh_template->fetch(IMP_TEMPLATES . '/mailbox/message_headers.html'); + echo $mh_template->fetch(IMP_TEMPLATES . '/imp/mailbox/message_headers.html'); } } @@ -694,13 +694,13 @@ while (list(,$ob) = each($mbox_info['overview'])) { } $search_template->set('lastMbox', $lastMbox); $search_template->set('folder_link', $folder_link); - echo $search_template->fetch(IMP_TEMPLATES . '/mailbox/searchfolder.html'); + echo $search_template->fetch(IMP_TEMPLATES . '/imp/mailbox/searchfolder.html'); if ($mh_count) { $mh_template->set('form_tag', false); } $mh_template->set('mh_count', $mh_count++); - echo $mh_template->fetch(IMP_TEMPLATES . '/mailbox/message_headers.html'); + echo $mh_template->fetch(IMP_TEMPLATES . '/imp/mailbox/message_headers.html'); } } @@ -827,15 +827,15 @@ _outputSummaries($msgs); /* Prepare the message footers template. */ $mf_template = $injector->createInstance('Horde_Template'); $mf_template->set('page', $pageOb['page']); -echo $mf_template->fetch(IMP_TEMPLATES . '/mailbox/message_footers.html'); +echo $mf_template->fetch(IMP_TEMPLATES . '/imp/mailbox/message_footers.html'); /* If there are 20 messages or less, don't show the actions/navbar again. */ if (($pageOb['end'] - $pageOb['begin']) >= 20) { $a_template->set('isbottom', true); - echo $a_template->fetch(IMP_TEMPLATES . '/mailbox/actions.html'); + echo $a_template->fetch(IMP_TEMPLATES . '/imp/mailbox/actions.html'); $n_template->set('id', 2); $n_template->set('isbottom', true); - echo $n_template->fetch(IMP_TEMPLATES . '/mailbox/navbar.html'); + echo $n_template->fetch(IMP_TEMPLATES . '/imp/mailbox/navbar.html'); } Horde::addInlineScript(array( diff --git a/imp/message-dimp.php b/imp/message-dimp.php index 489884d44..b36d0c06d 100644 --- a/imp/message-dimp.php +++ b/imp/message-dimp.php @@ -89,7 +89,7 @@ Horde::addInlineScript(array_filter($js_onload), 'load'); IMP::status(); IMP_Dimp::header($show_msg_result['title'], $scripts); echo "\n"; -require IMP_TEMPLATES . '/chunks/message.php'; +require IMP_TEMPLATES . '/dimp/chunks/message.php'; Horde::includeScriptFiles(); Horde::outputInlineScript(); if (!$disable_compose) { diff --git a/imp/message-mimp.php b/imp/message-mimp.php index 3e9b6154a..4082d0910 100644 --- a/imp/message-mimp.php +++ b/imp/message-mimp.php @@ -157,7 +157,7 @@ if (($vars->a == 'pa') && $t->set('self_link', $self_link); require IMP_TEMPLATES . '/common-header.inc'; - echo $t->fetch(IMP_TEMPLATES . '/message/part-mimp.html'); + echo $t->fetch(IMP_TEMPLATES . '/mimp/message/part.html'); exit; } @@ -354,4 +354,4 @@ $t->set('title', ($status ? $status . ' | ' : '') . $display_headers['subject'] require IMP_TEMPLATES . '/common-header.inc'; IMP::status(); -echo $t->fetch(IMP_TEMPLATES . '/message/message-mimp.html'); +echo $t->fetch(IMP_TEMPLATES . '/mimp/message/message.html'); diff --git a/imp/message.php b/imp/message.php index e7203bc85..f31d05441 100644 --- a/imp/message.php +++ b/imp/message.php @@ -665,16 +665,16 @@ IMP::menu(); IMP::status(); IMP::quota(); -echo $t_template->fetch(IMP_TEMPLATES . '/message/navbar_top.html'); -echo $n_template->fetch(IMP_TEMPLATES . '/message/navbar_navigate.html'); -echo $a_template->fetch(IMP_TEMPLATES . '/message/navbar_actions.html'); -echo $m_template->fetch(IMP_TEMPLATES . '/message/message.html'); +echo $t_template->fetch(IMP_TEMPLATES . '/imp/message/navbar_top.html'); +echo $n_template->fetch(IMP_TEMPLATES . '/imp/message/navbar_navigate.html'); +echo $a_template->fetch(IMP_TEMPLATES . '/imp/message/navbar_actions.html'); +echo $m_template->fetch(IMP_TEMPLATES . '/imp/message/message.html'); $a_template->set('isbottom', true); -echo $a_template->fetch(IMP_TEMPLATES . '/message/navbar_actions.html'); +echo $a_template->fetch(IMP_TEMPLATES . '/imp/message/navbar_actions.html'); $n_template->set('id', 2); $n_template->set('isbottom', true); -echo $n_template->fetch(IMP_TEMPLATES . '/message/navbar_navigate.html'); +echo $n_template->fetch(IMP_TEMPLATES . '/imp/message/navbar_navigate.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; diff --git a/imp/pgp.php b/imp/pgp.php index 751cc8aa2..28f576c9c 100644 --- a/imp/pgp.php +++ b/imp/pgp.php @@ -326,7 +326,7 @@ if ($prefs->getValue('use_pgp')) { } $t->set('prefsurl', Horde::getServiceLink('options', 'imp')); -echo $t->fetch(IMP_TEMPLATES . '/pgp/pgp.html'); +echo $t->fetch(IMP_TEMPLATES . '/prefs/pgp/pgp.html'); if (!$chunk) { require $registry->get('templates', 'horde') . '/common-footer.inc'; } diff --git a/imp/search-basic.php b/imp/search-basic.php index b24875e7a..87ce1cdf1 100644 --- a/imp/search-basic.php +++ b/imp/search-basic.php @@ -74,5 +74,5 @@ if ($browser->hasFeature('javascript')) { $t->set('advsearch', Horde::link(Horde::applicationUrl('search.php')->add(array('search_mailbox' => $search_mailbox)))); } -echo $t->fetch(IMP_TEMPLATES . '/search/search-basic.html'); +echo $t->fetch(IMP_TEMPLATES . '/imp/search/search-basic.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; diff --git a/imp/search.php b/imp/search.php index 8c4ef4dc0..97d72b4a8 100644 --- a/imp/search.php +++ b/imp/search.php @@ -221,5 +221,5 @@ if (!$dimp_view) { } IMP::status(); -echo $t->fetch(IMP_TEMPLATES . '/search/search.html'); +echo $t->fetch(IMP_TEMPLATES . '/imp/search/search.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; diff --git a/imp/stationery.php b/imp/stationery.php index 81f9af3f0..2a818c364 100644 --- a/imp/stationery.php +++ b/imp/stationery.php @@ -131,7 +131,7 @@ $t->set('content', $stationery['c']); $t->set('button_href', $compose_url->copy()->add('group', 'compose')); $t->set('button_val', htmlspecialchars(_("Return to Message Composition"), ENT_COMPAT, Horde_Nls::getCharset())); -echo $t->fetch(IMP_TEMPLATES . '/stationery/stationery.html'); +echo $t->fetch(IMP_TEMPLATES . '/prefs/stationery/stationery.html'); if (!$chunk) { require $registry->get('templates', 'horde') . '/common-footer.inc'; } diff --git a/imp/templates/common-header.inc b/imp/templates/common-header.inc index 23bc4f8fe..d534b9b6b 100644 --- a/imp/templates/common-header.inc +++ b/imp/templates/common-header.inc @@ -6,7 +6,7 @@ $imp_view = IMP::getViewMode(); * other scripts already added. */ switch ($imp_view) { case 'dimp': - include IMP_TEMPLATES . '/javascript_defs_dimp.php'; + include IMP_TEMPLATES . '/dimp/javascript_defs_dimp.php'; break; case 'mimp': @@ -14,7 +14,7 @@ case 'mimp': break; default: - include IMP_TEMPLATES . '/javascript_defs.php'; + include IMP_TEMPLATES . '/imp/javascript_defs.php'; break; } diff --git a/imp/templates/chunks/compose.php b/imp/templates/dimp/chunks/compose.php similarity index 100% rename from imp/templates/chunks/compose.php rename to imp/templates/dimp/chunks/compose.php diff --git a/imp/templates/chunks/message.php b/imp/templates/dimp/chunks/message.php similarity index 100% rename from imp/templates/chunks/message.php rename to imp/templates/dimp/chunks/message.php diff --git a/imp/templates/imp/compose.html b/imp/templates/dimp/compose/compose.html similarity index 100% rename from imp/templates/imp/compose.html rename to imp/templates/dimp/compose/compose.html diff --git a/imp/templates/index/index-dimp.inc b/imp/templates/dimp/index.inc similarity index 100% rename from imp/templates/index/index-dimp.inc rename to imp/templates/dimp/index.inc diff --git a/imp/templates/javascript_defs_dimp.php b/imp/templates/dimp/javascript_defs_dimp.php similarity index 100% rename from imp/templates/javascript_defs_dimp.php rename to imp/templates/dimp/javascript_defs_dimp.php diff --git a/imp/templates/imp/portal.html b/imp/templates/dimp/portal/portal.html similarity index 100% rename from imp/templates/imp/portal.html rename to imp/templates/dimp/portal/portal.html diff --git a/imp/templates/acl/acl.html b/imp/templates/imp/acl/acl.html similarity index 100% rename from imp/templates/acl/acl.html rename to imp/templates/imp/acl/acl.html diff --git a/imp/templates/compose/compose.html b/imp/templates/imp/compose/compose.html similarity index 100% rename from imp/templates/compose/compose.html rename to imp/templates/imp/compose/compose.html diff --git a/imp/templates/compose/redirect.html b/imp/templates/imp/compose/redirect.html similarity index 100% rename from imp/templates/compose/redirect.html rename to imp/templates/imp/compose/redirect.html diff --git a/imp/templates/compose/success.html b/imp/templates/imp/compose/success.html similarity index 100% rename from imp/templates/compose/success.html rename to imp/templates/imp/compose/success.html diff --git a/imp/templates/contacts/contacts.html b/imp/templates/imp/contacts/contacts.html similarity index 100% rename from imp/templates/contacts/contacts.html rename to imp/templates/imp/contacts/contacts.html diff --git a/imp/templates/folders/actions.html b/imp/templates/imp/folders/actions.html similarity index 100% rename from imp/templates/folders/actions.html rename to imp/templates/imp/folders/actions.html diff --git a/imp/templates/folders/folders.html b/imp/templates/imp/folders/folders.html similarity index 100% rename from imp/templates/folders/folders.html rename to imp/templates/imp/folders/folders.html diff --git a/imp/templates/folders/folders_confirm.html b/imp/templates/imp/folders/folders_confirm.html similarity index 100% rename from imp/templates/folders/folders_confirm.html rename to imp/templates/imp/folders/folders_confirm.html diff --git a/imp/templates/folders/folders_size.html b/imp/templates/imp/folders/folders_size.html similarity index 100% rename from imp/templates/folders/folders_size.html rename to imp/templates/imp/folders/folders_size.html diff --git a/imp/templates/folders/head.html b/imp/templates/imp/folders/head.html similarity index 100% rename from imp/templates/folders/head.html rename to imp/templates/imp/folders/head.html diff --git a/imp/templates/folders/import.html b/imp/templates/imp/folders/import.html similarity index 100% rename from imp/templates/folders/import.html rename to imp/templates/imp/folders/import.html diff --git a/imp/templates/javascript_defs.php b/imp/templates/imp/javascript_defs.php similarity index 100% rename from imp/templates/javascript_defs.php rename to imp/templates/imp/javascript_defs.php diff --git a/imp/templates/mailbox/actions.html b/imp/templates/imp/mailbox/actions.html similarity index 100% rename from imp/templates/mailbox/actions.html rename to imp/templates/imp/mailbox/actions.html diff --git a/imp/templates/mailbox/actions_deleted.html b/imp/templates/imp/mailbox/actions_deleted.html similarity index 100% rename from imp/templates/mailbox/actions_deleted.html rename to imp/templates/imp/mailbox/actions_deleted.html diff --git a/imp/templates/mailbox/empty_mailbox.html b/imp/templates/imp/mailbox/empty_mailbox.html similarity index 100% rename from imp/templates/mailbox/empty_mailbox.html rename to imp/templates/imp/mailbox/empty_mailbox.html diff --git a/imp/templates/mailbox/header.html b/imp/templates/imp/mailbox/header.html similarity index 100% rename from imp/templates/mailbox/header.html rename to imp/templates/imp/mailbox/header.html diff --git a/imp/templates/mailbox/mailbox.html b/imp/templates/imp/mailbox/mailbox.html similarity index 100% rename from imp/templates/mailbox/mailbox.html rename to imp/templates/imp/mailbox/mailbox.html diff --git a/imp/templates/mailbox/message_footers.html b/imp/templates/imp/mailbox/message_footers.html similarity index 100% rename from imp/templates/mailbox/message_footers.html rename to imp/templates/imp/mailbox/message_footers.html diff --git a/imp/templates/mailbox/message_headers.html b/imp/templates/imp/mailbox/message_headers.html similarity index 100% rename from imp/templates/mailbox/message_headers.html rename to imp/templates/imp/mailbox/message_headers.html diff --git a/imp/templates/mailbox/navbar.html b/imp/templates/imp/mailbox/navbar.html similarity index 100% rename from imp/templates/mailbox/navbar.html rename to imp/templates/imp/mailbox/navbar.html diff --git a/imp/templates/mailbox/searchfolder.html b/imp/templates/imp/mailbox/searchfolder.html similarity index 100% rename from imp/templates/mailbox/searchfolder.html rename to imp/templates/imp/mailbox/searchfolder.html diff --git a/imp/templates/menu.html b/imp/templates/imp/menu/menu.html similarity index 100% rename from imp/templates/menu.html rename to imp/templates/imp/menu/menu.html diff --git a/imp/templates/message/message.html b/imp/templates/imp/message/message.html similarity index 100% rename from imp/templates/message/message.html rename to imp/templates/imp/message/message.html diff --git a/imp/templates/message/navbar_actions.html b/imp/templates/imp/message/navbar_actions.html similarity index 100% rename from imp/templates/message/navbar_actions.html rename to imp/templates/imp/message/navbar_actions.html diff --git a/imp/templates/message/navbar_navigate.html b/imp/templates/imp/message/navbar_navigate.html similarity index 100% rename from imp/templates/message/navbar_navigate.html rename to imp/templates/imp/message/navbar_navigate.html diff --git a/imp/templates/message/navbar_top.html b/imp/templates/imp/message/navbar_top.html similarity index 100% rename from imp/templates/message/navbar_top.html rename to imp/templates/imp/message/navbar_top.html diff --git a/imp/templates/search/search-basic.html b/imp/templates/imp/search/search-basic.html similarity index 100% rename from imp/templates/search/search-basic.html rename to imp/templates/imp/search/search-basic.html diff --git a/imp/templates/search/search.html b/imp/templates/imp/search/search.html similarity index 100% rename from imp/templates/search/search.html rename to imp/templates/imp/search/search.html diff --git a/imp/templates/thread/thread.html b/imp/templates/imp/thread/thread.html similarity index 100% rename from imp/templates/thread/thread.html rename to imp/templates/imp/thread/thread.html diff --git a/imp/templates/compose/compose-mimp.html b/imp/templates/mimp/compose/compose.html similarity index 100% rename from imp/templates/compose/compose-mimp.html rename to imp/templates/mimp/compose/compose.html diff --git a/imp/templates/folders/folders-mimp.html b/imp/templates/mimp/folders/folders.html similarity index 100% rename from imp/templates/folders/folders-mimp.html rename to imp/templates/mimp/folders/folders.html diff --git a/imp/templates/mailbox/mailbox-mimp.html b/imp/templates/mimp/mailbox/mailbox.html similarity index 100% rename from imp/templates/mailbox/mailbox-mimp.html rename to imp/templates/mimp/mailbox/mailbox.html diff --git a/imp/templates/mailbox/search-mimp.html b/imp/templates/mimp/mailbox/search.html similarity index 100% rename from imp/templates/mailbox/search-mimp.html rename to imp/templates/mimp/mailbox/search.html diff --git a/imp/templates/message/message-mimp.html b/imp/templates/mimp/message/message.html similarity index 100% rename from imp/templates/message/message-mimp.html rename to imp/templates/mimp/message/message.html diff --git a/imp/templates/message/part-mimp.html b/imp/templates/mimp/message/part.html similarity index 100% rename from imp/templates/message/part-mimp.html rename to imp/templates/mimp/message/part.html diff --git a/imp/templates/filters/prefs.html b/imp/templates/prefs/filters/filters.html similarity index 100% rename from imp/templates/filters/prefs.html rename to imp/templates/prefs/filters/filters.html diff --git a/imp/templates/pgp/import_key.html b/imp/templates/prefs/pgp/import_key.html similarity index 100% rename from imp/templates/pgp/import_key.html rename to imp/templates/prefs/pgp/import_key.html diff --git a/imp/templates/pgp/pgp.html b/imp/templates/prefs/pgp/pgp.html similarity index 100% rename from imp/templates/pgp/pgp.html rename to imp/templates/prefs/pgp/pgp.html diff --git a/imp/templates/smime/import_key.html b/imp/templates/prefs/smime/import_key.html similarity index 100% rename from imp/templates/smime/import_key.html rename to imp/templates/prefs/smime/import_key.html diff --git a/imp/templates/smime/smime.html b/imp/templates/prefs/smime/smime.html similarity index 100% rename from imp/templates/smime/smime.html rename to imp/templates/prefs/smime/smime.html diff --git a/imp/templates/stationery/stationery.html b/imp/templates/prefs/stationery/stationery.html similarity index 100% rename from imp/templates/stationery/stationery.html rename to imp/templates/prefs/stationery/stationery.html diff --git a/imp/thread.php b/imp/thread.php index 5093bd786..de4be45dd 100644 --- a/imp/thread.php +++ b/imp/thread.php @@ -162,5 +162,5 @@ IMP::prepareMenu(); require IMP_TEMPLATES . '/common-header.inc'; IMP::menu(); IMP::status(); -echo $template->fetch(IMP_TEMPLATES . '/thread/thread.html'); +echo $template->fetch(IMP_TEMPLATES . '/imp/thread/thread.html'); require $registry->get('templates', 'horde') . '/common-footer.inc'; -- 2.11.0