source: subversion/trunk/roundcubemail/program/steps/mail/sendmdn.inc @ 5787

Last change on this file since 5787 was 5787, checked in by thomasb, 16 months ago

Changed license to GNU GPLv3+ with exceptions for skins and plugins

  • Property svn:keywords set to Author Date Id Revision
File size: 1.7 KB
Line 
1<?php
2
3/*
4 +-----------------------------------------------------------------------+
5 | program/steps/mail/sendmdn.inc                                        |
6 |                                                                       |
7 | This file is part of the Roundcube Webmail client                     |
8 | Copyright (C) 2008-2009, The Roundcube Dev Team                       |
9 |                                                                       |
10 | Licensed under the GNU General Public License version 3 or            |
11 | any later version with exceptions for skins & plugins.                |
12 | See the README file for a full license statement.                     |
13 |                                                                       |
14 | PURPOSE:                                                              |
15 |   Send a message disposition notification for a specific mail         |
16 |                                                                       |
17 +-----------------------------------------------------------------------+
18 | Author: Thomas Bruederli <roundcube@gmail.com>                        |
19 +-----------------------------------------------------------------------+
20
21 $Id$
22
23*/
24
25// only process ajax requests
26if (!$OUTPUT->ajax_call)
27  return;
28
29if (!empty($_POST['_uid'])) {
30  $sent = rcmail_send_mdn(get_input_value('_uid', RCUBE_INPUT_POST), $smtp_error);
31}
32
33// show either confirm or error message
34if ($sent) {
35  $OUTPUT->set_env('mdn_request', false);
36  $OUTPUT->show_message('receiptsent', 'confirmation');
37}
38else if ($smtp_error) {
39  $OUTPUT->show_message($smtp_error['label'], 'error', $smtp_error['vars']);
40}
41else {
42  $OUTPUT->show_message('errorsendingreceipt', 'error');
43}
44
45$OUTPUT->send();
Note: See TracBrowser for help on using the repository browser.