]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/what-config_mediadata.php
www is out-dated
[mailer.git] / inc / modules / admin / what-config_mediadata.php
index 45ff327457a7fb03bb9e765f686c575faf0c1cd2..132897acc43b233d222a9d836e817abcab28fa98 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 /************************************************************************
- * MXChange v0.2.1                                    Start: 09/28/2003 *
- * ================                             Last change: 02/12/2004 *
+ * Mailer v0.2.1-FINAL                                Start: 09/28/2003 *
+ * ===================                          Last change: 02/12/2004 *
  *                                                                      *
  * -------------------------------------------------------------------- *
  * File              : what-                                            *
  * $Date::                                                            $ *
  * $Tag:: 0.2.1-FINAL                                                 $ *
  * $Author::                                                          $ *
- * Needs to be in all Files and every File needs "svn propset           *
- * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
  * -------------------------------------------------------------------- *
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *
- * For more information visit: http://www.mxchange.org                  *
+ * Copyright (c) 2003 - 2009 by Roland Haeder                           *
+ * Copyright (c) 2009 - 2011 by Mailer Developer Team                   *
+ * For more information visit: http://mxchange.org                      *
  *                                                                      *
  * This program is free software; you can redistribute it and/or modify *
  * it under the terms of the GNU General Public License as published by *
  ************************************************************************/
 
 // Some security stuff...
-if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
-       require($INC);
-}
+if ((!defined('__SECURITY')) || (!isAdmin())) {
+       die();
+} // END - if
 
 // Add description as navigation point
-ADD_DESCR('admin', __FILE__);
+addYouAreHereLink('admin', __FILE__);
 
 if (isFormSent()) {
        // Test timestamp
-       $STAMP = mktime(0, 0, 0, bigintval(REQUEST_POST('month')), bigintval(REQUEST_POST('day')), bigintval(REQUEST_POST('year')));
+       $STAMP = mktime(0, 0, 0, bigintval(postRequestElement('month')), bigintval(postRequestElement('day')), bigintval(postRequestElement('year')));
        if ($STAMP > time()) {
                // Date is in the future!
-               REQUEST_UNSET_POST('ok');
+               unsetPostRequestElement('ok');
        } else {
                // Remove entries
-               REQUEST_UNSET_POST('day');
-               REQUEST_UNSET_POST('month');
-               REQUEST_UNSET_POST('year');
+               unsetPostRequestElement('day');
+               unsetPostRequestElement('month');
+               unsetPostRequestElement('year');
 
                // Remember timestamp
-               REQUEST_SET_POST('mt_start', $STAMP);
+               setPostRequestElement('mt_start', $STAMP);
        }
 
        // Convert some data
-       REQUEST_SET_POST('mt_stage', bigintval(REQUEST_POST('mt_stage')));
-       if (REQUEST_POST('mt_stage') <= GET_TOTAL_DATA('CONFIRMED', 'user_data', 'userid', 'status', true)) {
+       setPostRequestElement('mt_stage', bigintval(postRequestElement('mt_stage')));
+       if (postRequestElement('mt_stage') <= getTotalConfirmedUser()) {
                // Not enougth!
-               REQUEST_UNSET_POST('ok');
-       }
-}
+               unsetPostRequestElement('ok');
+       } // END - if
+} // END - if
 
 if (isFormSent()) {
        // Save data
-       ADMIN_SAVE_SETTINGS_POST();
+       adminSaveSettingsFromPostData();
 } else {
        // Start of this exchange
        if (getConfig('mt_start') > 0) {
                // Only show start
-               define('__MT_START', '<strong>' . generateDateTime(getConfig('mt_start'), '3') . '</strong>');
+               $content['mt_start'] = '<strong>' . generateDateTime(getConfig('mt_start'), 3) . '</strong>';
        } else {
                // Make start editable
-               define('__MT_START',
-                       ADD_SELECTION('day'  , date('d', time())).
-                       ADD_SELECTION('month', date('m', time())).
-                       ADD_SELECTION('year',  -1)
-               );
+               $content['mt_start'] =
+                       addSelectionBox('day'  , getDay()).
+                       addSelectionBox('month', getMonth()).
+                       addSelectionBox('year',  -1)
+               ;
        }
 
-       // Next stage of this MT
-       define('__MT_STAGE', getConfig('mt_stage'));
-
        // Load template
-       LOAD_TEMPLATE('admin_config_mediadata');
+       loadTemplate('admin_config_mediadata', false, $content);
 }
 
 //