'what' files should be loaded only once
[mailer.git] / inc / modules / guest / action-sponsor.php
1 <?php
2 /************************************************************************
3  * Mailer v0.2.1-FINAL                                Start: 06/10/2005 *
4  * ===================                          Last change: 05/18/2008 *
5  *                                                                      *
6  * -------------------------------------------------------------------- *
7  * File              : action-sponsor.php                               *
8  * -------------------------------------------------------------------- *
9  * Short description : Sponsor area                                     *
10  * -------------------------------------------------------------------- *
11  * Kurzbeschreibung  : Sponsorenbereich                                 *
12  * -------------------------------------------------------------------- *
13  * $Revision::                                                        $ *
14  * $Date::                                                            $ *
15  * $Tag:: 0.2.1-FINAL                                                 $ *
16  * $Author::                                                          $ *
17  * -------------------------------------------------------------------- *
18  * Copyright (c) 2003 - 2009 by Roland Haeder                           *
19  * Copyright (c) 2009 - 2011 by Mailer Developer Team                   *
20  * For more information visit: http://mxchange.org                      *
21  *                                                                      *
22  * This program is free software. You can redistribute it and/or modify *
23  * it under the terms of the GNU General Public License as published by *
24  * the Free Software Foundation; either version 2 of the License.       *
25  *                                                                      *
26  * This program is distributed in the hope that it will be useful,      *
27  * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
28  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
29  * GNU General Public License for more details.                         *
30  *                                                                      *
31  * You should have received a copy of the GNU General Public License    *
32  * along with this program; if not, write to the Free Software          *
33  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
34  * MA  02110-1301  USA                                                  *
35  ************************************************************************/
36
37 // Some security stuff...
38 if (!defined('__SECURITY')) {
39         die();
40 } elseif (isBlockModeEnabled()) {
41         // Block mode detected
42         return;
43 }
44
45 // Add description as navigation point
46 addYouAreHereLink('guest', __FILE__);
47
48 if ((!isExtensionActive('sponsor')) && (!isAdmin())) {
49         displayMessage('{%pipe,generateExtensionInactiveNotInstalledMessage=sponsor%}');
50         return;
51 } // END - if
52
53 // Load the include file
54 $inc = sprintf("inc/modules/guest/what-%s.php", getWhat());
55 if (isIncludeReadable($inc)) {
56         // Ok, we finally load the guest action module
57         loadIncludeOnce($inc);
58 } else {
59         addFatalMessage(__FILE__, __LINE__, '{--GUEST_WHAT_404--}');
60 }
61
62 // [EOF]
63 ?>