aboutsummaryrefslogtreecommitdiff
path: root/pages/settings
diff options
context:
space:
mode:
Diffstat (limited to 'pages/settings')
-rw-r--r--pages/settings/account.php27
-rw-r--r--pages/settings/index.php19
-rw-r--r--pages/settings/statistics.php15
-rw-r--r--pages/settings/tools.php (renamed from pages/settings/plugins.php)15
-rw-r--r--pages/settings/user.php22
5 files changed, 47 insertions, 51 deletions
diff --git a/pages/settings/account.php b/pages/settings/account.php
new file mode 100644
index 000000000..88e916658
--- /dev/null
+++ b/pages/settings/account.php
@@ -0,0 +1,27 @@
+<?php
+/**
+ * Elgg user account settings.
+ *
+ * @package Elgg
+ * @subpackage Core
+ */
+
+// Only logged in users
+gatekeeper();
+
+// Make sure we don't open a security hole ...
+if ((!elgg_get_page_owner()) || (!elgg_get_page_owner()->canEdit())) {
+ set_page_owner(get_loggedin_userid());
+}
+
+$title = elgg_echo('usersettings:user');
+
+$content .= elgg_view('core/settings/account');
+
+$params = array(
+ 'content' => $content,
+ 'title' => $title,
+);
+$body = elgg_view_layout('one_sidebar', $params);
+
+echo elgg_view_page($title, $body);
diff --git a/pages/settings/index.php b/pages/settings/index.php
deleted file mode 100644
index dbc8c87da..000000000
--- a/pages/settings/index.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-/**
- * Elgg user settings system index
- *
- * @package Elgg
- * @subpackage Core
- */
-
-if (!elgg_get_page_owner_guid()) {
- set_page_owner(get_loggedin_userid());
-}
-
-// Make sure we don't open a security hole ...
-if ((!elgg_get_page_owner()) || (!elgg_get_page_owner()->canEdit())) {
- set_page_owner(get_loggedin_userid());
-}
-
-// Forward to the user settings
-forward('pg/settings/user/' . elgg_get_page_owner()->username . "/"); \ No newline at end of file
diff --git a/pages/settings/statistics.php b/pages/settings/statistics.php
index 741003308..165c31e8e 100644
--- a/pages/settings/statistics.php
+++ b/pages/settings/statistics.php
@@ -6,7 +6,7 @@
* @subpackage Core
*/
-// Make sure only valid admin users can see this
+// Only logged in users
gatekeeper();
// Make sure we don't open a security hole ...
@@ -14,9 +14,14 @@ if ((!elgg_get_page_owner()) || (!elgg_get_page_owner()->canEdit())) {
set_page_owner(get_loggedin_userid());
}
-$content = elgg_view_title(elgg_echo("usersettings:statistics"));
-$content .= elgg_view("usersettings/statistics");
+$title = elgg_echo("usersettings:statistics");
-$body = elgg_view_layout('one_column_with_sidebar', array('content' => $content));
+$content = elgg_view("core/settings/statistics");
-echo elgg_view_page(elgg_echo("usersettings:statistics"), $body);
+$params = array(
+ 'content' => $content,
+ 'title' => $title,
+);
+$body = elgg_view_layout('one_sidebar', array('content' => $content));
+
+echo elgg_view_page($title, $body);
diff --git a/pages/settings/plugins.php b/pages/settings/tools.php
index 657519d38..e1c247581 100644
--- a/pages/settings/plugins.php
+++ b/pages/settings/tools.php
@@ -1,6 +1,6 @@
<?php
/**
- * Elgg user plugin settings.
+ * Elgg user tools settings
*
* @package Elgg
* @subpackage Core
@@ -14,10 +14,15 @@ if ((!elgg_get_page_owner()) || (!elgg_get_page_owner()->canEdit())) {
set_page_owner(get_loggedin_userid());
}
-$content = elgg_view_title(elgg_echo("usersettings:plugins"));
-$content .= elgg_view("usersettings/plugins",
+$title = elgg_echo("usersettings:plugins");
+
+$content = elgg_view("core/settings/tools",
array('installed_plugins' => get_installed_plugins()));
-$body = elgg_view_layout('one_column_with_sidebar', array('content' => $content));
+$params = array(
+ 'content' => $content,
+ 'title' => $title,
+);
+$body = elgg_view_layout('one_sidebar', $params);
-echo elgg_view_page(elgg_echo("usersettings:plugins"), $body);
+echo elgg_view_page($title, $body);
diff --git a/pages/settings/user.php b/pages/settings/user.php
deleted file mode 100644
index 2a530548c..000000000
--- a/pages/settings/user.php
+++ /dev/null
@@ -1,22 +0,0 @@
-<?php
-/**
- * Elgg user account settings.
- *
- * @package Elgg
- * @subpackage Core
- */
-
-// Make sure only valid admin users can see this
-gatekeeper();
-
-// Make sure we don't open a security hole ...
-if ((!elgg_get_page_owner()) || (!elgg_get_page_owner()->canEdit())) {
- set_page_owner(get_loggedin_userid());
-}
-
-$content = elgg_view_title(elgg_echo('usersettings:user'));
-$content .= elgg_view("usersettings/form");
-
-$body = elgg_view_layout("one_column_with_sidebar", array('content' => $content));
-
-echo elgg_view_page(elgg_echo("usersettings:user"), $body);