aboutsummaryrefslogtreecommitdiff
path: root/views/default/widgets/controls.php
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-11-19 19:11:03 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-11-19 19:11:03 +0000
commitf42382e0bff1692e2ddcd1c8eb316836e3020f1e (patch)
treebd11cb29bbae69f0daff3c0cd9c273203c788dc9 /views/default/widgets/controls.php
parentb70654070d83323853f808beccc6780cfcd51ce4 (diff)
downloadelgg-f42382e0bff1692e2ddcd1c8eb316836e3020f1e.tar.gz
elgg-f42382e0bff1692e2ddcd1c8eb316836e3020f1e.tar.bz2
users can delete widgets from layout
git-svn-id: http://code.elgg.org/elgg/trunk@7349 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/widgets/controls.php')
-rw-r--r--views/default/widgets/controls.php32
1 files changed, 32 insertions, 0 deletions
diff --git a/views/default/widgets/controls.php b/views/default/widgets/controls.php
new file mode 100644
index 000000000..881057969
--- /dev/null
+++ b/views/default/widgets/controls.php
@@ -0,0 +1,32 @@
+<?php
+/**
+ * Elgg widget controls
+ *
+ * @package Elgg
+ * @subpackage Core
+ */
+
+$widget = $vars['widget'];
+
+$params = array(
+ 'text' => 'delete',
+ 'href' => '#', //elgg_get_site_url() . "action/widgets/delete?guid=$widget->guid",
+ 'is_action' => true,
+ 'class' => 'widget_delete',
+ 'internalid' => "widget_delete_$widget->guid"
+);
+$delete_link = elgg_view('output/url', $params);
+
+$params = array(
+ 'text' => 'edit',
+ 'href' => elgg_get_site_url() . "#",
+ 'is_action' => true,
+);
+$edit_link = elgg_view('output/url', $params);
+
+echo <<<___END
+<ul>
+ <li>$delete_link</li>
+ <li>$edit_link</li>
+</ul>
+___END;