]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/what-config_yoomedia.php
Even more double->single converted
[mailer.git] / inc / modules / admin / what-config_yoomedia.php
index a4beb41cd27db0be3c21b15f1731fdf5f1f5d710..6a3dcbb07ded89248be68298182d277c360b6b32 100644 (file)
@@ -8,17 +8,16 @@
  * -------------------------------------------------------------------- *
  * Short description : Setup default statistics mode                    *
  * -------------------------------------------------------------------- *
- * Kurzbeschreibung  : Standart Modus der Statistiken einstellen        *
+ * Kurzbeschreibung  : Standard Modus der Statistiken einstellen        *
  * -------------------------------------------------------------------- *
  * $Revision::                                                        $ *
  * $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 - 2009 by Roland Haeder                           *
- * For more information visit: http://www.mxchange.org                  *
+ * Copyright (c) 2009 - 2013 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 *
@@ -42,36 +41,29 @@ if ((!defined('__SECURITY')) || (!isAdmin())) {
 } // END - if
 
 // Add description as navigation point
-addMenuDescription('admin', __FILE__);
-
-if (!isExtensionActive('yoomedia')) {
-       loadTemplate('admin_settings_saved', false, generateExtensionInactiveNotInstalledMessage('yoomedia'));
-       return;
-} // END - if
+addYouAreHereLink('admin', __FILE__);
 
 // Was the form submitted?
-if (isFormSent()) {
+if (isFormSent('save_config')) {
        // Test Yoo!Media config
        if (YOOMEDIA_TEST_CONFIG(postRequestArray())) {
                // Save settings
                adminSaveSettingsFromPostData();
        } else {
                // Config not saved
-               loadTemplate('admin_settings_saved', false, getMessage('ADMIN_CONFIG_YOOMEDIA_TEST_FAILED'));
+               displayMessage('{--ADMIN_CONFIG_YOOMEDIA_TEST_FAILED--}');
        }
 } else {
        // Erotic selection
-       for ($idx = '0'; $idx <= 2; $idx++) {
+       for ($idx = 0; $idx <= 2; $idx++) {
                $content['yoomedia_erotic_allowed_' . $idx] = '';
        } // END - for
 
        // Set default selection
-       foreach (array('yoomedia_erotic_allowed') as $entry) {
-               $content[$entry . '_' . strtolower(getConfig($entry))] = ' selected="selected"';
-       } // END - foreach
+       $content = merge_array($content, getSelectedConfig(array('yoomedia_erotic_allowed')));
 
        // Load template
-       loadTemplate('admin_config_yoomedia', false, $content);
+       loadTemplate('admin_config_yoomedia', FALSE, $content);
 }
 
 // [EOF]