diff options
Diffstat (limited to 'views')
-rw-r--r-- | views/default/admin/plugin_settings.php | 3 | ||||
-rw-r--r-- | views/default/core/settings/tools.php | 12 | ||||
-rw-r--r-- | views/default/forms/plugins/settings/save.php | 7 |
3 files changed, 16 insertions, 6 deletions
diff --git a/views/default/admin/plugin_settings.php b/views/default/admin/plugin_settings.php index c2801cec3..7473768c0 100644 --- a/views/default/admin/plugin_settings.php +++ b/views/default/admin/plugin_settings.php @@ -14,8 +14,9 @@ $plugin_id = $plugin->getID(); // required for plugin settings backward compatibility $vars['entity'] = $plugin; -if (elgg_view_exists("settings/$plugin_id/edit")) { +$settings = false; +if (elgg_view_exists("settings/$plugin_id/edit") || elgg_view_exists("plugins/$plugin_id/settings")) { $title = $plugin->manifest->getName(); $params = array('id' => "$plugin_id-settings"); diff --git a/views/default/core/settings/tools.php b/views/default/core/settings/tools.php index 3836b7ef1..ff02c9183 100644 --- a/views/default/core/settings/tools.php +++ b/views/default/core/settings/tools.php @@ -25,9 +25,13 @@ $count = count($installed_plugins); // Display all plugins' usersettings forms foreach ($installed_plugins as $plugin) { $plugin_id = $plugin->getID(); - if ($plugin->isActive() && elgg_view_exists("usersettings/$plugin_id/edit")) { - $title = $plugin->manifest->getName(); - $body = elgg_view_form('plugins/usersettings/save', array(), array('entity' => $plugin)); - echo elgg_view_module('info', $title, $body); + if ($plugin->isActive()) { + if (elgg_view_exists("usersettings/$plugin_id/edit") + || elgg_view_exists("plugins/$plugin_id/usersettings")) { + + $title = $plugin->manifest->getName(); + $body = elgg_view_form('plugins/usersettings/save', array(), array('entity' => $plugin)); + echo elgg_view_module('info', $title, $body); + } } }
\ No newline at end of file diff --git a/views/default/forms/plugins/settings/save.php b/views/default/forms/plugins/settings/save.php index 5125f3142..efe6d7792 100644 --- a/views/default/forms/plugins/settings/save.php +++ b/views/default/forms/plugins/settings/save.php @@ -17,7 +17,12 @@ if ($type != 'user') { $type = ''; } -echo elgg_view("{$type}settings/$plugin_id/edit", $vars); +if (elgg_view_exists("{$type}settings/$plugin_id/edit")) { + elgg_deprecated_notice("{$type}settings/$plugin_id/edit was deprecated in favor of plugins/$plugin_id/{$type}settings", 1.8); + echo elgg_view("{$type}settings/$plugin_id/edit", $vars); +} else { + echo elgg_view("plugins/$plugin_id/{$type}settings", $vars); +} echo "<div>"; echo elgg_view('input/hidden', array('name' => 'plugin_id', 'value' => $plugin_id)); |