New option to enable and disable the "share" element

Changes to "vier" to use more "font awesome" icons
This commit is contained in:
Michael Vogel 2012-12-21 00:08:58 +01:00
parent 8e194cb411
commit f4bc5c57f3
9 changed files with 110 additions and 152 deletions

View file

@ -3,6 +3,14 @@
require_once("include/oembed.php");
require_once('include/event.php');
function bb_cleanstyle($st) {
return "<span style=\"".cleancss($st[1]).";\">".$st[2]."</span>";
}
function bb_cleanclass($st) {
return "<span class=\"".cleancss($st[1])."\">".$st[2]."</span>";
}
function cleancss($input) {
$cleaned = "";
@ -385,10 +393,10 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true) {
$Text = str_replace("[*]", "<li>", $Text);
// Check for style sheet commands
$Text = preg_replace("(\[style=(.*?)\](.*?)\[\/style\])ism","<span style=\"$1;\">$2</span>",$Text);
$Text = preg_replace_callback("(\[style=(.*?)\](.*?)\[\/style\])ism","bb_cleanstyle",$Text);
// Check for CSS classes
$Text = preg_replace("(\[class=(.*?)\](.*?)\[\/class\])ism","<span class=\"$1\">$2</span>",$Text);
$Text = preg_replace_callback("(\[class=(.*?)\](.*?)\[\/class\])ism","bb_cleanclass",$Text);
// handle nested lists
$endlessloop = 0;