aboutsummaryrefslogtreecommitdiff
path: root/actions/widgets/save.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/widgets/save.php')
-rw-r--r--actions/widgets/save.php34
1 files changed, 34 insertions, 0 deletions
diff --git a/actions/widgets/save.php b/actions/widgets/save.php
new file mode 100644
index 000000000..b50010e6f
--- /dev/null
+++ b/actions/widgets/save.php
@@ -0,0 +1,34 @@
+<?php
+
+ /**
+ * Elgg widget save action
+ *
+ * @package Elgg
+ * @subpackage Core
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.org/
+ */
+
+ $guid = get_input('guid');
+ $params = get_input('params');
+ $pageurl = get_input('pageurl');
+
+ $result = false;
+
+ if (!empty($guid)) {
+
+ $result = save_widget_info($guid,$params);
+
+ }
+
+ if ($result) {
+ system_message('widgets:save:success');
+ } else {
+ system_message('widgets:save:failure');
+ }
+
+ forward($_SERVER['HTTP_REFERER']);
+
+?> \ No newline at end of file