diff options
Diffstat (limited to 'mod/faq/views')
-rw-r--r-- | mod/faq/views/default/expages/menu.php | 23 | ||||
-rw-r--r-- | mod/faq/views/default/js/simple_faq/toc.php | 24 |
2 files changed, 47 insertions, 0 deletions
diff --git a/mod/faq/views/default/expages/menu.php b/mod/faq/views/default/expages/menu.php new file mode 100644 index 000000000..a88536924 --- /dev/null +++ b/mod/faq/views/default/expages/menu.php @@ -0,0 +1,23 @@ +<?php +/** + * External pages menu + * + * @uses $vars['type'] + */ + +$type = $vars['type']; + +//set the url +$url = $vars['url'] . "admin/site/expages?type="; + +$pages = array('about', 'terms', 'privacy', 'faq'); +$tabs = array(); +foreach ($pages as $page) { + $tabs[] = array( + 'title' => elgg_echo("expages:$page"), + 'url' => "admin/appearance/expages?type=$page", + 'selected' => $page == $type, + ); +} + +echo elgg_view('navigation/tabs', array('tabs' => $tabs, 'class' => 'elgg-form-settings')); diff --git a/mod/faq/views/default/js/simple_faq/toc.php b/mod/faq/views/default/js/simple_faq/toc.php new file mode 100644 index 000000000..2b1621f88 --- /dev/null +++ b/mod/faq/views/default/js/simple_faq/toc.php @@ -0,0 +1,24 @@ +<?php +/** + * Show the FAQs' Table of Contents + * + * @package SimpleFAQ + */ + +include(elgg_get_plugins_path() . 'simple_faq/vendors/jquery-stoc/jquery.stoc.js'); + +?> + +elgg.provide('elgg.simple_faq'); + +elgg.simple_faq.init = function() { + $(function(){ + $("<div class="elgg-simplefaq-toc"></div>").prependTo(".elgg-main .elgg-output").stoc({ + search: ".elgg-main .elgg-output", + stocTitle: "", + listType: "ol", + }); + }); +}; + +elgg.register_hook_handler('init', 'system', elgg.simple_faq.init); |