aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrub <rub@piwigo.org>2007-02-11 00:43:53 +0000
committerrub <rub@piwigo.org>2007-02-11 00:43:53 +0000
commitfb8ac5394a32dad1fd7b453d9a498b7d8cc6ac07 (patch)
treebc36b7520d0068afdab3b61c3bc2edbd1b252127
parent8a8c80d4405d2bd3300558aa29848937bcf77f5d (diff)
Fix text/plain mail
Fix translations git-svn-id: http://piwigo.org/svn/trunk@1803 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--include/functions_mail.inc.php46
-rw-r--r--language/en_UK.iso-8859-1/admin.lang.php8
2 files changed, 30 insertions, 24 deletions
diff --git a/include/functions_mail.inc.php b/include/functions_mail.inc.php
index 98f5b5a1d..68df98e10 100644
--- a/include/functions_mail.inc.php
+++ b/include/functions_mail.inc.php
@@ -206,30 +206,36 @@ function pwg_mail($to, $from = '', $subject = 'PhpWebGallery', $infos = '', $for
'MAIL' => get_webmaster_mail_address()
));
- $mail_template->set_filename('mail_css_default_template', 'default-layout-mail-css.tpl');
- $mail_template->assign_var_from_handle('MAIL_CSS_DEFAULT_TEMPLATE', 'mail_css_default_template');
+ if ($email_format == 'text/html')
+ {
+ if (is_file($mail_template->root.'/default-layout-mail-css.tpl'))
+ {
+ $mail_template->set_filename('mail_css_default_template', 'default-layout-mail-css.tpl');
+ $mail_template->assign_var_from_handle('MAIL_CSS_DEFAULT_TEMPLATE', 'mail_css_default_template');
+ }
- $old_root = $mail_template->root;
+ $old_root = $mail_template->root;
- $mail_template->root = PHPWG_ROOT_PATH.'template/'.$user['template'].'/theme/'.$user['theme'];
- if (is_file($mail_template->root.'/layout-mail-css.tpl'))
- {
- $mail_template->set_filename('mail_css_theme', 'layout-mail-css.tpl');
- $mail_template->assign_var_from_handle('MAIL_CSS_THEME', 'mail_css_theme');
- }
+ $mail_template->root = PHPWG_ROOT_PATH.'template/'.$user['template'].'/theme/'.$user['theme'];
+ if (is_file($mail_template->root.'/layout-mail-css.tpl'))
+ {
+ $mail_template->set_filename('mail_css_theme', 'layout-mail-css.tpl');
+ $mail_template->assign_var_from_handle('MAIL_CSS_THEME', 'mail_css_theme');
+ }
- $mail_template->root = PHPWG_ROOT_PATH.'template-common';
- if (is_file($mail_template->root.'/local-layout-mail-css.tpl'))
- {
- $mail_template->set_filename('mail_css_local_template', 'local-layout-mail-css.tpl');
- $mail_template->assign_var_from_handle('MAIL_CSS_LOCAL_COMMON', 'mail_css_local_template');
- }
+ $mail_template->root = PHPWG_ROOT_PATH.'template-common';
+ if (is_file($mail_template->root.'/local-layout-mail-css.tpl'))
+ {
+ $mail_template->set_filename('mail_css_local_template', 'local-layout-mail-css.tpl');
+ $mail_template->assign_var_from_handle('MAIL_CSS_LOCAL_COMMON', 'mail_css_local_template');
+ }
- $mail_template->root = $old_root;
- if (is_file($mail_template->root.'/local-layout-mail-css.tpl'))
- {
- $mail_template->set_filename('mail_css_local_template', 'local-layout-mail-css.tpl');
- $mail_template->assign_var_from_handle('MAIL_CSS_LOCAL_TEMPLATE', 'mail_css_local_template');
+ $mail_template->root = $old_root;
+ if (is_file($mail_template->root.'/local-layout-mail-css.tpl'))
+ {
+ $mail_template->set_filename('mail_css_local_template', 'local-layout-mail-css.tpl');
+ $mail_template->assign_var_from_handle('MAIL_CSS_LOCAL_TEMPLATE', 'mail_css_local_template');
+ }
}
// what are displayed on the header of each mail ?
diff --git a/language/en_UK.iso-8859-1/admin.lang.php b/language/en_UK.iso-8859-1/admin.lang.php
index 06ae1dd6c..da0853856 100644
--- a/language/en_UK.iso-8859-1/admin.lang.php
+++ b/language/en_UK.iso-8859-1/admin.lang.php
@@ -287,13 +287,13 @@ $lang['nbm_content_new_elements'] = 'New elements were added ';
$lang['nbm_content_new_elements_single'] = ' on ';
$lang['nbm_content_new_elements_between_1'] = 'between ';
$lang['nbm_content_new_elements_between_2'] = ' and ';
-$lang['nbm_content_subscribe_by_admin'] = 'The webmaster has subcribed you for receiving notifications by mail';
-$lang['nbm_content_subscribe_by_himself'] = 'You have subcribed to receiving notifications by mail';
+$lang['nbm_content_subscribe_by_admin'] = 'The webmaster has subcribed you for receiving notifications by mail.';
+$lang['nbm_content_subscribe_by_himself'] = 'You have subcribed to receiving notifications by mail.';
$lang['nbm_content_subscribe_link'] = 'To subscribe';
$lang['nbm_content_problem_contact'] = 'If you encounter problems or have any question, please send a message to ';
$lang['nbm_content_pb_contact_object'] = '[NBM] Problems or questions';
-$lang['nbm_content_unsubscribe_by_admin'] = 'The webmaster has unsubcribed you from receiving notifications by mail';
-$lang['nbm_content_unsubscribe_by_himself'] = 'You have unsubcribed from receiving notifications by mail';
+$lang['nbm_content_unsubscribe_by_admin'] = 'The webmaster has unsubcribed you from receiving notifications by mail.';
+$lang['nbm_content_unsubscribe_by_himself'] = 'You have unsubcribed from receiving notifications by mail.';
$lang['nbm_content_click_on'] = ', click on ';
$lang['nbm_content_unsubscribe_link'] = 'To unsubscribe';
$lang['nbm_info_send_mail_as'] = 'With blank value, gallery title will be used';