aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorEiner von Vielen <tomwie@users.sourceforge.net>2015-01-13 00:06:44 +0100
committerEiner von Vielen <tomwie@users.sourceforge.net>2015-01-13 00:06:44 +0100
commit43b877caa1381c2ac8a031751acd2dab3ec739f0 (patch)
tree9b2e6e74c9e3ffa5ead6a7f89b6b7663fbb6dafa /include
parent9fc9af87e375e65a2bdee4d3c4009df9ed52b4aa (diff)
downloadvolse-hubzilla-43b877caa1381c2ac8a031751acd2dab3ec739f0.tar.gz
volse-hubzilla-43b877caa1381c2ac8a031751acd2dab3ec739f0.tar.bz2
volse-hubzilla-43b877caa1381c2ac8a031751acd2dab3ec739f0.zip
Test
...with table of content. jquery.tableofconent.js works bunt not properly
Diffstat (limited to 'include')
-rw-r--r--include/bbcode.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/bbcode.php b/include/bbcode.php
index 030a1fb49..441c4cc5c 100644
--- a/include/bbcode.php
+++ b/include/bbcode.php
@@ -575,6 +575,10 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true) {
if (strpos($Text,'[h6]') !== false) {
$Text = preg_replace("(\[h6\](.*?)\[\/h6\])ism",'<h6>$1</h6>',$Text);
}
+ // Check for h6
+ if (strpos($Text,'[toc]') !== false) {
+ $Text = preg_replace("/\[toc\]/ism",'<ul id="toc"></ul>',$Text);
+ }
// Check for centered text
if (strpos($Text,'[/center]') !== false) {
$Text = preg_replace("(\[center\](.*?)\[\/center\])ism","<div style=\"text-align:center;\">$1</div>",$Text);