6 * Copyright (c) 1999-2005 The SquirrelMail Project Team
7 * Licensed under the GNU GPL. For full terms see the file COPYING.
11 * @subpackage listcommands
15 define('SM_PATH','../../');
17 /* SquirrelMail required files. */
18 require_once(SM_PATH
. 'include/validate.php');
19 include_once(SM_PATH
. 'functions/page_header.php');
20 include_once(SM_PATH
. 'include/load_prefs.php');
21 include_once(SM_PATH
. 'functions/html.php');
22 require_once(SM_PATH
. 'functions/identity.php');
23 require_once(SM_PATH
. 'functions/forms.php');
24 include_once(SM_PATH
. 'plugins/listcommands/functions.php');
27 sqgetGlobalVar('mailbox', $mailbox, SQ_GET
);
28 sqgetGlobalVar('send_to', $send_to, SQ_GET
);
29 sqgetGlobalVar('subject', $subject, SQ_GET
);
30 sqgetGlobalVar('body', $body, SQ_GET
);
31 sqgetGlobalVar('action', $action, SQ_GET
);
33 displayPageHeader($color, $mailbox);
34 $fieldsdescr = listcommands_fieldsdescr();
38 $out_string = _("This will send a message to %s requesting help for this list. You will receive an emailed response at the address below.");
41 $out_string = _("This will send a message to %s requesting that you will be subscribed to this list. You will be subscribed with the address below.");
44 $out_string = _("This will send a message to %s requesting that you will be unsubscribed from this list. It will try to unsubscribe the adress below.");
47 error_box(sprintf(_("Unknown action: %s"),htmlspecialchars($action)), $color);
51 echo html_tag('p', '', 'left' ) .
52 html_tag( 'table', '', 'center', $color[0], 'border="0" width="75%"' ) . "\n" .
54 html_tag( 'th', _("Mailinglist") . ': ' . $fieldsdescr[$action], '', $color[9] )
57 html_tag( 'td', '', 'left' );
59 printf($out_string, '"' . htmlspecialchars($send_to) . '"');
61 echo addForm(SM_PATH
. 'src/compose.php', 'post');
63 $idents = get_identities();
65 echo html_tag('p', '', 'center' ) . _("From:") . ' ';
67 if (count($idents) > 1) {
68 echo '<select name="identity">';
69 foreach($idents as $nr=>$data) {
70 echo '<option value="' . $nr . '">' .
72 $data['full_name'].' <'.
73 $data['email_address'] . ">\n");
75 echo '</select>' . "\n" ;
77 echo htmlspecialchars('"'.$idents[0]['full_name'].'" <'.$idents[0]['email_address'].'>');
81 addHidden('send_to', $send_to) .
82 addHidden('subject', $subject) .
83 addHidden('body', $body) .
84 addHidden('mailbox', $mailbox) .
85 addSubmit(_("Send Mail"), 'send');
88 </form
></td
></tr
></table
></p
></body
></html
>