aboutsummaryrefslogtreecommitdiffstats
path: root/view
diff options
context:
space:
mode:
authorRedMatrix <info@friendica.com>2015-01-15 11:22:57 +1100
committerRedMatrix <info@friendica.com>2015-01-15 11:22:57 +1100
commitb37915a40e4e049072698e604e61798445a339de (patch)
tree8442b35b92920a759f6b9e67030b8f151114e648 /view
parentd6ae124bbd549629ec7d76bb1b1555d1344ac8b4 (diff)
parentdfab2416926631b7b08c6c89b62528ca2520f130 (diff)
downloadvolse-hubzilla-b37915a40e4e049072698e604e61798445a339de.tar.gz
volse-hubzilla-b37915a40e4e049072698e604e61798445a339de.tar.bz2
volse-hubzilla-b37915a40e4e049072698e604e61798445a339de.zip
Merge pull request #850 from einervonvielen/toc
Added a table of content as bbcode element [toc] for webpages
Diffstat (limited to 'view')
-rw-r--r--view/js/main.js2
-rw-r--r--view/php/theme_init.php1
2 files changed, 3 insertions, 0 deletions
diff --git a/view/js/main.js b/view/js/main.js
index 9d5136c34..0c56c8d41 100644
--- a/view/js/main.js
+++ b/view/js/main.js
@@ -1125,6 +1125,8 @@ $(document).ready(function() {
$(".autotime").timeago();
+ $("#toc").toc({content: "div.page-body", headings: "h1,h2,h3,h4"});
+
});
diff --git a/view/php/theme_init.php b/view/php/theme_init.php
index d43a87046..b3580b81f 100644
--- a/view/php/theme_init.php
+++ b/view/php/theme_init.php
@@ -43,6 +43,7 @@ head_add_js('library/colorbox/jquery.colorbox-min.js');
head_add_js('library/bootstrap-tagsinput/bootstrap-tagsinput.js');
head_add_js('library/jquery.AreYouSure/jquery.are-you-sure.js');
+head_add_js('library/tableofcontents/jquery.toc.js');
/**
* Those who require this feature will know what to do with it.
* Those who don't, won't.