diff options
author | cash <cash.costello@gmail.com> | 2011-10-01 12:42:00 -0400 |
---|---|---|
committer | cash <cash.costello@gmail.com> | 2011-10-01 12:42:00 -0400 |
commit | c7b0817dabd1ea596086b03569d4480355e5f721 (patch) | |
tree | 41da241f906243771130b3df92ff4180f30ffeb8 /mod/embed/views/default/navigation | |
parent | 7c52743cc264e258d55c42dccde021b1032f2358 (diff) | |
download | elgg-c7b0817dabd1ea596086b03569d4480355e5f721.tar.gz elgg-c7b0817dabd1ea596086b03569d4480355e5f721.tar.bz2 |
using the menu system for the embed tabs and adding a reusable select list view
Diffstat (limited to 'mod/embed/views/default/navigation')
-rw-r--r-- | mod/embed/views/default/navigation/menu/embed.php | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/mod/embed/views/default/navigation/menu/embed.php b/mod/embed/views/default/navigation/menu/embed.php new file mode 100644 index 000000000..36cedc47e --- /dev/null +++ b/mod/embed/views/default/navigation/menu/embed.php @@ -0,0 +1,21 @@ +<?php +/** + * Embed tabs + * + * @uses $vars['menu']['select'] + * @uses $vars['menu']['upload'] + */ + +$tabs = array(); +foreach (array('select', 'upload') as $type) { + foreach ($vars['menu'][$type] as $menu_item) { + $tabs[] = array( + 'title' => $menu_item->getText(), + 'url' => 'embed/tab/' . $menu_item->getName(), + 'url_class' => 'embed-section', + 'selected' => $menu_item->getSelected(), + ); + } +} + +echo elgg_view('navigation/tabs', array('tabs' => $tabs)); |