Commit 4e451521 authored by Bate's avatar Bate

Smilies

parent c63a806f
...@@ -667,7 +667,7 @@ class dokusyntax ...@@ -667,7 +667,7 @@ class dokusyntax
'FIXME'=>'fixme.gif', 'FIXME'=>'fixme.gif',
'DELETEME'=>'delete.gif' 'DELETEME'=>'delete.gif'
); );
$smPath = "/images/forum/smilies/"; $smPath = "images/forum/smilies/";
foreach($smileys as $tag => $img) foreach($smileys as $tag => $img)
{ {
if ( file_exists(__DIR__."/../..".$smPath . "/" . $img) ) if ( file_exists(__DIR__."/../..".$smPath . "/" . $img) )
...@@ -686,7 +686,7 @@ class dokusyntax ...@@ -686,7 +686,7 @@ class dokusyntax
$tag = preg_replace('!\*!i', '\*', $tag); $tag = preg_replace('!\*!i', '\*', $tag);
$tag = preg_replace('!\.!i', '\.', $tag); $tag = preg_replace('!\.!i', '\.', $tag);
$tag = preg_replace('!\|!i', '\|', $tag); $tag = preg_replace('!\|!i', '\|', $tag);
$text = preg_replace('!( |^|\n)'.$tag.'( |$|\n)!i', "$1<img src=\"".$wwwtopdir.$smPath.$img."\" alt=\"\" />$2", $text); $text = preg_replace('!( |^|\n)'.$tag.'( |$|\n)!i', "$1<img src=\"".$wwwtopdir.$smPath.$img."\" alt=\"$tag\" />$2", $text);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment