postfixadmin-svn Mailing List for PostfixAdmin (Page 109)
Brought to you by:
christian_boltz,
gingerdog
You can subscribe to this list here.
2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(13) |
Oct
(63) |
Nov
(79) |
Dec
(34) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
(15) |
Feb
(8) |
Mar
(8) |
Apr
(44) |
May
(18) |
Jun
(20) |
Jul
(35) |
Aug
(21) |
Sep
(8) |
Oct
(9) |
Nov
(21) |
Dec
(14) |
2009 |
Jan
(53) |
Feb
(13) |
Mar
(36) |
Apr
(40) |
May
(22) |
Jun
(10) |
Jul
(18) |
Aug
(18) |
Sep
(7) |
Oct
(26) |
Nov
(32) |
Dec
(13) |
2010 |
Jan
(6) |
Feb
(7) |
Mar
(12) |
Apr
(2) |
May
(12) |
Jun
(8) |
Jul
(9) |
Aug
(12) |
Sep
(12) |
Oct
(7) |
Nov
(9) |
Dec
(42) |
2011 |
Jan
(10) |
Feb
(35) |
Mar
(43) |
Apr
(39) |
May
(8) |
Jun
(8) |
Jul
(83) |
Aug
(20) |
Sep
(20) |
Oct
(63) |
Nov
(33) |
Dec
(20) |
2012 |
Jan
(28) |
Feb
(3) |
Mar
(1) |
Apr
(37) |
May
(16) |
Jun
(7) |
Jul
(3) |
Aug
|
Sep
|
Oct
(3) |
Nov
(1) |
Dec
(4) |
2013 |
Jan
(6) |
Feb
(16) |
Mar
(9) |
Apr
(11) |
May
(9) |
Jun
(30) |
Jul
(17) |
Aug
(6) |
Sep
(2) |
Oct
(30) |
Nov
(41) |
Dec
(26) |
2014 |
Jan
(16) |
Feb
(20) |
Mar
(5) |
Apr
(4) |
May
(14) |
Jun
(4) |
Jul
(1) |
Aug
|
Sep
(8) |
Oct
(18) |
Nov
(26) |
Dec
|
2015 |
Jan
(4) |
Feb
(9) |
Mar
(12) |
Apr
(26) |
May
(3) |
Jun
(3) |
Jul
(2) |
Aug
|
Sep
(15) |
Oct
(13) |
Nov
|
Dec
(1) |
2016 |
Jan
(1) |
Feb
(5) |
Mar
(4) |
Apr
(3) |
May
(19) |
Jun
|
Jul
|
Aug
(3) |
Sep
(16) |
Oct
(4) |
Nov
(5) |
Dec
(5) |
2017 |
Jan
(1) |
Feb
(8) |
Mar
|
Apr
(7) |
May
(3) |
Jun
(16) |
Jul
(13) |
Aug
(16) |
Sep
(6) |
Oct
(4) |
Nov
(10) |
Dec
(7) |
2018 |
Jan
(16) |
Feb
(17) |
Mar
(11) |
Apr
(13) |
May
(20) |
Jun
(3) |
Jul
(10) |
Aug
|
Sep
(3) |
Oct
(1) |
Nov
(6) |
Dec
(18) |
2019 |
Jan
(18) |
Feb
(31) |
Mar
(4) |
Apr
(4) |
May
(1) |
Jun
(8) |
Jul
(7) |
Aug
(10) |
Sep
(23) |
Oct
(6) |
Nov
(3) |
Dec
(5) |
2020 |
Jan
(10) |
Feb
(18) |
Mar
(34) |
Apr
(19) |
May
(6) |
Jun
(9) |
Jul
|
Aug
(10) |
Sep
(16) |
Oct
(6) |
Nov
(3) |
Dec
(11) |
2021 |
Jan
(118) |
Feb
(22) |
Mar
(13) |
Apr
(12) |
May
(48) |
Jun
(21) |
Jul
(17) |
Aug
(12) |
Sep
(19) |
Oct
(25) |
Nov
(16) |
Dec
(7) |
2022 |
Jan
(6) |
Feb
(7) |
Mar
(14) |
Apr
(4) |
May
|
Jun
(16) |
Jul
(18) |
Aug
(5) |
Sep
(12) |
Oct
(8) |
Nov
(10) |
Dec
(13) |
2023 |
Jan
|
Feb
(3) |
Mar
(2) |
Apr
(1) |
May
(2) |
Jun
(6) |
Jul
(3) |
Aug
(3) |
Sep
(3) |
Oct
(2) |
Nov
(7) |
Dec
(13) |
2024 |
Jan
(8) |
Feb
(6) |
Mar
(5) |
Apr
(10) |
May
(8) |
Jun
(6) |
Jul
(2) |
Aug
(1) |
Sep
(2) |
Oct
(4) |
Nov
(15) |
Dec
(10) |
2025 |
Jan
(3) |
Feb
(12) |
Mar
(3) |
Apr
(7) |
May
(18) |
Jun
(10) |
Jul
(10) |
Aug
(6) |
Sep
(16) |
Oct
(1) |
Nov
|
Dec
|
From: <chr...@us...> - 2008-02-26 19:44:26
|
Revision: 301 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=301&view=rev Author: christian_boltz Date: 2008-02-26 11:44:27 -0800 (Tue, 26 Feb 2008) Log Message: ----------- language.php: - added japanese translation of "japanese" - taken from phpMyAdmin ;-) Modified Paths: -------------- trunk/languages/language.php Modified: trunk/languages/language.php =================================================================== --- trunk/languages/language.php 2008-02-26 19:39:14 UTC (rev 300) +++ trunk/languages/language.php 2008-02-26 19:44:27 UTC (rev 301) @@ -22,7 +22,7 @@ 'hu' => 'Magyar - Hungarian', 'is' => 'Icelandic', 'it' => 'Italiano - Italian', - 'ja' => 'Japanese', + 'ja' => '日本語 - Japanese', 'lt' => 'Lietuvių - Lithuanian', 'mk' => 'Macedonian - Macedonian', 'nl' => 'Nederlands - Dutch', This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-02-26 19:39:11
|
Revision: 300 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=300&view=rev Author: christian_boltz Date: 2008-02-26 11:39:14 -0800 (Tue, 26 Feb 2008) Log Message: ----------- ja.lang: - NEW: japanese translation added by Daisuke Aoyama <aoyama at peach dot ne dot jp> / daoyama @SF language.php: - added ja to list of available languages - added comment about the content of the language list Modified Paths: -------------- trunk/languages/language.php Added Paths: ----------- trunk/languages/ja.lang Added: trunk/languages/ja.lang =================================================================== --- trunk/languages/ja.lang (rev 0) +++ trunk/languages/ja.lang 2008-02-26 19:39:14 UTC (rev 300) @@ -0,0 +1,405 @@ +<?php +# $Id: en.lang 275 2007-12-28 21:42:09Z christian_boltz $ +// +// Language file Japanese +// by Daisuke Aoyama <aoyama at peach dot ne dot jp> +// + + +$PALANG['YES'] = 'はい'; +$PALANG['NO'] = 'いいえ'; +$PALANG['edit'] = '編集'; +$PALANG['del'] = '削除'; +$PALANG['exit'] = '終了'; +$PALANG['cancel'] = 'キャンセル'; +$PALANG['save'] = '保存'; +$PALANG['confirm'] = '本当に削除してもよろしいですか?\n'; +$PALANG['confirm_domain'] = '本当にこのドメインのすべての情報を削除してもよろしいですか?これを元に戻すことはできません。\n'; +$PALANG['check_update'] = '更新の確認'; +$PALANG['invalid_parameter'] = '無効なパラメータです。'; + +$PALANG['pFooter_logged_as'] = 'ログイン名 %s'; + +$PALANG['pLogin_welcome'] = 'こちらからドメインの管理ができます。'; +$PALANG['pLogin_username'] = 'ログイン (メールアドレス)'; +$PALANG['pLogin_password'] = 'パスワード'; +$PALANG['pLogin_button'] = 'ログイン'; +$PALANG['pLogin_username_incorrect'] = '<span class="error_msg">ログインが違います。正しいメールアドレスを入力してください。</span>'; +$PALANG['pLogin_password_incorrect'] = '<span class="error_msg">パスワードが違います。</span>'; +$PALANG['pLogin_login_users'] = '一般ユーザのログインはここをクリックしてください。'; + +$PALANG['pMenu_main'] = 'メイン'; +$PALANG['pMenu_overview'] = '概要'; +$PALANG['pMenu_create_alias'] = '転送先の追加'; +$PALANG['pMenu_create_mailbox'] = 'アドレスの追加'; +$PALANG['pMenu_fetchmail'] = 'メール取得'; +$PALANG['pMenu_sendmail'] = 'メール送信'; +$PALANG['pMenu_password'] = 'パスワード'; +$PALANG['pMenu_viewlog'] = 'ログ表示'; +$PALANG['pMenu_logout'] = 'ログアウト'; + +$PALANG['pMain_welcome'] = 'Postfix Admin へようこそ!'; +$PALANG['pMain_overview'] = '転送アドレスとメールアドレスの一覧を表示します。ここから編集と削除ができます。'; +$PALANG['pMain_create_alias'] = '新しい転送アドレスを作成します。'; +$PALANG['pMain_create_mailbox'] = '新しいメールアドレスを作成します。'; +$PALANG['pMain_sendmail'] = '新しいメールアドレスにメールを送信します。'; +$PALANG['pMain_password'] = 'パスワードを変更します。'; +$PALANG['pMain_viewlog'] = 'ログファイルを表示します。'; +$PALANG['pMain_logout'] = 'ログアウトします。'; + +$PALANG['pOverview_disabled'] = '無効'; +$PALANG['pOverview_unlimited'] = '無制限'; +$PALANG['pOverview_title'] = ':: 定義済ドメイン'; +$PALANG['pOverview_up_arrow'] = 'トップ'; +$PALANG['pOverview_right_arrow'] = '次ページ'; +$PALANG['pOverview_left_arrow'] = '前ページ'; +$PALANG['pOverview_alias_title'] = ':: 転送アドレス'; +$PALANG['pOverview_mailbox_title'] = ':: メールアドレス'; +$PALANG['pOverview_button'] = '表示'; +$PALANG['pOverview_welcome'] = '概要 '; +$PALANG['pOverview_alias_alias_count'] = '転送数'; +$PALANG['pOverview_alias_mailbox_count'] = 'アドレス数'; +$PALANG['pOverview_alias_address'] = '転送元'; +$PALANG['pOverview_alias_goto'] = '転送先'; +$PALANG['pOverview_alias_modified'] = '最終更新日'; +$PALANG['pOverview_alias_active'] = 'アクティブ'; +$PALANG['pOverview_alias_edit'] = '転送'; +$PALANG['and_x_more'] = '[その他 %s 個]'; +$PALANG['pOverview_mailbox_username'] = 'メールアドレス'; +$PALANG['pOverview_mailbox_name'] = '名前'; +$PALANG['pOverview_mailbox_quota'] = '容量制限 (MB)'; +$PALANG['pOverview_mailbox_modified'] = '最終更新日'; +$PALANG['pOverview_mailbox_active'] = 'アクティブ'; +$PALANG['pOverview_vacation_edit'] = '自動応答 利用中'; +$PALANG['pOverview_vacation_option'] = '自動応答'; + + +$PALANG['pOverview_get_domain'] = 'ドメイン'; +$PALANG['pOverview_get_aliases'] = '転送'; +$PALANG['pOverview_get_mailboxes'] = 'アドレス'; +$PALANG['pOverview_get_quota'] = '容量制限 (MB)'; +$PALANG['pOverview_get_modified'] = '最終更新日'; +$PALANG['pDelete_delete_error'] = '<span class="error_msg">エントリを削除できません。 '; +$PALANG['pDelete_delete_success'] = '%s を削除しました。'; +$PALANG['pDelete_postdelete_error'] = '<span class="error_msg">メールアドレスを削除できません。 '; +$PALANG['pDelete_domain_error'] = '<span class="error_msg">このドメインは管理外です。 '; +$PALANG['pDelete_alias_error'] = '<span class="error_msg">転送アドレスを削除できません。 '; + +$PALANG['pCreate_alias_welcome'] = '新しい転送先の作成'; +$PALANG['pCreate_alias_address'] = '転送元アドレス'; +$PALANG['pCreate_alias_address_text_error1'] = '<br /><span class="error_msg">メールアドレスが無効です。'; +$PALANG['pCreate_alias_address_text_error2'] = '<br /><span class="error_msg">このメールアドレスは既に存在するので、<br />別のアドレスを選択してください。</span>'; +$PALANG['pCreate_alias_address_text_error3'] = '<br /><span class="error_msg">転送アドレスの制限数に達しました。</span>'; +$PALANG['pCreate_alias_goto'] = '転送先アドレス'; +$PALANG['pCreate_alias_active'] = 'アクティブ'; +$PALANG['pCreate_alias_button'] = '転送先追加'; +$PALANG['pCreate_alias_goto_text'] = 'メールを転送するアドレス'; +$PALANG['pCreate_alias_goto_text_error'] = 'メールを転送するアドレス<br /><span class="error_msg">転送先が無効です。</span>'; +$PALANG['pCreate_alias_result_error'] = '<span class="error_msg">転送先を追加できません!</span>'; +$PALANG['pCreate_alias_result_success'] = '転送先を追加しました。'; +$PALANG['pCreate_alias_catchall_text'] = 'すべてのメールを受け取るには、転送元に "*" を使います。<br />別のドメインにすべて転送するには、転送先に "*.domain.tld" を使います。'; + +$PALANG['pEdit_alias_welcome'] = '転送先アドレスの編集<br />1行に1エントリです。'; +$PALANG['pEdit_alias_address'] = '転送元'; +$PALANG['pEdit_alias_address_error'] = '<span class="error_msg">転送元が見つかりません!</span>'; +$PALANG['pEdit_alias_goto'] = '転送先'; +$PALANG['pEdit_alias_active'] = 'アクティブ'; +$PALANG['pEdit_alias_goto_text_error1'] = '<span class="error_msg">転送先が入力されていません。</span>'; +$PALANG['pEdit_alias_goto_text_error2'] = '<span class="error_msg">このメールアドレスは無効です: '; +$PALANG['pEdit_alias_domain_error'] = '<span class="error_msg">このドメインは管理外です: '; +$PALANG['pEdit_alias_forward_and_store'] = 'ローカルのメールボックスに残す'; +$PALANG['pEdit_alias_forward_only'] = '指定された転送アドレスのみ'; +$PALANG['pEdit_alias_button'] = '転送先修正'; +$PALANG['pEdit_alias_result_error'] = '<span class="error_msg">修正できません!</span>'; + +$PALANG['pCreate_mailbox_welcome'] = '新しいメールアドレスの作成'; +$PALANG['pCreate_mailbox_username'] = 'ユーザ名'; +$PALANG['pCreate_mailbox_username_text_error1'] = '<br /><span class="error_msg">メールアドレスが無効です。</span>'; +$PALANG['pCreate_mailbox_username_text_error2'] = '<br /><span class="error_msg">このメールアドレスは既に存在するので、別のアドレスを選択してください。</span>'; +$PALANG['pCreate_mailbox_username_text_error3'] = '<br /><span class="error_msg">メールアドレスの制限数に達しました。</span>'; +$PALANG['pCreate_mailbox_password'] = 'パスワード'; +$PALANG['pCreate_mailbox_password2'] = 'パスワード (確認)'; +$PALANG['pCreate_mailbox_password_text'] = 'POP3/IMAPのパスワード'; +$PALANG['pCreate_mailbox_password_text_error'] = 'POP3/IMAPのパスワード<br /><span class="error_msg">パスワードが一致しません。<br />または空です。</span>'; +$PALANG['pCreate_mailbox_name'] = '名前'; +$PALANG['pCreate_mailbox_name_text'] = 'フルネーム'; +$PALANG['pCreate_mailbox_quota'] = '容量制限'; +$PALANG['pCreate_mailbox_quota_text'] = 'MB'; +$PALANG['pCreate_mailbox_quota_text_error'] = 'MB<br /><span class="error_msg">指定された容量制限が大きすぎます。</span>'; +$PALANG['pCreate_mailbox_active'] = 'アクティブ'; +$PALANG['pCreate_mailbox_mail'] = 'ようこそメールの送信'; +$PALANG['pCreate_mailbox_button'] = 'メールアドレス追加'; +$PALANG['pCreate_mailbox_result_error'] = '<span class="error_msg">メールアドレスを追加できません!</span>'; +$PALANG['pCreate_mailbox_result_success'] = 'メールアドレスを追加しました。'; +$PALANG['pCreate_mailbox_result_succes_nosubfolders'] = 'メールアドレスを追加しました。しかし、いくつかのサブフォルダの作成に失敗しました。'; + +$PALANG['pEdit_mailbox_welcome'] = 'メールアドレスの編集'; +$PALANG['pEdit_mailbox_username'] = 'メールアドレス'; +$PALANG['pEdit_mailbox_username_error'] = '<span class="error_msg">Unable to locate mailbox!</span>'; +$PALANG['pEdit_mailbox_password'] = '新しいパスワード'; +$PALANG['pEdit_mailbox_password2'] = '新しいパスワード (確認)'; +$PALANG['pEdit_mailbox_password_text_error'] = '<span class="error_msg">パスワードが一致しません。</span>'; +$PALANG['pEdit_mailbox_name'] = '名前'; +$PALANG['pEdit_mailbox_name_text'] = 'フルネーム'; +$PALANG['pEdit_mailbox_quota'] = '容量制限'; +$PALANG['pEdit_mailbox_quota_text'] = 'MB'; +$PALANG['pEdit_mailbox_quota_text_error'] = 'MB<br /><span class="error_msg">指定された容量制限が大きすぎます。</span>'; +$PALANG['pEdit_mailbox_domain_error'] = '<span class="error_msg">このドメインは管理外です: '; +$PALANG['pEdit_mailbox_button'] = 'メールアドレス修正'; +$PALANG['pEdit_mailbox_result_error'] = '<span class="error_msg">修正できません!</span>'; + +$PALANG['pPassword_welcome'] = 'パスワードの変更'; +$PALANG['pPassword_admin'] = 'ログイン'; +$PALANG['pPassword_admin_text_error'] = '<span class="error_msg">指定されたログインはメールボックスに一致しません。</span>'; +$PALANG['pPassword_password_current'] = '現在のパスワード'; +$PALANG['pPassword_password_current_text_error'] = '<span class="error_msg">現在のパスワードが入力されていません。</span>'; +$PALANG['pPassword_password'] = '新規パスワード'; +$PALANG['pPassword_password2'] = '新規パスワード (確認)'; +$PALANG['pPassword_password_text_error'] = '<span class="error_msg">パスワードが一致しません。<br />または空です。</span>'; +$PALANG['pPassword_button'] = 'パスワード変更'; +$PALANG['pPassword_result_error'] = '<span class="error_msg">パスワードを変更できません!</span>'; +$PALANG['pPassword_result_success'] = 'パスワードを変更しました。'; + +$PALANG['pEdit_vacation_set'] = 'メッセージ変更/設定'; +$PALANG['pEdit_vacation_remove'] = 'メッセージ解除'; + +$PALANG['pVacation_result_error'] = '<span class="error_msg">自動応答の設定を更新できませんでした!</span>'; +$PALANG['pVacation_result_removed'] = '自動応答を解除しました。'; +$PALANG['pVacation_result_added'] = '自動応答を設定しました。'; + +$PALANG['pViewlog_welcome'] = '過去10個のアクション '; +$PALANG['pViewlog_timestamp'] = 'タイムスタンプ'; +$PALANG['pViewlog_username'] = '管理者'; +$PALANG['pViewlog_domain'] = 'ドメイン'; +$PALANG['pViewlog_action'] = 'アクション'; +$PALANG['pViewlog_data'] = 'データ'; + +$PALANG['pViewlog_action_create_mailbox'] = 'アドレス作成'; +$PALANG['pViewlog_action_delete_mailbox'] = 'アドレス削除'; +$PALANG['pViewlog_action_edit_mailbox'] = 'アドレス編集'; +$PALANG['pViewlog_action_edit_mailbox_state'] = 'アドレス状態編集'; +$PALANG['pViewlog_action_create_alias'] = '転送先作成'; +$PALANG['pViewlog_action_delete_alias'] = '転送先削除'; +$PALANG['pViewlog_action_edit_alias'] = '転送先編集'; +$PALANG['pViewlog_action_edit_alias_state'] = '転送先状態編集'; +$PALANG['pViewlog_action_edit_password'] = 'パスワード変更'; + +$PALANG['pViewlog_button'] = '表示'; +$PALANG['pViewlog_result_error'] = '<span class="error_msg">ログが見つかりません!</span>'; + +$PALANG['pSendmail_welcome'] = 'メール送信'; +$PALANG['pSendmail_admin'] = '差出人'; +$PALANG['pSendmail_to'] = '宛先'; +$PALANG['pSendmail_to_text_error'] = '<span class="error_msg">宛先が空欄か無効です。</span>'; +$PALANG['pSendmail_subject'] = '件名'; +$PALANG['pSendmail_subject_text'] = 'ようこそ'; +$PALANG['pSendmail_body'] = '本文'; +$PALANG['pSendmail_button'] = 'メッセージ送信'; +$PALANG['pSendmail_result_error'] = '<span class="error_msg">メールが送信できません!</span>'; +$PALANG['pSendmail_result_success'] = 'メールが送信されました。'; + +$PALANG['pAdminMenu_list_admin'] = '管理者一覧'; +$PALANG['pAdminMenu_list_domain'] = 'ドメイン一覧'; +$PALANG['pAdminMenu_list_virtual'] = 'アドレス一覧'; +$PALANG['pAdminMenu_viewlog'] = 'ログ表示'; +$PALANG['pAdminMenu_backup'] = 'バックアップ'; +$PALANG['pAdminMenu_create_domain_admins'] = 'ドメイン管理者'; +$PALANG['pAdminMenu_create_admin'] = '新しい管理者'; +$PALANG['pAdminMenu_create_domain'] = '新しいドメイン'; +$PALANG['pAdminMenu_create_alias'] = '転送先の追加'; +$PALANG['pAdminMenu_create_mailbox'] = 'アドレスの追加'; + +$PALANG['pAdminList_admin_domain'] = 'ドメイン'; +$PALANG['pAdminList_admin_username'] = '管理者'; +$PALANG['pAdminList_admin_count'] = 'ドメイン数'; +$PALANG['pAdminList_admin_modified'] = '最終更新日'; +$PALANG['pAdminList_admin_active'] = 'アクティブ'; + +$PALANG['pAdminList_domain_domain'] = 'ドメイン'; +$PALANG['pAdminList_domain_description'] = '説明'; +$PALANG['pAdminList_domain_aliases'] = '転送数'; +$PALANG['pAdminList_domain_mailboxes'] = 'アドレス数'; +$PALANG['pAdminList_domain_maxquota'] = '容量制限 (MB)'; +$PALANG['pAdminList_domain_transport'] = '配送方法'; +$PALANG['pAdminList_domain_backupmx'] = 'バックアップ MX'; +$PALANG['pAdminList_domain_modified'] = '最終更新日'; +$PALANG['pAdminList_domain_active'] = 'アクティブ'; + +$PALANG['pAdminList_virtual_button'] = '表示'; +$PALANG['pAdminList_virtual_welcome'] = '概要 '; +$PALANG['pAdminList_virtual_alias_alias_count'] = '転送数'; +$PALANG['pAdminList_virtual_alias_mailbox_count'] = 'アドレス数'; +$PALANG['pAdminList_virtual_alias_address'] = '転送元'; +$PALANG['pAdminList_virtual_alias_goto'] = '転送先'; +$PALANG['pAdminList_virtual_alias_modified'] = '最終更新日'; +$PALANG['pAdminList_virtual_mailbox_username'] = 'メールアドレス'; +$PALANG['pAdminList_virtual_mailbox_name'] = '名前'; +$PALANG['pAdminList_virtual_mailbox_quota'] = '容量制限 (MB)'; +$PALANG['pAdminList_virtual_mailbox_modified'] = '最終更新日'; +$PALANG['pAdminList_virtual_mailbox_active'] = 'アクティブ'; + +$PALANG['pAdminCreate_domain_welcome'] = '新しいドメインの追加'; +$PALANG['pAdminCreate_domain_domain'] = 'ドメイン'; +$PALANG['pAdminCreate_domain_domain_text_error'] = '<span class="error_msg">ドメインが既に存在します。</span>'; +$PALANG['pAdminCreate_domain_domain_text_error2'] = '<span class="error_msg">ドメインが無効です。</span>'; +$PALANG['pAdminCreate_domain_description'] = '説明'; +$PALANG['pAdminCreate_domain_aliases'] = '最大転送先数'; +$PALANG['pAdminCreate_domain_aliases_text'] = '-1 = 無効 | 0 = 無制限'; +$PALANG['pAdminCreate_domain_mailboxes'] = '最大メールアドレス数'; +$PALANG['pAdminCreate_domain_mailboxes_text'] = '-1 = 無効 | 0 = 無制限'; +$PALANG['pAdminCreate_domain_maxquota'] = '最大容量制限'; +$PALANG['pAdminCreate_domain_maxquota_text'] = 'MB<br /> -1 = 無効 | 0 = 無制限'; +$PALANG['pAdminCreate_domain_transport'] = '配送方法'; +$PALANG['pAdminCreate_domain_transport_text'] = '配送方法の定義'; +$PALANG['pAdminCreate_domain_defaultaliases'] = 'デフォルト転送先の追加'; +$PALANG['pAdminCreate_domain_defaultaliases_text'] = ''; +$PALANG['pAdminCreate_domain_backupmx'] = 'バックアップ MXサーバ'; +$PALANG['pAdminCreate_domain_button'] = 'ドメイン追加'; +$PALANG['pAdminCreate_domain_result_error'] = '<span class="error_msg">ドメインを追加できません!</span>'; +$PALANG['pAdminCreate_domain_result_success'] = 'ドメインを追加しました。'; + +$PALANG['pAdminDelete_domain_error'] = '<span class="error_msg">ドメインが削除できません!</span>'; + +$PALANG['pAdminEdit_domain_welcome'] = 'ドメインの修正'; +$PALANG['pAdminEdit_domain_domain'] = 'ドメイン'; +$PALANG['pAdminEdit_domain_description'] = '説明'; +$PALANG['pAdminEdit_domain_aliases'] = '最大転送先数'; +$PALANG['pAdminEdit_domain_aliases_text'] = '-1 = 無効 | 0 = 無制限'; +$PALANG['pAdminEdit_domain_mailboxes'] = '最大メールアドレス'; +$PALANG['pAdminEdit_domain_mailboxes_text'] = '-1 = 無効 | 0 = 無制限'; +$PALANG['pAdminEdit_domain_maxquota'] = '最大容量制限'; +$PALANG['pAdminEdit_domain_maxquota_text'] = 'MB<br /> -1 = 無効 | 0 = 無制限'; +$PALANG['pAdminEdit_domain_transport'] = '配送方法'; +$PALANG['pAdminEdit_domain_transport_text'] = '配送方法の定義'; +$PALANG['pAdminEdit_domain_backupmx'] = 'バックアップ MXサーバ'; +$PALANG['pAdminEdit_domain_active'] = 'アクティブ'; +$PALANG['pAdminEdit_domain_button'] = 'ドメイン修正'; +$PALANG['pAdminEdit_domain_result_error'] = '<span class="error_msg">ドメインが修正できません!</span>'; + +$PALANG['pAdminCreate_admin_welcome'] = '新しいドメイン管理者の追加'; +$PALANG['pAdminCreate_admin_username'] = 'ドメイン管理者'; +$PALANG['pAdminCreate_admin_username_text'] = 'メールアドレス'; +$PALANG['pAdminCreate_admin_username_text_error1'] = 'メールアドレス<br /><span class="error_msg">管理者は有効なメールアドレスではありません。</span>'; +$PALANG['pAdminCreate_admin_username_text_error2'] = 'メールアドレス<br /><span class="error_msg">管理者は存在するか無効です。</span>'; +$PALANG['pAdminCreate_admin_password'] = 'パスワード'; +$PALANG['pAdminCreate_admin_password2'] = 'パスワード (確認)'; +$PALANG['pAdminCreate_admin_password_text_error'] = '<span class="error_msg">パスワードが一致しません。<br />または空です。</span>'; +$PALANG['pAdminCreate_admin_button'] = '管理者追加'; +$PALANG['pAdminCreate_admin_result_error'] = '<span class="error_msg">管理者を追加できません!</span>'; +$PALANG['pAdminCreate_admin_result_success'] = '管理者を追加しました。'; +$PALANG['pAdminCreate_admin_address'] = 'ドメイン'; + +$PALANG['pAdminEdit_admin_welcome'] = 'ドメイン管理者の編集'; +$PALANG['pAdminEdit_admin_username'] = '管理者'; +$PALANG['pAdminEdit_admin_password'] = 'パスワード'; +$PALANG['pAdminEdit_admin_password2'] = 'パスワード (確認)'; +$PALANG['pAdminEdit_admin_password_text_error'] = '<span class="error_msg">パスワードが一致しません。<br />または空です。</span>'; +$PALANG['pAdminEdit_admin_active'] = 'アクティブ'; +$PALANG['pAdminEdit_admin_super_admin'] = '特権管理者'; +$PALANG['pAdminEdit_admin_button'] = '管理者修正'; +$PALANG['pAdminEdit_admin_result_error'] = '<span class="error_msg">管理者を修正できません!</span>'; +$PALANG['pAdminEdit_admin_result_success'] = '管理者を修正しました。'; + +$PALANG['pUsersLogin_welcome'] = 'あなたのパスワードと転送先が変更できます。'; +$PALANG['pUsersLogin_username'] = 'ログイン (メールアドレス)'; +$PALANG['pUsersLogin_password'] = 'パスワード'; +$PALANG['pUsersLogin_button'] = 'ログイン'; +$PALANG['pUsersLogin_username_incorrect'] = 'ログインが違います。正しいメールアドレスを入力してください。'; +$PALANG['pUsersLogin_password_incorrect'] = 'パスワードが違います。'; + +$PALANG['pUsersMenu_vacation'] = '自動応答'; +$PALANG['pUsersMenu_edit_alias'] = '転送先変更'; +$PALANG['pUsersMenu_password'] = 'パスワード変更'; + +$PALANG['pUsersMain_vacation'] = '不在メッセージまたは自動応答を設定します'; +$PALANG['pUsersMain_vacationSet'] = '自動応答を利用中です。「自動応答」をクリックして編集/解除できます。'; +$PALANG['pUsersMain_edit_alias'] = '転送設定を変更します。'; +$PALANG['pUsersMain_password'] = 'パスワードを変更します。'; + +$PALANG['pUsersVacation_welcome'] = '自動応答'; +$PALANG['pUsersVacation_welcome_text'] = '既に自動応答を構成してあります。'; +$PALANG['pUsersVacation_subject'] = '件名'; +$PALANG['pUsersVacation_subject_text'] = '不在'; +$PALANG['pUsersVacation_body'] = '本文'; +$PALANG['pUsersVacation_body_text'] = <<<EOM +私は <date> から <date> まで不在です。 +緊急事項は <contact person> まで連絡してください。 +EOM; +$PALANG['pUsersVacation_button_away'] = '設定'; +$PALANG['pUsersVacation_button_back'] = '解除'; +$PALANG['pUsersVacation_result_error'] = '<span class="error_msg">自動応答の設定を更新できませんでした!</span>'; +$PALANG['pUsersVacation_result_success'] = '自動応答を解除しました。'; + +$PALANG['pCreate_dbLog_createmailbox'] = 'create mailbox'; +$PALANG['pCreate_dbLog_createalias'] = 'create alias'; +$PALANG['pDelete_dbLog_deletealias'] = 'delete alias'; +$PALANG['pDelete_dbLog_deletemailbox'] = 'delete mailbox'; + +$PALANG['pEdit_dbLog_editactive'] = 'change active state'; +$PALANG['pEdit_dbLog_editalias'] = 'edit alias'; +$PALANG['pEdit_dbLog_editmailbox'] = 'edit mailbox'; + +$PALANG['pSearch'] = '検索'; +$PALANG['pSearch_welcome'] = '検索文字列: '; + +$PALANG['pReturn_to'] = '戻る: '; + +$PALANG['pBroadcast_title'] = 'ブロードキャストメッセージの送信'; +$PALANG['pBroadcast_from'] = '差出人'; +$PALANG['pBroadcast_name'] = '名前'; +$PALANG['pBroadcast_subject'] = '件名'; +$PALANG['pBroadcast_message'] = 'メッセージ'; +$PALANG['pBroadcast_send'] = 'メッセージ送信'; +$PALANG['pBroadcast_success'] = 'ブロードキャストメッセージは送信されました。'; +$PALANG['pAdminMenu_broadcast_message'] = 'ブロードキャスト'; +$PALANG['pBroadcast_error_empty'] = '名前、件名、メッセージは入力が必要です。'; + +$PALANG['pStatus_undeliverable'] = 'おそらく配送不可能 '; +$PALANG['pStatus_custom'] = '配送先 '; +$PALANG['pStatus_popimap'] = 'POP/IMAP '; + +$PALANG['pPasswordTooShort'] = "パスワードが短すぎます。最低 %s 文字必要です。"; # usage: flash_error(sprintf($PALANG['pPasswordTooShort'], $CONF['min_password_length'])); + +$PALANG['pFetchmail_welcome'] = 'メール取得:'; +$PALANG['pFetchmail_new_entry'] = '新しいエントリ'; +$PALANG['pFetchmail_database_save_error'] = 'このエントリをデータベースに保存できませんでした。'; +$PALANG['pFetchmail_database_save_success'] = 'エントリをデータベースに保存しました。'; +$PALANG['pFetchmail_error_invalid_id'] = 'ID %s のエントリが見つかりません。'; +$PALANG['pFetchmail_invalid_mailbox'] = 'メールボックスが無効です!'; +$PALANG['pFetchmail_server_missing'] = 'リモートサーバ名を入力してください。'; +$PALANG['pFetchmail_user_missing'] = 'リモートユーザ名を入力してください。'; +$PALANG['pFetchmail_password_missing'] = 'リモートパスワードを入力してください。'; +$PALANG['pFetchmail_field_id'] = 'ID'; +$PALANG['pFetchmail_field_mailbox'] = 'メールボックス'; +$PALANG['pFetchmail_field_src_server'] = 'サーバ'; +$PALANG['pFetchmail_field_src_auth'] = '認証タイプ'; +$PALANG['pFetchmail_field_src_user'] = 'ユーザ'; +$PALANG['pFetchmail_field_src_password'] = 'パスワード'; +$PALANG['pFetchmail_field_src_folder'] = 'フォルダ'; +$PALANG['pFetchmail_field_poll_time'] = '間隔'; +$PALANG['pFetchmail_field_fetchall'] = 'すべて取得'; +$PALANG['pFetchmail_field_keep'] = '残す'; +$PALANG['pFetchmail_field_protocol'] = 'プロトコル'; +$PALANG['pFetchmail_field_extra_options'] = '追加オプション'; +$PALANG['pFetchmail_field_mda'] = 'MDA'; +$PALANG['pFetchmail_field_date'] = '日付'; +$PALANG['pFetchmail_field_returned_text'] = '戻りテキスト'; +$PALANG['pFetchmail_desc_id'] = 'レコード ID'; +$PALANG['pFetchmail_desc_mailbox'] = 'ローカル メールボックス'; +$PALANG['pFetchmail_desc_src_server'] = 'リモート サーバ'; +$PALANG['pFetchmail_desc_src_auth'] = '大抵は \'password\''; # Translators: Please do NOT translate 'password' here +$PALANG['pFetchmail_desc_src_user'] = 'リモート ユーザ'; +$PALANG['pFetchmail_desc_src_password'] = 'リモート パスワード'; +$PALANG['pFetchmail_desc_src_folder'] = 'リモート フォルダ'; +$PALANG['pFetchmail_desc_poll_time'] = '分単位の確認間隔'; +$PALANG['pFetchmail_desc_fetchall'] = '既読と新着メッセージを取得するか'; +$PALANG['pFetchmail_desc_keep'] = 'リモートサーバに取得済メッセージを残すか'; +$PALANG['pFetchmail_desc_protocol'] = '利用するプロトコル'; +$PALANG['pFetchmail_desc_extra_options'] = '追加の fetchmail オプション'; +$PALANG['pFetchmail_desc_mda'] = 'メール配送エージェント (Mail Delivery Agent)'; +$PALANG['pFetchmail_desc_date'] = '最終取得確認/設定変更日時'; +$PALANG['pFetchmail_desc_returned_text'] = '新着確認の戻りテキストメッセージ'; + +$PALANG['please_keep_this_as_last_entry'] = ''; # needed for language-check.sh +/* vim: set expandtab ft=php softtabstop=3 tabstop=3 shiftwidth=3: */ +?> Modified: trunk/languages/language.php =================================================================== --- trunk/languages/language.php 2008-02-21 21:43:58 UTC (rev 299) +++ trunk/languages/language.php 2008-02-26 19:39:14 UTC (rev 300) @@ -2,6 +2,8 @@ <?php # List of supported languages $supported_languages = array( +# Format: +# 'code' => 'native language name - language name in english' 'bg' => 'Български - Bulgarian', 'ca' => 'Català - Catalan', 'cn' => '中文 - Chinese simplified (gb2312)', @@ -20,6 +22,7 @@ 'hu' => 'Magyar - Hungarian', 'is' => 'Icelandic', 'it' => 'Italiano - Italian', + 'ja' => 'Japanese', 'lt' => 'Lietuvių - Lithuanian', 'mk' => 'Macedonian - Macedonian', 'nl' => 'Nederlands - Dutch', This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-02-21 21:43:56
|
Revision: 299 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=299&view=rev Author: GingerDog Date: 2008-02-21 13:43:58 -0800 (Thu, 21 Feb 2008) Log Message: ----------- applied patch from lenix - theme support for postfixadmin; see http://sourceforge.net/tracker/index.php?func=detail&aid=1898481&group_id=191583&atid=937966 - thank you Modified Paths: -------------- trunk/config.inc.php trunk/images/postfixadmin2.xcf trunk/index.php trunk/templates/header.php Added Paths: ----------- trunk/css/ trunk/css/default.css trunk/images/logo-default.png Removed Paths: ------------- trunk/stylesheet.css Modified: trunk/config.inc.php =================================================================== --- trunk/config.inc.php 2008-01-20 20:28:23 UTC (rev 298) +++ trunk/config.inc.php 2008-02-21 21:43:58 UTC (rev 299) @@ -33,10 +33,10 @@ // Postfix Admin Path // Set the location of your Postfix Admin installation here. -// You must enter complete url (http://domain.tld/) +// YOU MUST ENTER THE COMPLETE URL e.g. http://domain.tld/postfixadmin $CONF['postfix_admin_url'] = ''; -// leave this alone... +// shouldn't need changing. $CONF['postfix_admin_path'] = dirname(__FILE__); // Language config @@ -312,6 +312,11 @@ // http://www.php.net/manual/en/function.imap-open.php +// Theme Config +// Specify your own logo and CSS file +$CONF['theme_logo'] = 'images/logo-default.png'; +$CONF['theme_css'] = 'css/default.css'; + // If you want to keep most settings at default values and/or want to ensure // that future updates work without problems, you can use a separate config // file (config.local.php) instead of editing this file and override some Added: trunk/css/default.css =================================================================== --- trunk/css/default.css (rev 0) +++ trunk/css/default.css 2008-02-21 21:43:58 UTC (rev 299) @@ -0,0 +1,296 @@ +body { + background: #ffffff; + color: #000000; + font-family: "BitStream Vera Sans", Verdana, Arial, Helvetica, sans-serif; + font-size: 11px; + font-weight: normal; + text-align: center; +} + +a { + text-decoration: none; + color: #888888; +} + +a:hover { + text-decoration: underline; + color: #888888; +} + +a:visited, a:active { + color: #888888; +} + +table { + /* border-spacing: 0; */ + /* padding: 0; */ + border-collapse: collapse; /* for IE */ +} + +.button { + border: 1px solid #aaaaaa; + color: #777777; + background: #dddddd; + padding: 3px 3px 3px 3px; + font-size: 11px; +} + +.button:hover { + background: #BCFF36; + color: #888888; +} + +.flat { + border: 1px solid #888888; +} + +.error_msg { + color: #d01313; +} + +.standout { + color: maroon; + padding: 3px 3px 3px 3px; + text-align: center; +} + +#login_header { + width: 750px; + margin: 0 auto; + padding-bottom: 10px; + text-align: left; +} + +#login { + width: 750px; + margin: 0 auto; +} + +#login_table { + border-left: 8px solid gray; + border-right: 8px solid gray; + background: #eeeeee; + width: 350px; + margin: 0 auto; + border-collapse: separate; + border-spacing: 10px; +} + +#login_table h4 { + font-size: 13px; +} + +#menu { + width: 750px; + margin: 0 auto; + padding-top: 10px; + white-space: nowrap; +} + +#menu ul { + padding: 0; + margin: 0; + margin-left:auto; + margin-right:auto; + list-style: none; +} + +#menu li { + float: left; + background: #efefef; + margin-right: 3px; + border-top: 4px solid #aaaaaa; +} + +#menu li:hover, #menu li.sfhover { + background: #BFFF00; +} + +#menu li ul { + position: absolute; + width: auto; + left: -999em; + border:2px solid white; + border-top:none; +} +#menu li:hover ul, #menu li.sfhover ul { + left: auto; +} + + +#menu li ul li { + float: none; + margin-right: 0px; + border-top:2px solid white;; + text-align:left; +} + + + + +#menu a { + display: block; + width: auto; + padding: 20px 5px 5px 5px; + color: #888888; +} + +#menu a:hover { + color: #888888; +} + + + +#menu li ul li a { + padding: 5px 5px 5px 5px; +} + + + +#main_menu, #edit_form { + width: 750px; + margin: 0 auto; +} + +#edit_form table { + margin: 0 auto; + padding-top: 10px; + text-align: left; + width: 500px; + border: 1px solid #efefef; +} + +#edit_form h3 { + text-align: center; + font-size: 12px; + margin: 0; + background: #AFE1A6; /*#b4004a;*/ + border: 1px solid #bbb; + line-height: 25px; + color: #555555; +} + +.hlp_center { + text-align: center; +} + +.help_text { + background: #efefef; + border-left: 1px solid #bbbbbb; + border-right: 1px solid #bbbbbb; + text-align: center; + padding-top: 5px; + padding-bottom: 5px; +} + +#main_menu table { + margin: 0 auto; + text-align: left; + padding-top: 20px; + padding-bottom: 20px; +} + +#main_menu table td { + padding-left: 30px; + padding-bottom: 5px; +} + +#main_menu a { + color: #888888; + padding-left: 8px; +} + +#main_menu a:hover { + color: #40B33C; /*#CD6A6A;*/ + text-decoration: none; + padding-left: 4px; + border-bottom: 1px solid #40B33C; + border-left: 4px solid #40B33C; +} + +#overview, #admin_domains, #admin_virtual { + width: 750px; + margin: 0 auto; + background: #AFE1A6; /*#9ACD32;*/ + border: 1px solid #bbb; +} + +#overview h4, #overview P, #overview FORM, #admin_virtual h4, #admin_virtual P, #admin_virtual FORM { + display: inline; + padding-right: 10px; + line-height: 30px; +} + +#nav_bar { + text-align: right; + width: 750px; + margin: 0 auto; +} + +#alias_table, #mailbox_table, #overview_table, #log_table, #admin_table { + width: 750px; + margin: 0px auto; + border: 1px solid #efefef; +} + +#alias_table .header, #mailbox_table .header, #overview_table .header, #log_table .header, #admin_table .header { + line-height: 20px; + background: #efefef; + color: black; +} + +#alias_table .hilightoff, #mailbox_table .hilightoff, #overview_table .hilightoff, #log_table .hilightoff, #admin_table .hilighoff { + background: white; +} + +#alias_table .hilighton, #mailbox_table .hilighton, #overview_table .hilighton, #log_table .hilighton, #admin_table .hilighton { + background: #D9FF43; /*#D6FF85;*/ /*#ffdddd;*/ +} + +#alias_table tr:hover, #mailbox_table tr:hover, #overview_table tr:hover, #log_table tr:hover, #admin_table tr:hover { + background: #D9FF43; /*#D6FF85;*/ /*#ffdddd;*/ +} + + +#alias_table h3, #mailbox_table h3, #overview_table h3, #log_table h3, #admin_table h3 { + background: silver; + text-align: left; + font-size: 12px; + font-weight: bold; + padding-left: 20px; + line-height: 25px; + margin: 0; +} + +#footer { + width: 750px; + margin: 20px auto; + border-top: 1px solid #bbbbbb; + background: #efefef; + color: #999999; + line-height: 20px; + text-align: left; + padding-left: 15px; + font-size: 9px; +} + +#footer a { + text-decoration: none; + color: #999999; +} + +#footer a:hover { + text-decoration: underline; + color: #777777; +} + +div.setup { + width:700px; + margin-left:auto; + margin-right:auto; + text-align: left; +} + +div.setup li { + padding-bottom:1em; +} Added: trunk/images/logo-default.png =================================================================== (Binary files differ) Property changes on: trunk/images/logo-default.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: trunk/images/postfixadmin2.xcf =================================================================== (Binary files differ) Modified: trunk/index.php =================================================================== --- trunk/index.php 2008-01-20 20:28:23 UTC (rev 298) +++ trunk/index.php 2008-02-21 21:43:58 UTC (rev 299) @@ -35,8 +35,7 @@ <title>Welcome to Postfix Admin</title> </head> <body> - <img id="login_header_logo" src="images/postbox.png" /> - <img id="login_header_logo2" src="images/postfixadmin2.png" /> + <img id="login_header_logo" src="images/logo-default.png" /> <h1>Welcome to Postfix Admin</h1> <h2>What is it?</h2> <p>Postfix Admin is a web based interface to configure and manage a Postfix based email server for many users.</p> Deleted: trunk/stylesheet.css =================================================================== --- trunk/stylesheet.css 2008-01-20 20:28:23 UTC (rev 298) +++ trunk/stylesheet.css 2008-02-21 21:43:58 UTC (rev 299) @@ -1,296 +0,0 @@ -body { - background: #ffffff; - color: #000000; - font-family: "BitStream Vera Sans", Verdana, Arial, Helvetica, sans-serif; - font-size: 11px; - font-weight: normal; - text-align: center; -} - -a { - text-decoration: none; - color: #888888; -} - -a:hover { - text-decoration: underline; - color: #888888; -} - -a:visited, a:active { - color: #888888; -} - -table { - /* border-spacing: 0; */ - /* padding: 0; */ - border-collapse: collapse; /* for IE */ -} - -.button { - border: 1px solid #aaaaaa; - color: #777777; - background: #dddddd; - padding: 3px 3px 3px 3px; - font-size: 11px; -} - -.button:hover { - background: #BCFF36; - color: #888888; -} - -.flat { - border: 1px solid #888888; -} - -.error_msg { - color: #d01313; -} - -.standout { - color: maroon; - padding: 3px 3px 3px 3px; - text-align: center; -} - -#login_header { - width: 750px; - margin: 0 auto; - padding-bottom: 10px; - text-align: left; -} - -#login { - width: 750px; - margin: 0 auto; -} - -#login_table { - border-left: 8px solid gray; - border-right: 8px solid gray; - background: #eeeeee; - width: 350px; - margin: 0 auto; - border-collapse: separate; - border-spacing: 10px; -} - -#login_table h4 { - font-size: 13px; -} - -#menu { - width: 750px; - margin: 0 auto; - padding-top: 10px; - white-space: nowrap; -} - -#menu ul { - padding: 0; - margin: 0; - margin-left:auto; - margin-right:auto; - list-style: none; -} - -#menu li { - float: left; - background: #efefef; - margin-right: 3px; - border-top: 4px solid #aaaaaa; -} - -#menu li:hover, #menu li.sfhover { - background: #BFFF00; -} - -#menu li ul { - position: absolute; - width: auto; - left: -999em; - border:2px solid white; - border-top:none; -} -#menu li:hover ul, #menu li.sfhover ul { - left: auto; -} - - -#menu li ul li { - float: none; - margin-right: 0px; - border-top:2px solid white;; - text-align:left; -} - - - - -#menu a { - display: block; - width: auto; - padding: 20px 5px 5px 5px; - color: #888888; -} - -#menu a:hover { - color: #888888; -} - - - -#menu li ul li a { - padding: 5px 5px 5px 5px; -} - - - -#main_menu, #edit_form { - width: 750px; - margin: 0 auto; -} - -#edit_form table { - margin: 0 auto; - padding-top: 10px; - text-align: left; - width: 500px; - border: 1px solid #efefef; -} - -#edit_form h3 { - text-align: center; - font-size: 12px; - margin: 0; - background: #AFE1A6; /*#b4004a;*/ - border: 1px solid #bbb; - line-height: 25px; - color: #555555; -} - -.hlp_center { - text-align: center; -} - -.help_text { - background: #efefef; - border-left: 1px solid #bbbbbb; - border-right: 1px solid #bbbbbb; - text-align: center; - padding-top: 5px; - padding-bottom: 5px; -} - -#main_menu table { - margin: 0 auto; - text-align: left; - padding-top: 20px; - padding-bottom: 20px; -} - -#main_menu table td { - padding-left: 30px; - padding-bottom: 5px; -} - -#main_menu a { - color: #888888; - padding-left: 8px; -} - -#main_menu a:hover { - color: #40B33C; /*#CD6A6A;*/ - text-decoration: none; - padding-left: 4px; - border-bottom: 1px solid #40B33C; - border-left: 4px solid #40B33C; -} - -#overview, #admin_domains, #admin_virtual { - width: 750px; - margin: 0 auto; - background: #AFE1A6; /*#9ACD32;*/ - border: 1px solid #bbb; -} - -#overview h4, #overview P, #overview FORM, #admin_virtual h4, #admin_virtual P, #admin_virtual FORM { - display: inline; - padding-right: 10px; - line-height: 30px; -} - -#nav_bar { - text-align: right; - width: 750px; - margin: 0 auto; -} - -#alias_table, #mailbox_table, #overview_table, #log_table, #admin_table { - width: 750px; - margin: 0px auto; - border: 1px solid #efefef; -} - -#alias_table .header, #mailbox_table .header, #overview_table .header, #log_table .header, #admin_table .header { - line-height: 20px; - background: #efefef; - color: black; -} - -#alias_table .hilightoff, #mailbox_table .hilightoff, #overview_table .hilightoff, #log_table .hilightoff, #admin_table .hilighoff { - background: white; -} - -#alias_table .hilighton, #mailbox_table .hilighton, #overview_table .hilighton, #log_table .hilighton, #admin_table .hilighton { - background: #D9FF43; /*#D6FF85;*/ /*#ffdddd;*/ -} - -#alias_table tr:hover, #mailbox_table tr:hover, #overview_table tr:hover, #log_table tr:hover, #admin_table tr:hover { - background: #D9FF43; /*#D6FF85;*/ /*#ffdddd;*/ -} - - -#alias_table h3, #mailbox_table h3, #overview_table h3, #log_table h3, #admin_table h3 { - background: silver; - text-align: left; - font-size: 12px; - font-weight: bold; - padding-left: 20px; - line-height: 25px; - margin: 0; -} - -#footer { - width: 750px; - margin: 20px auto; - border-top: 1px solid #bbbbbb; - background: #efefef; - color: #999999; - line-height: 20px; - text-align: left; - padding-left: 15px; - font-size: 9px; -} - -#footer a { - text-decoration: none; - color: #999999; -} - -#footer a:hover { - text-decoration: underline; - color: #777777; -} - -div.setup { - width:700px; - margin-left:auto; - margin-right:auto; - text-align: left; -} - -div.setup li { - padding-bottom:1em; -} Modified: trunk/templates/header.php =================================================================== --- trunk/templates/header.php 2008-01-20 20:28:23 UTC (rev 298) +++ trunk/templates/header.php 2008-02-21 21:43:58 UTC (rev 299) @@ -12,10 +12,10 @@ <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <?php -if (file_exists (realpath ("./stylesheet.css"))) { - print "<link rel=\"stylesheet\" type=\"text/css\" href=\"stylesheet.css\" />\n"; -} elseif (file_exists (realpath ("../stylesheet.css"))) { - print "<link rel=\"stylesheet\" type=\"text/css\" href=\"../stylesheet.css\" />\n"; +if (file_exists (realpath ("../".$CONF['theme_css']))) { + print "<link rel=\"stylesheet\" type=\"text/css\" href=\"../".htmlentities($CONF['theme_css'])."\" />\n"; +} else { + print "<link rel=\"stylesheet\" type=\"text/css\" href=\"".htmlentities($CONF['theme_css'])."\" />\n"; } ?> <title>Postfix Admin - <?php print $_SERVER['HTTP_HOST']; ?></title> @@ -23,14 +23,11 @@ <body> <div id="login_header"> <?php -if (file_exists (realpath ("./stylesheet.css"))) +if (file_exists (realpath ("../".$CONF['theme_logo']))) { - print "<img id=\"login_header_logo\" src=\"images/postbox.png\" />\n"; - print "<img id=\"login_header_logo2\" src=\"images/postfixadmin2.png\" />\n"; -} elseif (file_exists (realpath ("../stylesheet.css"))) -{ - print "<img id=\"login_header_logo\" src=\"../images/postbox.png\" />\n"; - print "<img id=\"login_header_logo2\" src=\"../images/postfixadmin2.png\" />\n"; + print "<img id=\"login_header_logo\" src=\"../".htmlentities($CONF['theme_logo'])."\" />\n"; +} else { + print "<img id=\"login_header_logo\" src=\"".htmlentities($CONF['theme_logo'])."\" />\n"; } if (($CONF['show_header_text'] == "YES") and ($CONF['header_text'])) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-01-20 20:28:25
|
Revision: 298 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=298&view=rev Author: christian_boltz Date: 2008-01-20 12:28:23 -0800 (Sun, 20 Jan 2008) Log Message: ----------- users/main.php - only show vacation as active if active=true https://sourceforge.net/tracker/?func=detail&atid=937964&aid=1875901&group_id=191583 [That's what I meant with "side effects" when discussing the DELETE -> UPDATE ... set active=false change...] Modified Paths: -------------- trunk/users/main.php Modified: trunk/users/main.php =================================================================== --- trunk/users/main.php 2008-01-19 16:48:15 UTC (rev 297) +++ trunk/users/main.php 2008-01-20 20:28:23 UTC (rev 298) @@ -27,7 +27,8 @@ authentication_require_role('user'); $USERID_USERNAME = authentication_get_username(); -$result = db_query("SELECT * FROM $table_vacation WHERE email='$USERID_USERNAME'"); +$db_active = db_get_boolean(True); +$result = db_query("SELECT * FROM $table_vacation WHERE email='$USERID_USERNAME' AND active='$db_active'"); if ($result['rows'] == 1) { $row = db_array($result['result']); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-19 16:48:09
|
Revision: 297 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=297&view=rev Author: GingerDog Date: 2008-01-19 08:48:15 -0800 (Sat, 19 Jan 2008) Log Message: ----------- vacation: maintain away message after coming back for next time Modified Paths: -------------- trunk/edit-vacation.php trunk/users/vacation.php Modified: trunk/edit-vacation.php =================================================================== --- trunk/edit-vacation.php 2008-01-19 16:47:27 UTC (rev 296) +++ trunk/edit-vacation.php 2008-01-19 16:48:15 UTC (rev 297) @@ -84,10 +84,10 @@ if ($_SERVER['REQUEST_METHOD'] == "POST") { - $tSubject = safepost('fSubject'); - $fSubject = escape_string ( $tSubject); - $tBody = safepost('fBody'); - $fBody = escape_string ( $tBody); + $tSubject = safepost('fSubject'); + $fSubject = escape_string ($tSubject); + $tBody = safepost('fBody'); + $fBody = escape_string ($tBody); $fChange = escape_string (safepost('fChange')); $fBack = escape_string (safepost('fBack')); @@ -111,15 +111,13 @@ //if change, remove old one, then perhaps set new one if (!empty ($fBack) || !empty ($fChange)) { - //if we find an existing vacation entry, delete it + //if we find an existing vacation entry, disable it $result = db_query("SELECT * FROM $table_vacation WHERE email='$fUsername'"); if ($result['rows'] == 1) { - $result = db_query ("DELETE FROM $table_vacation WHERE email='$fUsername'"); - if ($result['rows'] != 1) - { - $error = 1; - } + $db_false = db_get_boolean(false); + // retain vacation message if possible - i.e disable vacation away-ness. + $result = db_query ("UPDATE $table_vacation SET active = $db_false WHERE email='$fUsername'"); $result = db_query ("SELECT * FROM $table_alias WHERE address='$fUsername'"); if ($result['rows'] == 1) @@ -157,7 +155,16 @@ $goto = $row['goto']; } $Active = db_get_boolean(True); - $result = db_query ("INSERT INTO $table_vacation (email,subject,body,domain,created,active) VALUES ('$fUsername','$fSubject','$fBody','$fDomain',NOW(),$Active)"); + $notActive = db_get_boolean(False); + // I don't think we need to care if the vacation entry is inactive or active.. as long as we don't try and + // insert a duplicate + $result = db_query("SELECT * FROM $table_vacation WHERE email = '$fUsername'"); + if($result['rows'] == 1) { + $result = db_query("UPDATE $table_vacation SET active = $Active, created = NOW() WHERE email = '$fUsername'"); + } + else { + $result = db_query ("INSERT INTO $table_vacation (email,subject,body,domain,created,active) VALUES ('$fUsername','$fSubject','$fBody','$fDomain',NOW(),$Active)"); + } if ($result['rows'] != 1) { Modified: trunk/users/vacation.php =================================================================== --- trunk/users/vacation.php 2008-01-19 16:47:27 UTC (rev 296) +++ trunk/users/vacation.php 2008-01-19 16:48:15 UTC (rev 297) @@ -84,17 +84,11 @@ // if they've set themselves away OR back, delete any record of vacation emails. if (!empty ($fBack) || !empty ($fAway)) { - $result = db_query ("DELETE FROM $table_vacation WHERE email='$USERID_USERNAME'"); - $result2 = db_query ("DELETE FROM $table_vacation_notification WHERE on_vacation='$USERID_USERNAME'"); - if ($result['rows'] != 1) - { - $error = 1; - $tMessage = $PALANG['pUsersVacation_result_error']; - } - else - { - $tMessage = $PALANG['pUsersVacation_result_success']; - } + $notActive = db_get_boolean(False); + // this isn't very good, as $result['rows'] would be 0 if the user had not used vacation stuff before. + $result = db_query("UPDATE $table_vacation SET active = $notActive WHERE email='$USERID_USERNAME'"); + $result = db_query("DELETE FROM $table_vacation_notification WHERE on_vacation='$USERID_USERNAME'"); + $tMessage = $PALANG['pUsersVacation_result_error']; // We need to see whether there is already an alias record for the user, or not. // If not, we create one, else update the existing one. @@ -146,7 +140,14 @@ $tGoto = $row['goto']; } $Active = db_get_boolean(True); - $result = db_query ("INSERT INTO $table_vacation (email,subject,body,domain,created,active) VALUES ('$USERID_USERNAME','$fSubject','$fBody','$USERID_DOMAIN',NOW(),$Active)"); + $result = db_query("SELECT * FROM $table_vacation WHERE email = '$USERID_USERNAME'"); + if($result['rows'] == 1) { + $result = db_query("UPDATE $table_vacation SET active = $Active, body = '$fBody', subject = '$fSubject', created = NOW() WHERE email = '$USERID_USERNAME'"); + } + else { + $result = db_query ("INSERT INTO $table_vacation (email,subject,body,domain,created,active) VALUES ('$USERID_USERNAME','$fSubject','$fBody','$USERID_DOMAIN',NOW(),$Active)"); + } + if ($result['rows'] != 1) { $error = 1; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-19 16:47:21
|
Revision: 296 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=296&view=rev Author: GingerDog Date: 2008-01-19 08:47:27 -0800 (Sat, 19 Jan 2008) Log Message: ----------- debian/rules: add stylesheet to .deb as per email reported bug (thanks) Modified Paths: -------------- trunk/debian/rules Modified: trunk/debian/rules =================================================================== --- trunk/debian/rules 2008-01-14 20:33:25 UTC (rev 295) +++ trunk/debian/rules 2008-01-19 16:47:27 UTC (rev 296) @@ -30,6 +30,7 @@ cp -a languages debian/postfixadmin/usr/share/postfixadmin cp -a templates debian/postfixadmin/usr/share/postfixadmin cp -a users debian/postfixadmin/usr/share/postfixadmin + cp stylesheet.css debian/postfixadmin/usr/share/postfixadmin mkdir -p debian/postfixadmin/etc/apache2/conf.d cp debian/apache-conf debian/postfixadmin/etc/apache2/conf.d/postfixadmin find debian/postfixadmin -name .svn | xargs -r rm -r This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gin...@us...> - 2008-01-14 20:33:21
|
Revision: 295 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=295&view=rev Author: gingerdog Date: 2008-01-14 12:33:25 -0800 (Mon, 14 Jan 2008) Log Message: ----------- index.php: fix broken url Modified Paths: -------------- website/index.php Modified: website/index.php =================================================================== --- website/index.php 2008-01-14 20:31:19 UTC (rev 294) +++ website/index.php 2008-01-14 20:33:25 UTC (rev 295) @@ -60,7 +60,8 @@ <h3>Other Relevant links and related projects</h3> <ul> -<li><a href="http://postfixadmin-squirrelmail.palepurple.co.uk">Postfixadmin/Squirrelmail plugin</a> - Integrate together <A href="http://squirrelmail.org">Squirrelmail</a> with Postfixadmin</a></li> +<li><a href="http://squirrelmail-postfixadmin.palepurple.co.uk">Postfixadmin/Squirrelmail plugin</a> - Integrate together <A href="http://squirrelmail.org">Squirrelmail</a> with Postfixadmin</a></li> +<li><a href="http://codepoets.co.uk/postfixadmin-postgresql-courier-squirrelmail-debian-etch-howto-tutorial@">Guide to installation on Etch with PostgreSQL and Courier</a></li> </ul> (If you would like to add links to any other relevant projects, please poke GingerDog on irc) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-14 20:31:14
|
Revision: 294 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=294&view=rev Author: GingerDog Date: 2008-01-14 12:31:19 -0800 (Mon, 14 Jan 2008) Log Message: ----------- index.php: update url Modified Paths: -------------- trunk/index.php Modified: trunk/index.php =================================================================== --- trunk/index.php 2008-01-14 07:41:21 UTC (rev 293) +++ trunk/index.php 2008-01-14 20:31:19 UTC (rev 294) @@ -68,7 +68,7 @@ <li>Read the <a href='INSTALL.TXT'>INSTALL.txt</a> file</li> <li>Configure Postfix to use your chosen database - see (for example) the following pages : <ul> - <li><a href="http://codepoets.co.uk/docs/postfix_postgresql_postfixadmin_courier_howto">Postfix/PostgreSQL/Postfixadmin/Courier</a></li> + <li><a href="http://codepoets.co.uk/postfixadmin-postgresql-courier-squirrelmail-debian-etch-howto-tutorial">Postfix/PostgreSQL/Postfixadmin/Courier</a></li> <li><a href="http://bliki.rimuhosting.com/space/knowledgebase/linux/mail/postfixadmin+on+debian+sarge">Postfix/MySQL/Postfixadmin/Dovecot</a></li> <li><a href="http://gentoo-wiki.com/HOWTO_Setup_a_Virtual_Postfix/Courier_Mail_System_with_PostfixAdmin">Postfix/MySQL/Postfixamdin/Courier</a></li> </ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-14 07:41:17
|
Revision: 293 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=293&view=rev Author: GingerDog Date: 2008-01-13 23:41:21 -0800 (Sun, 13 Jan 2008) Log Message: ----------- rules: when building .debs, change the $CONF["postfix_admin_path"] manually to /usr/share/postfixadmin; this stops us having issues with dirname(__FILE__) returning the realpath Modified Paths: -------------- trunk/debian/rules Modified: trunk/debian/rules =================================================================== --- trunk/debian/rules 2008-01-13 17:24:27 UTC (rev 292) +++ trunk/debian/rules 2008-01-14 07:41:21 UTC (rev 293) @@ -24,6 +24,7 @@ cp *.php debian/postfixadmin/usr/share/postfixadmin mv debian/postfixadmin/usr/share/postfixadmin/config.inc.php debian/postfixadmin/etc/postfixadmin/config.inc.php ln -s /etc/postfixadmin/config.inc.php debian/postfixadmin/usr/share/postfixadmin/config.inc.php + perl -p -i -e "s#$$CONF\['postfix_admin_path'\] = dirname\(__FILE__\)#$$CONF\['postfix_admin_path'\] = '/usr/share/postfixadmin'#" debian/postfixadmin/etc/postfixadmin/config.inc.php cp -a admin debian/postfixadmin/usr/share/postfixadmin cp -a images debian/postfixadmin/usr/share/postfixadmin cp -a languages debian/postfixadmin/usr/share/postfixadmin This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-01-13 17:25:00
|
Revision: 292 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=292&view=rev Author: christian_boltz Date: 2008-01-13 09:24:27 -0800 (Sun, 13 Jan 2008) Log Message: ----------- ru.lang: - translation update by Pavel Usischev (pusischev) - thanks! https://sourceforge.net/tracker/?func=detail&atid=937966&aid=1869896&group_id=191583 Modified Paths: -------------- trunk/languages/ru.lang Modified: trunk/languages/ru.lang =================================================================== --- trunk/languages/ru.lang 2008-01-09 21:47:28 UTC (rev 291) +++ trunk/languages/ru.lang 2008-01-13 17:24:27 UTC (rev 292) @@ -197,8 +197,8 @@ $PALANG['pSendmail_subject_text'] = 'Добро пожаловать!'; $PALANG['pSendmail_body'] = 'Текст'; $PALANG['pSendmail_button'] = 'Послать сообщение'; -$PALANG['pSendmail_result_error'] = '<span class="error_msg">Невозможно создать почтовый ящик!</span>'; # XXX text change - new: <span class="error_msg">Unable to send email!</span> -$PALANG['pSendmail_result_success'] = 'Почтовый ящик был создан!'; # XXX text change - new: Email sent! +$PALANG['pSendmail_result_error'] = '<span class="error_msg">Невозможно отправить сообщение!</span>'; +$PALANG['pSendmail_result_success'] = 'Сообщение отправлено!'; $PALANG['pAdminMenu_list_admin'] = 'Список админов'; $PALANG['pAdminMenu_list_domain'] = 'Список доменов'; @@ -223,7 +223,7 @@ $PALANG['pAdminList_domain_mailboxes'] = 'Ящики'; $PALANG['pAdminList_domain_maxquota'] = 'Квота (МБ)'; $PALANG['pAdminList_domain_transport'] = 'Транспорт'; -$PALANG['pAdminList_domain_backupmx'] = 'Backup MX'; +$PALANG['pAdminList_domain_backupmx'] = 'Резервный MX'; $PALANG['pAdminList_domain_modified'] = 'Последнее изменение'; $PALANG['pAdminList_domain_active'] = 'Активен'; @@ -255,7 +255,7 @@ $PALANG['pAdminCreate_domain_transport_text'] = 'Укажите транспорт'; $PALANG['pAdminCreate_domain_defaultaliases'] = 'Добавить стандартные алиасы для домена'; $PALANG['pAdminCreate_domain_defaultaliases_text'] = ''; -$PALANG['pAdminCreate_domain_backupmx'] = 'Почтовый сервер является backup MX'; +$PALANG['pAdminCreate_domain_backupmx'] = 'Почтовый сервер является резервным MX'; $PALANG['pAdminCreate_domain_button'] = 'Добавить домен'; $PALANG['pAdminCreate_domain_result_error'] = '<span class="error_msg">Невозможно добавить домен!</span>'; $PALANG['pAdminCreate_domain_result_success'] = 'Домен был добавлен!'; @@ -273,7 +273,7 @@ $PALANG['pAdminEdit_domain_maxquota_text'] = 'МБ<br /> -1 = отключить | 0 = неограниченное'; $PALANG['pAdminEdit_domain_transport'] = 'Транспорт'; $PALANG['pAdminEdit_domain_transport_text'] = 'Укажите транспорт'; -$PALANG['pAdminEdit_domain_backupmx'] = 'Почтовый сервер является backup MX'; +$PALANG['pAdminEdit_domain_backupmx'] = 'Почтовый сервер является резервным MX'; $PALANG['pAdminEdit_domain_active'] = 'Активен'; $PALANG['pAdminEdit_domain_button'] = 'Редактировать домен'; $PALANG['pAdminEdit_domain_result_error'] = '<span class="error_msg">Невозможно изменить домен!</span>'; @@ -353,7 +353,7 @@ $PALANG['pBroadcast_message'] = 'Сообщение'; $PALANG['pBroadcast_send'] = 'Отправить сообщение'; $PALANG['pBroadcast_success'] = 'Ваше широковещательное сообщение было отправлено.'; -$PALANG['pAdminMenu_broadcast_message'] = 'ШВ сообщение'; +$PALANG['pAdminMenu_broadcast_message'] = 'Широковещательное сообщение'; $PALANG['pBroadcast_error_empty'] = 'Поля Имя, Тема и Сообщение не должны быть пустыми!'; $PALANG['pStatus_undeliverable'] = 'возможно НЕ ДОСТАВЛЕНО '; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-01-09 21:49:43
|
Revision: 291 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=291&view=rev Author: christian_boltz Date: 2008-01-09 13:47:28 -0800 (Wed, 09 Jan 2008) Log Message: ----------- edit-mailbox.php - fix: put the values the user entered in the form again if an error was detected (instead of showing the form completely empty) - fix: do not check for password length when password is not going to be changed (empty password field). Thanks to Danilo Montagna (dmontagna) for pointing this out! https://sourceforge.net/forum/message.php?msg_id=4709926 Modified Paths: -------------- trunk/edit-mailbox.php Modified: trunk/edit-mailbox.php =================================================================== --- trunk/edit-mailbox.php 2008-01-06 20:20:42 UTC (rev 290) +++ trunk/edit-mailbox.php 2008-01-09 21:47:28 UTC (rev 291) @@ -96,12 +96,12 @@ if($fPassword != $user_details['password']){ $min_length = $CONF['min_password_length']; - if($min_length > 0 && strlen($fPassword) < $min_length) { - flash_error(sprintf($PALANG['pPasswordTooShort'], $CONF['min_password_length'])); - $error = 1; - } if($fPassword == $fPassword2) { if ($fPassword != "") { + if($min_length > 0 && strlen($fPassword) < $min_length) { + flash_error(sprintf($PALANG['pPasswordTooShort'], $CONF['min_password_length'])); + $error = 1; + } $formvars['password'] = pacrypt($fPassword); } } @@ -157,6 +157,13 @@ header ("Location: list-virtual.php?domain=$fDomain"); exit(0); } + } + else + { + # error detected. Put the values the user entered in the form again. + $tName = $fName; + $tQuota = $fQuota; + $tActive = $fActive; } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-01-06 20:20:38
|
Revision: 290 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=290&view=rev Author: christian_boltz Date: 2008-01-06 12:20:42 -0800 (Sun, 06 Jan 2008) Log Message: ----------- de.lang: - small fix: Mailboxes -> Mailboxen Modified Paths: -------------- trunk/languages/de.lang Modified: trunk/languages/de.lang =================================================================== --- trunk/languages/de.lang 2008-01-06 19:47:45 UTC (rev 289) +++ trunk/languages/de.lang 2008-01-06 20:20:42 UTC (rev 290) @@ -54,7 +54,7 @@ $PALANG['pOverview_right_arrow'] = 'Nächste Seite'; $PALANG['pOverview_left_arrow'] = 'Vorherige Seite'; $PALANG['pOverview_alias_title'] = ':: Alias'; -$PALANG['pOverview_mailbox_title'] = ':: Mailboxes'; +$PALANG['pOverview_mailbox_title'] = ':: Mailboxen'; $PALANG['pOverview_button'] = 'Los'; $PALANG['pOverview_welcome'] = 'Überblick über '; $PALANG['pOverview_alias_alias_count'] = 'Aliase'; @@ -75,7 +75,7 @@ $PALANG['pOverview_get_domain'] = 'Domain'; $PALANG['pOverview_get_aliases'] = 'Aliases'; -$PALANG['pOverview_get_mailboxes'] = 'Mailboxes'; +$PALANG['pOverview_get_mailboxes'] = 'Mailboxen'; $PALANG['pOverview_get_quota'] = 'Mailbox Quota (MB)'; $PALANG['pOverview_get_modified'] = 'Zuletzt verändert'; @@ -245,7 +245,7 @@ $PALANG['pAdminCreate_domain_description'] = 'Beschreibung'; $PALANG['pAdminCreate_domain_aliases'] = 'Aliase'; $PALANG['pAdminCreate_domain_aliases_text'] = '-1 = ausschalten | 0 = kein Limit'; -$PALANG['pAdminCreate_domain_mailboxes'] = 'Mailboxes'; +$PALANG['pAdminCreate_domain_mailboxes'] = 'Mailboxen'; $PALANG['pAdminCreate_domain_mailboxes_text'] = '-1 = ausschalten | 0 = kein Limit'; $PALANG['pAdminCreate_domain_maxquota'] = 'Max Quota'; $PALANG['pAdminCreate_domain_maxquota_text'] = 'MB<br /> -1 = ausschalten | 0 = kein Limit'; @@ -265,7 +265,7 @@ $PALANG['pAdminEdit_domain_description'] = 'Beschreibung'; $PALANG['pAdminEdit_domain_aliases'] = 'Aliase'; $PALANG['pAdminEdit_domain_aliases_text'] = '-1 = ausschalten | 0 = kein Limit'; -$PALANG['pAdminEdit_domain_mailboxes'] = 'Mailboxes'; +$PALANG['pAdminEdit_domain_mailboxes'] = 'Mailboxen'; $PALANG['pAdminEdit_domain_mailboxes_text'] = '-1 = ausschalten | 0 = kein Limit'; $PALANG['pAdminEdit_domain_maxquota'] = 'Max Quota'; $PALANG['pAdminEdit_domain_maxquota_text'] = 'MB<br /> -1 = ausschalten | 0 = kein Limit'; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-01-06 19:47:39
|
Revision: 289 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=289&view=rev Author: christian_boltz Date: 2008-01-06 11:47:45 -0800 (Sun, 06 Jan 2008) Log Message: ----------- setup.php: - added check for $CONF['configured'] Modified Paths: -------------- trunk/setup.php Modified: trunk/setup.php =================================================================== --- trunk/setup.php 2008-01-06 19:39:08 UTC (rev 288) +++ trunk/setup.php 2008-01-06 19:47:45 UTC (rev 289) @@ -113,6 +113,16 @@ print "<li>Depends on: presence config.inc.php - OK</li>\n"; require_once('config.inc.php'); $config_loaded = 1; + + require('config.inc.php'); + if(isset($CONF['configured'])) { + if($CONF['configured'] == TRUE) { + print "<li>Checking \$CONF['configured'] - OK\n"; + } else { + print "<li><b>Error: \$CONF['configured'] is 'false'.<br>\n"; + print "Please edit your config.inc.php settings and then change it.</b>\n"; + } + } } else { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2008-01-06 19:39:06
|
Revision: 288 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=288&view=rev Author: christian_boltz Date: 2008-01-06 11:39:08 -0800 (Sun, 06 Jan 2008) Log Message: ----------- common.php: - check if setup.php exists before blindly redirecting to it. Display error message if the user has already deleted it. (old behaviour caused some user confusion) Modified Paths: -------------- trunk/common.php Modified: trunk/common.php =================================================================== --- trunk/common.php 2008-01-06 17:12:10 UTC (rev 287) +++ trunk/common.php 2008-01-06 19:39:08 UTC (rev 288) @@ -19,6 +19,17 @@ define('POSTFIXADMIN', 1); # checked in included files +function incorrect_setup() { + global $incpath; + # we ask the user to delete setup.php, which makes a blind redirect a bad idea + if(!is_file("$incpath/setup.php")) { + die ("config.inc.php does not exist or is not configured correctly. Please re-install setup.php and create/fix your config."); + } else { + header("Location: setup.php"); + exit(0); + } +} + $incpath = dirname(__FILE__); (ini_get('magic_quotes_gpc') ? ini_set('magic_quotes_runtime', '0') : '1'); (ini_get('magic_quotes_gpc') ? ini_set('magic_quotes_sybase', '0') : '1'); @@ -27,16 +38,15 @@ die("Please turn off register_globals; edit your php.ini"); } require_once("$incpath/variables.inc.php"); + if(!is_file("$incpath/config.inc.php")) { // incorrectly setup... - header("Location: setup.php"); - exit(0); + incorrect_setup(); } require_once("$incpath/config.inc.php"); if(isset($CONF['configured'])) { if($CONF['configured'] == FALSE) { - header("Location: setup.php"); - exit(0); + incorrect_setup(); } } require_once("$incpath/languages/language.php"); @@ -44,3 +54,5 @@ require_once("$incpath/languages/" . check_language () . ".lang"); session_start(); + +/* vim: set expandtab softtabstop=4 tabstop=4 shiftwidth=4: */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-06 17:12:07
|
Revision: 287 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=287&view=rev Author: GingerDog Date: 2008-01-06 09:12:10 -0800 (Sun, 06 Jan 2008) Log Message: ----------- edit-mailbox.php: Closes #1865124 - too short error was not telling the user the minimum size Modified Paths: -------------- trunk/edit-mailbox.php Modified: trunk/edit-mailbox.php =================================================================== --- trunk/edit-mailbox.php 2008-01-03 21:58:02 UTC (rev 286) +++ trunk/edit-mailbox.php 2008-01-06 17:12:10 UTC (rev 287) @@ -97,7 +97,7 @@ $min_length = $CONF['min_password_length']; if($min_length > 0 && strlen($fPassword) < $min_length) { - flash_error($PALANG['pPasswordTooShort']); + flash_error(sprintf($PALANG['pPasswordTooShort'], $CONF['min_password_length'])); $error = 1; } if($fPassword == $fPassword2) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-03 22:05:50
|
Revision: 286 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=286&view=rev Author: GingerDog Date: 2008-01-03 13:58:02 -0800 (Thu, 03 Jan 2008) Log Message: ----------- upgrade.php: needless echo removed; tested on another PostgreSQL database - worked fine Modified Paths: -------------- trunk/upgrade.php Modified: trunk/upgrade.php =================================================================== --- trunk/upgrade.php 2008-01-03 21:51:08 UTC (rev 285) +++ trunk/upgrade.php 2008-01-03 21:58:02 UTC (rev 286) @@ -38,7 +38,7 @@ AND pg_catalog.pg_table_is_visible(c.oid) ) AND a.attname = '$field' "; - echo $sql; +// echo $sql; $r = db_query($sql); $row = db_row($r['result']); if($row) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-03 21:51:04
|
Revision: 285 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=285&view=rev Author: GingerDog Date: 2008-01-03 13:51:08 -0800 (Thu, 03 Jan 2008) Log Message: ----------- edit-mailbox.php: random edits - I thought password length check was already in... </confusion> Modified Paths: -------------- trunk/edit-mailbox.php Modified: trunk/edit-mailbox.php =================================================================== --- trunk/edit-mailbox.php 2008-01-03 21:50:39 UTC (rev 284) +++ trunk/edit-mailbox.php 2008-01-03 21:51:08 UTC (rev 285) @@ -52,107 +52,112 @@ if (!(check_owner ($SESSID_USERNAME, $fDomain) || authentication_has_role('global-admin')) ) { - $error = 1; - $tName = $fName; - $tQuota = $fQuota; - $tActive = $fActive; - $tMessage = $PALANG['pEdit_mailbox_domain_error'] . "$fDomain</span>"; + $error = 1; + $tName = $fName; + $tQuota = $fQuota; + $tActive = $fActive; + $tMessage = $PALANG['pEdit_mailbox_domain_error'] . "$fDomain</span>"; } $result = db_query("SELECT * FROM $table_mailbox WHERE username = '$fUsername' AND domain = '$fDomain'"); if($result['rows'] != 1) { - die("Invalid username chosen; user does not exist in mailbox table"); + die("Invalid username chosen; user does not exist in mailbox table"); } $user_details = db_array($result['result']); if ($_SERVER['REQUEST_METHOD'] == "GET") { - if (check_owner($SESSID_USERNAME, $fDomain) || authentication_has_role('global-admin')) - { - $tName = $user_details['name']; - $tQuota = divide_quota($user_details['quota']); - $tActive = $user_details['active']; - if ('pgsql'==$CONF['database_type']) { - $tActive = ('t'==$user_details['active']) ? 1 : 0; - } + if (check_owner($SESSID_USERNAME, $fDomain) || authentication_has_role('global-admin')) + { + $tName = $user_details['name']; + $tQuota = divide_quota($user_details['quota']); + $tActive = $user_details['active']; + if ('pgsql'==$CONF['database_type']) { + $tActive = ('t'==$user_details['active']) ? 1 : 0; + } - $result = db_query ("SELECT * FROM $table_domain WHERE domain='$fDomain'"); - if ($result['rows'] == 1) - { - $row = db_array ($result['result']); - $tMaxquota = $row['maxquota']; - } - } + $result = db_query ("SELECT * FROM $table_domain WHERE domain='$fDomain'"); + if ($result['rows'] == 1) + { + $row = db_array ($result['result']); + $tMaxquota = $row['maxquota']; + } + } } if ($_SERVER['REQUEST_METHOD'] == "POST") { - if (isset ($_POST['fPassword'])) $fPassword = escape_string ($_POST['fPassword']); - if (isset ($_POST['fPassword2'])) $fPassword2 = escape_string ($_POST['fPassword2']); - if (isset ($_POST['fName'])) $fName = escape_string ($_POST['fName']); - if (isset ($_POST['fQuota'])) $fQuota = intval ($_POST['fQuota']); - if (isset ($_POST['fActive'])) $fActive = escape_string ($_POST['fActive']); + if (isset ($_POST['fPassword'])) $fPassword = escape_string ($_POST['fPassword']); + if (isset ($_POST['fPassword2'])) $fPassword2 = escape_string ($_POST['fPassword2']); + if (isset ($_POST['fName'])) $fName = escape_string ($_POST['fName']); + if (isset ($_POST['fQuota'])) $fQuota = intval ($_POST['fQuota']); + if (isset ($_POST['fActive'])) $fActive = escape_string ($_POST['fActive']); - if($fPassword != $user_details['password']){ - if($fPassword == $fPassword2) { - if ($fPassword != "") { - $formvars['password'] = pacrypt($fPassword); - } - } - else { - flash_error($PALANG['pEdit_mailbox_password_text_error']); - $error = 1; - } - } + if($fPassword != $user_details['password']){ + $min_length = $CONF['min_password_length']; - if ($CONF['quota'] == "YES") - { - if (!check_quota ($fQuota, $fDomain)) - { - $error = 1; - $tName = $fName; - $tQuota = $fQuota; - $tActive = $fActive; - $pEdit_mailbox_quota_text = $PALANG['pEdit_mailbox_quota_text_error']; - } - } - if ($error != 1) - { - if (!empty ($fQuota)) - { - $quota = multiply_quota ($fQuota); - } - else - { - $quota = 0; - } + if($min_length > 0 && strlen($fPassword) < $min_length) { + flash_error($PALANG['pPasswordTooShort']); + $error = 1; + } + if($fPassword == $fPassword2) { + if ($fPassword != "") { + $formvars['password'] = pacrypt($fPassword); + } + } + else { + flash_error($PALANG['pEdit_mailbox_password_text_error']); + $error = 1; + } + } + if ($CONF['quota'] == "YES") + { + if (!check_quota ($fQuota, $fDomain)) + { + $error = 1; + $tName = $fName; + $tQuota = $fQuota; + $tActive = $fActive; + $pEdit_mailbox_quota_text = $PALANG['pEdit_mailbox_quota_text_error']; + } + } + if ($error != 1) + { + if (!empty ($fQuota)) + { + $quota = multiply_quota ($fQuota); + } + else + { + $quota = 0; + } - if ($fActive == "on") - { - $sqlActive = db_get_boolean(True); - $fActive = 1; - } - else - { - $sqlActive = db_get_boolean(False); - $fActive = 0; - } + if ($fActive == "on") + { + $sqlActive = db_get_boolean(True); + $fActive = 1; + } + else + { + $sqlActive = db_get_boolean(False); + $fActive = 0; + } - $formvars['name'] = $fName; - $formvars['quota'] =$quota; - $formvars['active']=$sqlActive; + $formvars['name'] = $fName; + $formvars['quota'] =$quota; + $formvars['active']=$sqlActive; - $result = db_update ('mailbox', "username='$fUsername' AND domain='$fDomain'", $formvars, array('modified')); - if ($result != 1) { - $tMessage = $PALANG['pEdit_mailbox_result_error']; - } - else { - db_log ($SESSID_USERNAME, $fDomain, 'edit_mailbox', $fUsername); + $result = db_update ('mailbox', "username='$fUsername' AND domain='$fDomain'", $formvars, array('modified')); + if ($result != 1) { + $tMessage = $PALANG['pEdit_mailbox_result_error']; + } + else { + db_log ($SESSID_USERNAME, $fDomain, 'edit_mailbox', $fUsername); -// header ("Location: list-virtual.php?domain=$fDomain"); - exit; - } - } + header ("Location: list-virtual.php?domain=$fDomain"); + exit(0); + } + } } include ("templates/header.php"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2008-01-03 21:50:37
|
Revision: 284 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=284&view=rev Author: GingerDog Date: 2008-01-03 13:50:39 -0800 (Thu, 03 Jan 2008) Log Message: ----------- list-virtual.php: Exit after header redirect Modified Paths: -------------- trunk/list-virtual.php Modified: trunk/list-virtual.php =================================================================== --- trunk/list-virtual.php 2007-12-30 20:16:07 UTC (rev 283) +++ trunk/list-virtual.php 2008-01-03 21:50:39 UTC (rev 284) @@ -28,9 +28,9 @@ * fDomain * fDisplay */ - require_once('common.php'); + authentication_require_role('admin'); $SESSID_USERNAME = authentication_get_username(); @@ -69,6 +69,7 @@ if (!check_owner(authentication_get_username(), $fDomain)) { # die($PALANG['invalid_parameter']); header("Location: list-domain.php"); # domain not owned by this admin + exit(0); } $query = "SELECT $table_alias.address,$table_alias.goto,$table_alias.modified,$table_alias.active FROM $table_alias LEFT JOIN $table_mailbox ON $table_alias.address=$table_mailbox.username WHERE $table_alias.domain='$fDomain' AND $table_mailbox.maildir IS NULL ORDER BY $table_alias.address LIMIT $fDisplay, $page_size"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2007-12-30 20:16:07
|
Revision: 283 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=283&view=rev Author: christian_boltz Date: 2007-12-30 12:16:07 -0800 (Sun, 30 Dec 2007) Log Message: ----------- functions.inc.php - fixed wrong comment about check_language parameter Modified Paths: -------------- trunk/functions.inc.php Modified: trunk/functions.inc.php =================================================================== --- trunk/functions.inc.php 2007-12-30 19:14:35 UTC (rev 282) +++ trunk/functions.inc.php 2007-12-30 20:16:07 UTC (rev 283) @@ -142,7 +142,7 @@ // check_language // Action: checks what language the browser uses // Call: check_language -// Parameter: $use_post - set to 1 if $_POST should NOT be read +// Parameter: $use_post - set to 0 if $_POST should NOT be read // function check_language ($use_post = 1) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2007-12-30 19:14:31
|
Revision: 282 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=282&view=rev Author: christian_boltz Date: 2007-12-30 11:14:35 -0800 (Sun, 30 Dec 2007) Log Message: ----------- backup.php - also backup vacation_notification table Reported by Johan Hendriks (sylhouette) - thanks! https://sourceforge.net/tracker/index.php?func=detail&aid=1860193&group_id=191583&atid=937964 Modified Paths: -------------- trunk/backup.php Modified: trunk/backup.php =================================================================== --- trunk/backup.php 2007-12-30 18:49:18 UTC (rev 281) +++ trunk/backup.php 2007-12-30 19:14:35 UTC (rev 282) @@ -72,7 +72,8 @@ { fwrite ($fh, $header); - $tables = array('admin','alias','config','domain','domain_admins','log','mailbox','vacation'); + $tables = array('admin','alias','config','domain','domain_admins','log','mailbox','vacation','vacation_notification'); + # TODO: also backup fetchmail table for ($i = 0 ; $i < sizeof ($tables) ; ++$i) { @@ -115,4 +116,5 @@ unlink ("$backup"); fpassthru ($download_backup); } +/* vim: set expandtab softtabstop=3 tabstop=3 shiftwidth=3: */ ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2007-12-30 18:49:43
|
Revision: 281 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=281&view=rev Author: christian_boltz Date: 2007-12-30 10:49:18 -0800 (Sun, 30 Dec 2007) Log Message: ----------- templates/menu.php: - added JS to enable dropdowns in IE https://sourceforge.net/tracker/?func=detail&atid=937964&aid=1859556&group_id=191583 stylesheet.css: - dupliated the menu :hover styles as .sfhover for IE Modified Paths: -------------- trunk/stylesheet.css trunk/templates/menu.php Modified: trunk/stylesheet.css =================================================================== --- trunk/stylesheet.css 2007-12-30 01:32:33 UTC (rev 280) +++ trunk/stylesheet.css 2007-12-30 18:49:18 UTC (rev 281) @@ -102,7 +102,7 @@ border-top: 4px solid #aaaaaa; } -#menu li:hover { +#menu li:hover, #menu li.sfhover { background: #BFFF00; } @@ -113,7 +113,7 @@ border:2px solid white; border-top:none; } -#menu li:hover ul { +#menu li:hover ul, #menu li.sfhover ul { left: auto; } Modified: trunk/templates/menu.php =================================================================== --- trunk/templates/menu.php 2007-12-30 01:32:33 UTC (rev 280) +++ trunk/templates/menu.php 2007-12-30 18:49:18 UTC (rev 281) @@ -79,5 +79,25 @@ print "</div>"; } + + +# IE can't handle :hover dropdowns correctly. It needs some JS instead. +?> +<script type='text/javascript'> +sfHover = function() { + var sfEls = document.getElementById("menu").getElementsByTagName("LI"); + for (var i=0; i<sfEls.length; i++) { + sfEls[i].onmouseover=function() { + this.className+=" sfhover"; + } + sfEls[i].onmouseout=function() { + this.className=this.className.replace(new RegExp(" sfhover\\b"), ""); + } + } +} +if (window.attachEvent) window.attachEvent("onload", sfHover); +</script> + +<?php /* vim: set ft=php expandtab softtabstop=3 tabstop=3 shiftwidth=3: */ ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2007-12-30 01:32:30
|
Revision: 280 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=280&view=rev Author: christian_boltz Date: 2007-12-29 17:32:33 -0800 (Sat, 29 Dec 2007) Log Message: ----------- Summary: Added language selector to login form functions.inc.php: - function check_language - new optional parameter $use_post (needed by login.php) - check for language cookie - check for $_POST['lang'] - removed substr() call because it made pt-br translation unuseable - new function language_selector - returns a HTML dropdown language selector - new function safecookie - similar to safeget, but for cookies templates/login.php, templates/users_login.php: - display language selector dropdown login.php, users/login.php: - check for selected language - set cookie if user selected non-default language languages/language.php: (NEW FILE) - list of supported languages - language names taken from phpMyAdmin login form common.php: - include languages/language.php Modified Paths: -------------- trunk/common.php trunk/functions.inc.php trunk/login.php trunk/templates/login.php trunk/templates/users_login.php trunk/users/login.php Added Paths: ----------- trunk/languages/language.php Modified: trunk/common.php =================================================================== --- trunk/common.php 2007-12-29 21:11:54 UTC (rev 279) +++ trunk/common.php 2007-12-30 01:32:33 UTC (rev 280) @@ -39,6 +39,7 @@ exit(0); } } +require_once("$incpath/languages/language.php"); require_once("$incpath/functions.inc.php"); require_once("$incpath/languages/" . check_language () . ".lang"); Modified: trunk/functions.inc.php =================================================================== --- trunk/functions.inc.php 2007-12-29 21:11:54 UTC (rev 279) +++ trunk/functions.inc.php 2007-12-30 01:32:33 UTC (rev 280) @@ -142,19 +142,29 @@ // check_language // Action: checks what language the browser uses // Call: check_language +// Parameter: $use_post - set to 1 if $_POST should NOT be read // -function check_language () +function check_language ($use_post = 1) { global $CONF; $lang = $CONF['default_language']; $supported_languages = array ('bg', 'ca', 'cn', 'cs', 'da', 'de', 'en', 'es', 'et', 'eu', 'fi', 'fo', 'fr', 'hu', 'is', 'it', 'mk', 'nl', 'nn', 'pl', 'pt-br', 'ru', 'sl', 'sv', 'tr', 'tw'); + # TODO: use global $supported_languages (from languages/languages.php) instead + if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { $lang_array = preg_split ('/(\s*,\s*)/', $_SERVER['HTTP_ACCEPT_LANGUAGE']); + if (safecookie('lang')) { + array_unshift($lang_array, safecookie('lang')); # prefer language from cookie + } + if ( $use_post && safepost('lang')) { + array_unshift($lang_array, safepost('lang')); # but prefer $_POST['lang'] even more + } + for($i = 0; $i < count($lang_array); $i++) { $lang_next = $lang_array[$i]; - $lang_next = strtolower(substr(trim($lang_next), 0, 2)); + $lang_next = strtolower(trim($lang_next)); if(in_array($lang_next, $supported_languages)) { $lang = $lang_next; @@ -165,8 +175,31 @@ return $lang; } +// +// language_selector +// Action: returns a language selector dropdown with the browser (or cookie) language preselected +// Call: language_selector() +// +function language_selector() +{ + global $supported_languages; # from languages/languages.php + + $current_lang = check_language(); + $selector = '<select name="lang" xml:lang="en" dir="ltr">'; + foreach($supported_languages as $lang => $lang_name) { + if ($lang == $current_lang) { + $selected = ' selected="selected"'; + } else { + $selected = ''; + } + $selector .= "<option value='$lang'$selected>$lang_name</option>"; + } + $selector .= "</select>"; + return $selector; +} + // // check_string // Action: checks if a string is valid and returns TRUE if this is the case. @@ -374,7 +407,20 @@ return $retval; } +/** + * safecookie + * @see safeget() + * @param String $param + * @param String $default (optional) + * @return String value from $_COOKIE[$param] or $default + */ +function safecookie ($param, $default="") { + $retval=$default; + if (isset($_COOKIE[$param])) $retval=$_COOKIE[$param]; + return $retval; +} + // // get_domain_properties // Action: Get all the properties of a domain. Added: trunk/languages/language.php =================================================================== --- trunk/languages/language.php (rev 0) +++ trunk/languages/language.php 2007-12-30 01:32:33 UTC (rev 280) @@ -0,0 +1,37 @@ +<?php if( !defined('POSTFIXADMIN') ) die( "This file cannot be used standalone." ); ?> +<?php +# List of supported languages +$supported_languages = array( + 'bg' => 'Български - Bulgarian', + 'ca' => 'Català - Catalan', + 'cn' => '中文 - Chinese simplified (gb2312)', + 'tw' => '中文 - Chinese traditional', + 'cs' => 'Česky - Czech', + 'da' => 'Dansk - Danish', + 'de' => 'Deutsch - German', + 'en' => 'English', + 'es' => 'Español - Spanish', + 'et' => 'Eesti - Estonian', + 'eu' => 'Euskara - Basque', + 'fi' => 'Suomi - Finnish', + 'fo' => 'Faroese', + 'fr' => 'Français - French', + 'hr' => 'Hrvatski - Croatian', + 'hu' => 'Magyar - Hungarian', + 'is' => 'Icelandic', + 'it' => 'Italiano - Italian', + 'lt' => 'Lietuvių - Lithuanian', + 'mk' => 'Macedonian - Macedonian', + 'nl' => 'Nederlands - Dutch', + 'nn' => 'Norsk - Norwegian', + 'pl' => 'Polski - Polish', + 'pt-br' => 'Português - Brazilian portuguese', + 'ru' => 'Русский - Russian', + 'sk' => 'Slovenčina - Slovak', + 'sl' => 'Slovenščina - Slovenian', + 'sv' => 'Svenska - Swedish', + 'tr' => 'Türkçe - Turkish', +); + +/* vim: set expandtab ft=php softtabstop=4 tabstop=4 shiftwidth=4: */ +?> Modified: trunk/login.php =================================================================== --- trunk/login.php 2007-12-29 21:11:54 UTC (rev 279) +++ trunk/login.php 2007-12-30 01:32:33 UTC (rev 280) @@ -25,6 +25,7 @@ * * fUsername * fPassword + * lang */ require_once('common.php'); @@ -54,7 +55,13 @@ $fPassword = ''; if (isset ($_POST['fUsername'])) $fUsername = escape_string ($_POST['fUsername']); if (isset ($_POST['fPassword'])) $fPassword = escape_string ($_POST['fPassword']); + $lang = safepost('lang'); + if ( $lang != check_language(0) ) { # only set cookie if language selection was changed + setcookie('lang', $lang, time() + 60*60*24*30); # language cookie, lifetime 30 days + # (language preference cookie is processed even if username and/or password are invalid) + } + $result = db_query ("SELECT password FROM $table_admin WHERE username='$fUsername' AND active='1'"); if ($result['rows'] == 1) { Modified: trunk/templates/login.php =================================================================== --- trunk/templates/login.php 2007-12-29 21:11:54 UTC (rev 279) +++ trunk/templates/login.php 2007-12-30 01:32:33 UTC (rev 280) @@ -14,6 +14,11 @@ <td><input class="flat" type="password" name="fPassword" /></td> </tr> <tr> + <td colspan="2"> + <?php echo language_selector(); ?> + </td> + </tr> + <tr> <td colspan="2" class="hlp_center"><input class="button" type="submit" name="submit" value="<?php print $PALANG['pLogin_button']; ?>" /></td> </tr> <tr> @@ -31,3 +36,4 @@ </script> </div> +<?php /* vim: set ft=php expandtab softtabstop=3 tabstop=3 shiftwidth=3: */ ?> Modified: trunk/templates/users_login.php =================================================================== --- trunk/templates/users_login.php 2007-12-29 21:11:54 UTC (rev 279) +++ trunk/templates/users_login.php 2007-12-30 01:32:33 UTC (rev 280) @@ -14,6 +14,11 @@ <td><input class="flat" type="password" name="fPassword" /></td> </tr> <tr> + <td colspan="2"> + <?php echo language_selector(); ?> + </td> + </tr> + <tr> <td colspan="2" class="hlp_center"><input class="button" type="submit" name="submit" value="<?php print $PALANG['pUsersLogin_button']; ?>" /></td> </tr> <tr> Modified: trunk/users/login.php =================================================================== --- trunk/users/login.php 2007-12-29 21:11:54 UTC (rev 279) +++ trunk/users/login.php 2007-12-30 01:32:33 UTC (rev 280) @@ -25,6 +25,7 @@ * * fUsername * fPassword + * lang */ require_once("../common.php"); @@ -41,7 +42,13 @@ { $fUsername = escape_string ($_POST['fUsername']); $fPassword = escape_string ($_POST['fPassword']); + $lang = safepost('lang'); + if ( $lang != check_language(0) ) { # only set cookie if language selection was changed + setcookie('lang', $lang, time() + 60*60*24*30); # language cookie, lifetime 30 days + # (language preference cookie is processed even if username and/or password are invalid) + } + $active = db_get_boolean(True); $query = "SELECT password FROM $table_mailbox WHERE username='$fUsername' AND active=$active"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2007-12-29 21:11:50
|
Revision: 279 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=279&view=rev Author: GingerDog Date: 2007-12-29 13:11:54 -0800 (Sat, 29 Dec 2007) Log Message: ----------- new .deb release Modified Paths: -------------- trunk/debian/changelog trunk/debian/files Modified: trunk/debian/changelog =================================================================== --- trunk/debian/changelog 2007-12-29 14:51:58 UTC (rev 278) +++ trunk/debian/changelog 2007-12-29 21:11:54 UTC (rev 279) @@ -1,3 +1,11 @@ +postfixadmin (2.2.0-1rc2) unstable; urgency=low + + * Improved CSS + * Improved upgrade procedure (should work for PGSQL) (see upgrade.php) + * Various bug fixes + + -- David Goodwin <dav...@pa...> Sat, 29 Dec 2007 21:14:00 +0000 + postfixadmin (2.2.0-1rc1) unstable; urgency=low * Initial Release (via dpkg) Modified: trunk/debian/files =================================================================== --- trunk/debian/files 2007-12-29 14:51:58 UTC (rev 278) +++ trunk/debian/files 2007-12-29 21:11:54 UTC (rev 279) @@ -1 +1 @@ -postfixadmin_2.2.0-1rc1_all.deb web optional +postfixadmin_2.2.0-1rc2_all.deb web optional This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2007-12-29 14:51:54
|
Revision: 278 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=278&view=rev Author: GingerDog Date: 2007-12-29 06:51:58 -0800 (Sat, 29 Dec 2007) Log Message: ----------- upgrade.php: fix pgsql isms - i..e check that fields exist before trying to remove them, likewise for tables; minor syntax fixes in upgrade etc; tested and works for me Modified Paths: -------------- trunk/upgrade.php Modified: trunk/upgrade.php =================================================================== --- trunk/upgrade.php 2007-12-29 13:51:19 UTC (rev 277) +++ trunk/upgrade.php 2007-12-29 14:51:58 UTC (rev 278) @@ -1,11 +1,53 @@ <?php require_once('common.php'); +// vim ts=4:sw=4:et # Note: run with upgrade.php?debug=1 to see all SQL error messages +/** + * Use this to check whether an object (Table, index etc) exists within a + * PostgreSQL database. + * @param String the object name + * @return boolean true if it exists + */ +function _pgsql_object_exists($name) { + $sql = "select relname from pg_class where relname = '$name'"; + $r = db_query($sql); + if($r['rows'] == 1) { + return true; + } + return false; +} +function _pgsql_field_exists($table, $field) { + $sql = ' + SELECT + a.attname, + pg_catalog.format_type(a.atttypid, a.atttypmod) AS "Datatype" + FROM + pg_catalog.pg_attribute a + WHERE + a.attnum > 0 + AND NOT a.attisdropped + AND a.attrelid = ( + SELECT c.oid + FROM pg_catalog.pg_class c + LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace + WHERE c.relname ~ ' . "'^($table)\$' + AND pg_catalog.pg_table_is_visible(c.oid) + ) + AND a.attname = '$field' "; + echo $sql; + $r = db_query($sql); + $row = db_row($r['result']); + if($row) { + return true; + } + return false; +} + if($CONF['database_type'] == 'pgsql') { // check if table already exists, if so, don't recreate it $r = db_query("SELECT relname FROM pg_class WHERE relname = 'config'"); @@ -236,8 +278,10 @@ $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN quota int(10) NOT NULL default '0' AFTER maxquota", TRUE); } -function upgrade_4_pgsql() { # PgSQL only -# changes between 2.1 and moving to sourceforge +/** + * Changes between 2.1 and moving to sf.net + */ +function upgrade_4_pgsql() { $table_domain = table_by_key('domain'); $table_admin = table_by_key('admin'); $table_alias = table_by_key('alias'); @@ -246,68 +290,89 @@ $table_mailbox = table_by_key('mailbox'); $table_vacation = table_by_key('vacation'); - $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN quota int NOT NULL default '0'"); + if(!_pgsql_field_exists($table_domain, 'quota')) { + $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN quota int NOT NULL default '0'"); + } $result = db_query_parsed("ALTER TABLE $table_domain ALTER COLUMN domain DROP DEFAULT"); - $result = db_query_parsed("CREATE INDEX domain_domain_active ON domain(domain,active)"); - - $result = db_query_parsed("ALTER TABLE $table_admin ALTER COLUMN domain DROP DEFAULT"); + if(!_pgsql_object_exists('domain_domain_active')) { + $result = db_query_parsed("CREATE INDEX domain_domain_active ON domain(domain,active)"); + } + + $result = db_query_parsed("ALTER TABLE $table_domain_admins ALTER COLUMN domain DROP DEFAULT"); $result = db_query_parsed("ALTER TABLE $table_alias ALTER COLUMN address DROP DEFAULT"); $result = db_query_parsed("ALTER TABLE $table_alias ALTER COLUMN domain DROP DEFAULT"); - $result = db_query_parsed("CREATE INDEX alias_address_active ON alias(address,active)"); + if(!_pgsql_object_exists('alias_address_active')) { + $result = db_query_parsed("CREATE INDEX alias_address_active ON alias(address,active)"); + } $result = db_query_parsed("ALTER TABLE $table_domain_admins ALTER COLUMN username DROP DEFAULT"); $result = db_query_parsed("ALTER TABLE $table_domain_admins ALTER COLUMN domain DROP DEFAULT"); - $result = db_query_parsed("BEGIN; + $result = db_query_parsed(" + BEGIN; ALTER TABLE $table_log RENAME COLUMN data TO data_old; ALTER TABLE $table_log ADD COLUMN data text NOT NULL default ''; UPDATE $table_log SET data = CAST(data_old AS text); ALTER TABLE $table_log DROP COLUMN data_old; - COMMIT;"); + COMMIT;"); - $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN username DROP DEFAULT"); - $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN domain DROP DEFAULT"); + $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN username DROP DEFAULT"); + $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN domain DROP DEFAULT"); - $result = db_query_parsed("BEGIN; - ALTER TABLE $table_mailbox RENAME COLUMN domain TO domain_old; - ALTER TABLE $table_mailbox ADD COLUMN domain TYPE varchar(255) REFERENCES domain (domain); - UPDATE $table_mailbox SET domain = domain_old; - ALTER TABLE $table_mailbox DROP COLUMN domain_old; - CREATE INDEX mailbox_username_active ON mailbox(username,active); - COMMIT;"); + $result = db_query_parsed(" + BEGIN; + ALTER TABLE $table_mailbox RENAME COLUMN domain TO domain_old; + ALTER TABLE $table_mailbox ADD COLUMN domain varchar(255) REFERENCES domain (domain); + UPDATE $table_mailbox SET domain = domain_old; + ALTER TABLE $table_mailbox DROP COLUMN domain_old; + COMMIT;" + ); + if(!_pgsql_object_exists('mailbox_username_active')) { + db_query_parsed('CREATE INDEX mailbox_username_active ON mailbox(username,active)'); + } - $result = db_query_parsed("ALTER TABLE $table_vacation ALTER COLUMN body SET DEFAULT ''"); - $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN cache"); + $result = db_query_parsed("ALTER TABLE $table_vacation ALTER COLUMN body SET DEFAULT ''"); + if(_pgsql_field_exists($table_vacation, 'cache')) { + $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN cache"); + } - $result = db_query_parsed("ALTER TABLE $table_vacation RENAME COLUMN domain to domain_old"); - $result = db_query_parsed("ALTER TABLE $table_vacation ADD COLUMN domain TYPE character varying(255) REFERENCES domain "); - $result = db_query_parsed("UPDATE $table_vacation SET domain = domain_old"); - $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN domain_old"); + $result = db_query_parsed(" + BEGIN; + ALTER TABLE $table_vacation RENAME COLUMN domain to domain_old; + ALTER TABLE $table_vacation ADD COLUMN domain varchar(255) REFERENCES domain; + UPDATE $table_vacation SET domain = domain_old; + ALTER TABLE $table_vacation DROP COLUMN domain_old; + COMMIT; + "); - $result = db_query_parsed("CREATE INDEX vacation_email_active ON vacation(email,active)"); + if(!_pgsql_object_exists('vacation_email_active')) { + $result = db_query_parsed("CREATE INDEX vacation_email_active ON vacation(email,active)"); + } - $result = db_query_parsed(" - CREATE TABLE vacation_notification ( - on_vacation character varying(255) NOT NULL REFERENCES vacation(email) ON DELETE CASCADE, - notified character varying(255) NOT NULL, - notified_at timestamp with time zone NOT NULL DEFAULT now(), - CONSTRAINT vacation_notification_pkey primary key(on_vacation,notified) - );"); + if(!_pgsql_object_exists('vacation_notification')) { + $result = db_query_parsed(" + CREATE TABLE vacation_notification ( + on_vacation character varying(255) NOT NULL REFERENCES vacation(email) ON DELETE CASCADE, + notified character varying(255) NOT NULL, + notified_at timestamp with time zone NOT NULL DEFAULT now(), + CONSTRAINT vacation_notification_pkey primary key(on_vacation,notified) + );"); + } +} - +/** + * drop useless indicies (already available as primary key) + */ +function upgrade_79_mysql() { # MySQL only + $result = db_query_parsed(_drop_index('admin', 'username'), True); + $result = db_query_parsed(_drop_index('alias', 'address'), True); + $result = db_query_parsed(_drop_index('domain', 'domain'), True); + $result = db_query_parsed(_drop_index('mailbox', 'username'), True); } - function upgrade_79_mysql() { # MySQL only -# drop useless indicies (already available as primary key) - $result = db_query_parsed(_drop_index('admin', 'username'), True); - $result = db_query_parsed(_drop_index('alias', 'address'), True); - $result = db_query_parsed(_drop_index('domain', 'domain'), True); - $result = db_query_parsed(_drop_index('mailbox', 'username'), True); - } - function upgrade_81_mysql() { # MySQL only $table_vacation = table_by_key ('vacation'); $table_vacation_notification = table_by_key('vacation_notification'); @@ -343,17 +408,19 @@ ); } +/** + * Make logging translatable - i.e. create alias => create_alias + */ function upgrade_90() { -# translatable logging -# old format: "create alias" -# new format: "create_alias" $result = db_query_parsed("UPDATE " . table_by_key ('log') . " SET action = REPLACE(action,' ','_')", TRUE); -# change edit_alias_state to edit_alias_active + # change edit_alias_state to edit_alias_active $result = db_query_parsed("UPDATE " . table_by_key ('log') . " SET action = 'edit_alias_state' WHERE action = 'edit_alias_active'", TRUE); } -function upgrade_169_mysql() { # MySQL only -# allow quota > 2 GB +/** + * MySQL only allow quota > 2 GB + */ +function upgrade_169_mysql() { $table_domain = table_by_key ('domain'); $table_mailbox = table_by_key ('mailbox'); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <Gin...@us...> - 2007-12-29 13:51:16
|
Revision: 277 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=277&view=rev Author: GingerDog Date: 2007-12-29 05:51:19 -0800 (Sat, 29 Dec 2007) Log Message: ----------- upgrade.php: should work for postgresql now Modified Paths: -------------- trunk/upgrade.php Modified: trunk/upgrade.php =================================================================== --- trunk/upgrade.php 2007-12-28 21:45:33 UTC (rev 276) +++ trunk/upgrade.php 2007-12-29 13:51:19 UTC (rev 277) @@ -4,20 +4,33 @@ # Note: run with upgrade.php?debug=1 to see all SQL error messages -# Not nice, but works: -# We don't know if the config table exists, so we simply try to create it ;-) -# Better solution (TODO): query the db to see if the 'config' table exists -$sql = " -CREATE TABLE {IF_NOT_EXISTS} " . table_by_key ('config') . "( - `id` {AUTOINCREMENT} {PRIMARY}, - `name` VARCHAR(20) {LATIN1} NOT NULL DEFAULT '', - `value` VARCHAR(20) {LATIN1} NOT NULL DEFAULT '', - UNIQUE name ( `name` ) -) -"; -db_query_parsed($sql, 0, " ENGINE = MYISAM COMMENT = 'PostfixAdmin settings'"); +if($CONF['database_type'] == 'pgsql') { + // check if table already exists, if so, don't recreate it + $r = db_query("SELECT relname FROM pg_class WHERE relname = 'config'"); + if($r['rows'] == 0) { + $pgsql = " + CREATE TABLE config ( + id SERIAL, + name VARCHAR(20) NOT NULL UNIQUE, + value VARCHAR(20) NOT NULL, + PRIMARY KEY(id) + )"; + db_query_parsed($pgsql); + } +} +else { + $mysql = " + CREATE TABLE {IF_NOT_EXISTS} " . table_by_key ('config') . "( + `id` {AUTOINCREMENT} {PRIMARY}, + `name` VARCHAR(20) {LATIN1} NOT NULL DEFAULT '', + `value` VARCHAR(20) {LATIN1} NOT NULL DEFAULT '', + UNIQUE name ( `name` ) + ) + "; + db_query_parsed($mysql, 0, " ENGINE = MYISAM COMMENT = 'PostfixAdmin settings'"); +} $sql = "SELECT * FROM config WHERE name = 'version'"; @@ -32,6 +45,7 @@ } else { $version = 0; } + _do_upgrade($version); @@ -40,7 +54,7 @@ $target_version = preg_replace('/[^0-9]/', '', '$Revision$'); if ($current_version >= $target_version) { - # already up to date +# already up to date echo "up to date"; return true; } @@ -69,15 +83,17 @@ echo " done"; } } - # TODO: update version in config table after each change - # TODO: this avoids problems in case the script hits the max_execution_time, - # TODO: simply rerunning it will continue where it was stopped + // Update config table so we don't run the same query twice in the future. + $i = (int) $i; + $sql = "UPDATE config SET value = $i WHERE name = 'version'"; + db_query($sql); }; } /** * Replaces database specific parts in a query * @param String sql query with placeholders + * @param int (optional) whether errors should be ignored (0=false) * @param String (optional) MySQL specific code to attach, useful for COMMENT= on CREATE TABLE * @return String sql query */ @@ -88,34 +104,34 @@ if ($CONF['database_type'] == 'mysql' || $CONF['database_type'] == 'mysqli' ) { $replace = array( - '{AUTOINCREMENT}' => 'int(11) not null auto_increment', - '{PRIMARY}' => 'primary key', - '{UNSIGNED}' => 'unsigned' , - '{FULLTEXT}' => 'FULLTEXT', - '{BOOLEAN}' => 'tinyint(1) NOT NULL', - '{UTF-8}' => '/*!40100 CHARACTER SET utf8 COLLATE utf8_unicode_ci */', - '{LATIN1}' => '/*!40100 CHARACTER SET latin1 COLLATE latin1_swedish_ci */', - '{IF_NOT_EXISTS}' => 'IF NOT EXISTS', - '{RENAME_COLUMN}' => 'CHANGE COLUMN', - ); + '{AUTOINCREMENT}' => 'int(11) not null auto_increment', + '{PRIMARY}' => 'primary key', + '{UNSIGNED}' => 'unsigned' , + '{FULLTEXT}' => 'FULLTEXT', + '{BOOLEAN}' => 'tinyint(1) NOT NULL', + '{UTF-8}' => '/*!40100 CHARACTER SET utf8 COLLATE utf8_unicode_ci */', + '{LATIN1}' => '/*!40100 CHARACTER SET latin1 COLLATE latin1_swedish_ci */', + '{IF_NOT_EXISTS}' => 'IF NOT EXISTS', + '{RENAME_COLUMN}' => 'CHANGE COLUMN', + ); $sql = "$sql $attach_mysql"; } elseif($CONF['database_type'] == 'pgsql') { $replace = array( - '{AUTOINCREMENT}' => 'SERIAL', - '{PRIMARY}' => 'primary key', - '{UNSIGNED}' => '', - '{FULLTEXT}' => '', - '{BOOLEAN}' => 'BOOLEAN NOT NULL', - '{UTF-8}' => '', # TODO: UTF-8 is simply ignored. - '{LATIN1}' => '', # TODO: same for latin1 - '{IF_NOT_EXISTS}' => '', # TODO: does this work with PgSQL? NO - '{RENAME_COLUMN}' => 'ALTER COLUMN', # PgSQL : ALTER TABLE x RENAME x TO y - 'int(1)' => 'int', - 'int(10)' => 'int', - 'int(11)' => 'int', - 'int(4)' => 'int', - ); + '{AUTOINCREMENT}' => 'SERIAL', + '{PRIMARY}' => 'primary key', + '{UNSIGNED}' => '', + '{FULLTEXT}' => '', + '{BOOLEAN}' => 'BOOLEAN NOT NULL', + '{UTF-8}' => '', # TODO: UTF-8 is simply ignored. + '{LATIN1}' => '', # TODO: same for latin1 + '{IF_NOT_EXISTS}' => '', # TODO: does this work with PgSQL? NO + '{RENAME_COLUMN}' => 'ALTER COLUMN', # PgSQL : ALTER TABLE x RENAME x TO y + 'int(1)' => 'int', + 'int(10)' => 'int', + 'int(11)' => 'int', + 'int(4)' => 'int', + ); } else { echo "Sorry, unsupported database type " . $conf['database_type']; @@ -149,20 +165,20 @@ } function upgrade_1() { - # inserting the version number is a good start ;-) +# inserting the version number is a good start ;-) db_insert( - 'config', - array( - 'name' => 'version', - 'value' => '1', - ) - ); + 'config', + array( + 'name' => 'version', + 'value' => '1', + ) + ); echo "upgrade_1"; } function upgrade_2_mysql() { - # upgrade pre-2.1 database - # from TABLE_BACKUP_MX.TXT +# upgrade pre-2.1 database +# from TABLE_BACKUP_MX.TXT $table_domain = table_by_key ('domain'); $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN transport VARCHAR(255) AFTER maxquota;", TRUE); // don't think PGSQL supports 'AFTER transport' @@ -173,12 +189,11 @@ $table_domain = table_by_key ('domain'); $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN transport VARCHAR(255)", TRUE); $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN backupmx BOOLEAN DEFAULT false", TRUE); - } function upgrade_3_mysql() { - # upgrade pre-2.1 database - # from TABLE_CHANGES.TXT +# upgrade pre-2.1 database +# from TABLE_CHANGES.TXT $table_admin = table_by_key ('admin'); $table_alias = table_by_key ('alias'); $table_domain = table_by_key ('domain'); @@ -188,41 +203,41 @@ // these will not work on PostgreSQL; syntax is : // ALTER TABLE foo RENAME f1 TO f2 $all_sql = split("\n", trim(" - ALTER TABLE $table_admin {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_admin {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_alias {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_alias {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_domain {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_domain {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_domain ADD COLUMN aliases INT(10) DEFAULT '-1' NOT NULL AFTER description; - ALTER TABLE $table_domain ADD COLUMN mailboxes INT(10) DEFAULT '-1' NOT NULL AFTER aliases; - ALTER TABLE $table_domain ADD COLUMN maxquota INT(10) DEFAULT '-1' NOT NULL AFTER mailboxes; - ALTER TABLE $table_domain ADD COLUMN transport VARCHAR(255) AFTER maxquota; - ALTER TABLE $table_domain ADD COLUMN backupmx TINYINT(1) DEFAULT '0' NOT NULL AFTER transport; - ALTER TABLE $table_mailbox {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_mailbox {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; - ALTER TABLE $table_mailbox ADD COLUMN quota INT(10) DEFAULT '-1' NOT NULL AFTER maildir; - ALTER TABLE $table_vacation ADD COLUMN domain VARCHAR(255) DEFAULT '' NOT NULL AFTER cache; - ALTER TABLE $table_vacation ADD COLUMN created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL AFTER domain; - ALTER TABLE $table_vacation ADD COLUMN active TINYINT(1) DEFAULT '1' NOT NULL AFTER created; - ALTER TABLE $table_vacation DROP PRIMARY KEY - ALTER TABLE $table_vacation ADD PRIMARY KEY(email) - UPDATE $table_vacation SET domain=SUBSTRING_INDEX(email, '@', -1) WHERE email=email; - ")); + ALTER TABLE $table_admin {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_admin {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_alias {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_alias {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_domain {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_domain {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_domain ADD COLUMN aliases INT(10) DEFAULT '-1' NOT NULL AFTER description; + ALTER TABLE $table_domain ADD COLUMN mailboxes INT(10) DEFAULT '-1' NOT NULL AFTER aliases; + ALTER TABLE $table_domain ADD COLUMN maxquota INT(10) DEFAULT '-1' NOT NULL AFTER mailboxes; + ALTER TABLE $table_domain ADD COLUMN transport VARCHAR(255) AFTER maxquota; + ALTER TABLE $table_domain ADD COLUMN backupmx TINYINT(1) DEFAULT '0' NOT NULL AFTER transport; + ALTER TABLE $table_mailbox {RENAME_COLUMN} create_date created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_mailbox {RENAME_COLUMN} change_date modified DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL; + ALTER TABLE $table_mailbox ADD COLUMN quota INT(10) DEFAULT '-1' NOT NULL AFTER maildir; + ALTER TABLE $table_vacation ADD COLUMN domain VARCHAR(255) DEFAULT '' NOT NULL AFTER cache; + ALTER TABLE $table_vacation ADD COLUMN created DATETIME DEFAULT '0000-00-00 00:00:00' NOT NULL AFTER domain; + ALTER TABLE $table_vacation ADD COLUMN active TINYINT(1) DEFAULT '1' NOT NULL AFTER created; + ALTER TABLE $table_vacation DROP PRIMARY KEY + ALTER TABLE $table_vacation ADD PRIMARY KEY(email) + UPDATE $table_vacation SET domain=SUBSTRING_INDEX(email, '@', -1) WHERE email=email; + ")); - foreach ($all_sql as $sql) { - $result = db_query_parsed($sql, TRUE); - } + foreach ($all_sql as $sql) { + $result = db_query_parsed($sql, TRUE); + } } function upgrade_4_mysql() { # MySQL only - # changes between 2.1 and moving to sourceforge +# changes between 2.1 and moving to sourceforge $table_domain = table_by_key ('domain'); $result = db_query_parsed("ALTER TABLE $table_domain ADD COLUMN quota int(10) NOT NULL default '0' AFTER maxquota", TRUE); } function upgrade_4_pgsql() { # PgSQL only - # changes between 2.1 and moving to sourceforge +# changes between 2.1 and moving to sourceforge $table_domain = table_by_key('domain'); $table_admin = table_by_key('admin'); $table_alias = table_by_key('alias'); @@ -247,98 +262,98 @@ $result = db_query_parsed("BEGIN; ALTER TABLE $table_log RENAME COLUMN data TO data_old; - ALTER TABLE $table_log ADD COLUMN data TYPE text NOT NULL default ''; + ALTER TABLE $table_log ADD COLUMN data text NOT NULL default ''; UPDATE $table_log SET data = CAST(data_old AS text); ALTER TABLE $table_log DROP COLUMN data_old; COMMIT;"); - $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN username DROP DEFAULT"); - $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN domain DROP DEFAULT"); + $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN username DROP DEFAULT"); + $result = db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN domain DROP DEFAULT"); - $result = db_query_parsed("BEGIN; - ALTER TABLE $table_mailbox RENAME COLUMN domain TO domain_old; - ALTER TABLE $table_mailbox ADD COLUMN domain TYPE varchar(255) REFERENCES domain (domain); - UPDATE $table_mailbox SET domain = domain_old; - ALTER TABLE $table_mailbox DROP COLUMN domain_old; - CREATE INDEX mailbox_username_active ON mailbox(username,active); - COMMIT;"); + $result = db_query_parsed("BEGIN; + ALTER TABLE $table_mailbox RENAME COLUMN domain TO domain_old; + ALTER TABLE $table_mailbox ADD COLUMN domain TYPE varchar(255) REFERENCES domain (domain); + UPDATE $table_mailbox SET domain = domain_old; + ALTER TABLE $table_mailbox DROP COLUMN domain_old; + CREATE INDEX mailbox_username_active ON mailbox(username,active); + COMMIT;"); - $result = db_query_parsed("ALTER TABLE $table_vacation ALTER COLUMN body SET DEFAULT = ''"); - $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN cache"); + $result = db_query_parsed("ALTER TABLE $table_vacation ALTER COLUMN body SET DEFAULT ''"); + $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN cache"); - $result = db_query_parsed("ALTER TABLE $table_vacation RENAME COLUMN domain to domain_old"); - $result = db_query_parsed("ALTER TABLE $table_vacation ADD COLUMN domain TYPE character varying(255) REFERENCES domain "); - $result = db_query_parsed("UPDATE $table_vacation SET domain = domain_old"); - $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN domain_old"); + $result = db_query_parsed("ALTER TABLE $table_vacation RENAME COLUMN domain to domain_old"); + $result = db_query_parsed("ALTER TABLE $table_vacation ADD COLUMN domain TYPE character varying(255) REFERENCES domain "); + $result = db_query_parsed("UPDATE $table_vacation SET domain = domain_old"); + $result = db_query_parsed("ALTER TABLE $table_vacation DROP COLUMN domain_old"); - $result = db_query_parsed("CREATE INDEX vacation_email_active ON vacation(email,active)"); + $result = db_query_parsed("CREATE INDEX vacation_email_active ON vacation(email,active)"); - $result = db_query_parsed(" -CREATE TABLE vacation_notification ( - on_vacation character varying(255) NOT NULL REFERENCES vacation(email) ON DELETE CASCADE, - notified character varying(255) NOT NULL, - notified_at timestamp with time zone NOT NULL DEFAULT now(), - CONSTRAINT vacation_notification_pkey primary key(on_vacation,notified) -);"); + $result = db_query_parsed(" + CREATE TABLE vacation_notification ( + on_vacation character varying(255) NOT NULL REFERENCES vacation(email) ON DELETE CASCADE, + notified character varying(255) NOT NULL, + notified_at timestamp with time zone NOT NULL DEFAULT now(), + CONSTRAINT vacation_notification_pkey primary key(on_vacation,notified) + );"); } -function upgrade_79_mysql() { # MySQL only - # drop useless indicies (already available as primary key) - $result = db_query_parsed(_drop_index('admin', 'username'), True); - $result = db_query_parsed(_drop_index('alias', 'address'), True); - $result = db_query_parsed(_drop_index('domain', 'domain'), True); - $result = db_query_parsed(_drop_index('mailbox', 'username'), True); -} + function upgrade_79_mysql() { # MySQL only +# drop useless indicies (already available as primary key) + $result = db_query_parsed(_drop_index('admin', 'username'), True); + $result = db_query_parsed(_drop_index('alias', 'address'), True); + $result = db_query_parsed(_drop_index('domain', 'domain'), True); + $result = db_query_parsed(_drop_index('mailbox', 'username'), True); + } function upgrade_81_mysql() { # MySQL only $table_vacation = table_by_key ('vacation'); $table_vacation_notification = table_by_key('vacation_notification'); $all_sql = split("\n", trim(" - ALTER TABLE `$table_vacation` CHANGE `email` `email` VARCHAR( 255 ) {LATIN1} NOT NULL - ALTER TABLE `$table_vacation` CHANGE `subject` `subject` VARCHAR( 255 ) {UTF-8} NOT NULL - ALTER TABLE `$table_vacation` CHANGE `body` `body` TEXT {UTF-8} NOT NULL - ALTER TABLE `$table_vacation` CHANGE `cache` `cache` TEXT {LATIN1} NOT NULL - ALTER TABLE `$table_vacation` CHANGE `domain` `domain` VARCHAR( 255 ) {LATIN1} NOT NULL - ALTER TABLE `$table_vacation` CHANGE `active` `active` TINYINT( 1 ) NOT NULL DEFAULT '1' - ALTER TABLE `$table_vacation` DEFAULT {LATIN1} - ALTER TABLE `$table_vacation` ENGINE = INNODB - ")); + ALTER TABLE `$table_vacation` CHANGE `email` `email` VARCHAR( 255 ) {LATIN1} NOT NULL + ALTER TABLE `$table_vacation` CHANGE `subject` `subject` VARCHAR( 255 ) {UTF-8} NOT NULL + ALTER TABLE `$table_vacation` CHANGE `body` `body` TEXT {UTF-8} NOT NULL + ALTER TABLE `$table_vacation` CHANGE `cache` `cache` TEXT {LATIN1} NOT NULL + ALTER TABLE `$table_vacation` CHANGE `domain` `domain` VARCHAR( 255 ) {LATIN1} NOT NULL + ALTER TABLE `$table_vacation` CHANGE `active` `active` TINYINT( 1 ) NOT NULL DEFAULT '1' + ALTER TABLE `$table_vacation` DEFAULT {LATIN1} + ALTER TABLE `$table_vacation` ENGINE = INNODB + ")); foreach ($all_sql as $sql) { $result = db_query_parsed($sql, TRUE); } db_query_parsed( - " CREATE TABLE {IF_NOT_EXISTS} $table_vacation_notification ( - on_vacation varchar(255) NOT NULL, - notified varchar(255) NOT NULL, - notified_at timestamp NOT NULL default now(), - CONSTRAINT vacation_notification_pkey PRIMARY KEY(on_vacation, notified), - FOREIGN KEY (on_vacation) REFERENCES vacation(email) ON DELETE CASCADE - ) - ", - TRUE, - " ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci TYPE=InnoDB + " CREATE TABLE {IF_NOT_EXISTS} $table_vacation_notification ( + on_vacation varchar(255) NOT NULL, + notified varchar(255) NOT NULL, + notified_at timestamp NOT NULL default now(), + CONSTRAINT vacation_notification_pkey PRIMARY KEY(on_vacation, notified), + FOREIGN KEY (on_vacation) REFERENCES vacation(email) ON DELETE CASCADE + ) + ", + TRUE, + " ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci TYPE=InnoDB COMMENT='Postfix Admin - Virtual Vacation Notifications' - " - ); + " + ); } function upgrade_90() { - # translatable logging - # old format: "create alias" - # new format: "create_alias" +# translatable logging +# old format: "create alias" +# new format: "create_alias" $result = db_query_parsed("UPDATE " . table_by_key ('log') . " SET action = REPLACE(action,' ','_')", TRUE); - # change edit_alias_state to edit_alias_active +# change edit_alias_state to edit_alias_active $result = db_query_parsed("UPDATE " . table_by_key ('log') . " SET action = 'edit_alias_state' WHERE action = 'edit_alias_active'", TRUE); } function upgrade_169_mysql() { # MySQL only - # allow quota > 2 GB +# allow quota > 2 GB $table_domain = table_by_key ('domain'); $table_mailbox = table_by_key ('mailbox'); @@ -349,20 +364,19 @@ /* -TODO + TODO Database changes that should be done: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ MySQL: -* vacation: - - DROP INDEX email - - 'cache' field might be obsolete with vacation_notification - needs to be checked! -* vacation_notification: - - DEFAULT CHARSET and COLLATE should be changed - - change all varchar fields to latin1 (email addresses don't contain utf8 characters) + * vacation: + - DROP INDEX email + - 'cache' field might be obsolete with vacation_notification - needs to be checked! + * vacation_notification: + - DEFAULT CHARSET and COLLATE should be changed + - change all varchar fields to latin1 (email addresses don't contain utf8 characters) -*/ + */ -/* vim: set expandtab softtabstop=4 tabstop=4 shiftwidth=4: */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |