aboutsummaryrefslogtreecommitdiff
path: root/actions
diff options
context:
space:
mode:
Diffstat (limited to 'actions')
-rw-r--r--actions/admin/site/update_advanced.php2
-rw-r--r--actions/river/delete.php21
-rw-r--r--actions/widgets/add.php3
3 files changed, 23 insertions, 3 deletions
diff --git a/actions/admin/site/update_advanced.php b/actions/admin/site/update_advanced.php
index 897a2f983..0fd8d1f35 100644
--- a/actions/admin/site/update_advanced.php
+++ b/actions/admin/site/update_advanced.php
@@ -53,8 +53,6 @@ if ($site = elgg_get_site_entity()) {
$user_default_access = (get_input('allow_user_default_access')) ? 1 : 0;
set_config('allow_user_default_access', $user_default_access, $site->getGUID());
- set_config('view', get_input('view'), $site->getGUID());
-
$debug = get_input('debug');
if ($debug) {
set_config('debug', $debug, $site->getGUID());
diff --git a/actions/river/delete.php b/actions/river/delete.php
new file mode 100644
index 000000000..0d8297932
--- /dev/null
+++ b/actions/river/delete.php
@@ -0,0 +1,21 @@
+<?php
+/**
+ * River item delete action
+ *
+ * @package Elgg
+ * @subpackage Core
+ */
+
+$id = get_input('id', false);
+
+if ($id !== false && elgg_is_admin_logged_in()) {
+ if (elgg_delete_river(array('id' => $id))) {
+ system_message(elgg_echo('river:delete:success'));
+ } else {
+ register_error(elgg_echo('river:delete:fail'));
+ }
+} else {
+ register_error(elgg_echo('river:delete:fail'));
+}
+
+forward(REFERER);
diff --git a/actions/widgets/add.php b/actions/widgets/add.php
index f65d11134..d7b2f291c 100644
--- a/actions/widgets/add.php
+++ b/actions/widgets/add.php
@@ -9,6 +9,7 @@
$owner_guid = get_input('owner_guid');
$handler = get_input('handler');
$context = get_input('context');
+$show_access = (bool)get_input('show_access', true);
$column = get_input('column', 1);
$default_widgets = get_input('default_widgets', 0);
@@ -29,7 +30,7 @@ if (!empty($owner_guid)) {
$widget->move($column, 0);
// send widget html for insertion
- echo elgg_view_entity($widget);
+ echo elgg_view_entity($widget, array('show_access' => $show_access));
//system_message(elgg_echo('widgets:add:success'));
forward(REFERER);