aboutsummaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
Diffstat (limited to 'views')
-rw-r--r--views/default/object/plugin.php2
-rw-r--r--views/default/usersettings/plugins.php14
-rw-r--r--views/default/usersettings/plugins_opt/plugin.php18
3 files changed, 11 insertions, 23 deletions
diff --git a/views/default/object/plugin.php b/views/default/object/plugin.php
index aaa5d6681..2c70476df 100644
--- a/views/default/object/plugin.php
+++ b/views/default/object/plugin.php
@@ -14,7 +14,7 @@
$plugin = $vars['plugin'];
$prefix = $vars['prefix']; // Do we want to show admin settings (default) or user settings
- $form_body = elgg_view("{$prefix}settings/{$plugin}/edit",$vars);
+ $form_body = elgg_view("{$prefix}settings/{$plugin}/edit", $vars);
$form_body .= "<p>" . elgg_view('input/hidden', array('internalname' => 'plugin', 'value' => $plugin)) . elgg_view('input/submit', array('value' => elgg_echo('save'))) . "</p>";
diff --git a/views/default/usersettings/plugins.php b/views/default/usersettings/plugins.php
index 3daf16733..321f377ce 100644
--- a/views/default/usersettings/plugins.php
+++ b/views/default/usersettings/plugins.php
@@ -16,7 +16,6 @@
$limit = get_input('limit', 10);
$offset = get_input('offset', 0);
-
// Get the installed plugins
$installed_plugins = $vars['installed_plugins'];
$count = count($installed_plugins);
@@ -25,19 +24,10 @@
$n = 0;
foreach ($installed_plugins as $plugin => $data)
{
- if (($n>=$offset) && ($n < $offset+$limit))
+ if (is_plugin_enabled($plugin))
echo elgg_view("usersettings/plugins_opt/plugin", array('plugin' => $plugin, 'details' => $data));
- $n++;
}
- // Diplay nav
- if ($count)
- {
- echo elgg_view('navigation/pagination',array(
- 'baseurl' => $_SERVER['REQUEST_URI'],
- 'offset' => $offset,
- 'count' => $count,
- ));
- }
+
?> \ No newline at end of file
diff --git a/views/default/usersettings/plugins_opt/plugin.php b/views/default/usersettings/plugins_opt/plugin.php
index 51948b41f..1c02ff97a 100644
--- a/views/default/usersettings/plugins_opt/plugin.php
+++ b/views/default/usersettings/plugins_opt/plugin.php
@@ -22,21 +22,19 @@
$user_guid = $details['user_guid'];
if ($user_guid) $user_guid = $_SESSION['user']->guid;
+
+ if (elgg_view("usersettings/{$plugin}/edit")) {
?>
-<div id="plugin_details" class="<?php if ($active) echo "active"; else "not-active" ?>">
+<div id="user_plugin_details">
<div><h2><?php echo $plugin; ?></h2></div>
<?php if ($manifest) { ?>
<div><?php echo $manifest['description'] ?></div>
<div><?php echo elgg_echo('admin:plugins:label:author') . ": ". $manifest['author'] ?></div>
- <div><?php echo elgg_echo('admin:plugins:label:copyright') . ": ". $manifest['copyright'] ?></div>
- <div><?php echo elgg_echo('admin:plugins:label:licence') . ": ". $manifest['licence'] ?></div>
- <div><?php echo elgg_echo('admin:plugins:label:website') . ": "; ?><a href="<?php echo $manifest['website']; ?>"><?php echo $manifest['website']; ?></a></div>
<?php } ?>
- <?php if (elgg_view("usersettings/{$plugin}/edit")) { ?>
- <div id="<?php echo $plugin; ?>_settings">
- <?php echo elgg_view("object/plugin", array('plugin' => $plugin, 'entity' => find_plugin_usersettings($plugin, $user_guid), 'prefix' => 'user')) ?>
- </div>
- <?php } ?>
-</div> \ No newline at end of file
+ <div id="<?php echo $plugin; ?>_settings">
+ <?php echo elgg_view("object/plugin", array('plugin' => $plugin, 'entity' => find_plugin_usersettings($plugin, $user_guid), 'prefix' => 'user')) ?>
+ </div>
+</div>
+<?php } ?> \ No newline at end of file