Greetings to our newest member: FredoMcChief
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
Ganz am Anfang der navigation.ccml
HTML-Code:
<?php
//
// mit Web to Date erzeugte Seite buffern und parsen
// URL in Link umwandeln
// aus Webtodateforum.de
//
function output($out)
{
$out = str_replace("HTTP://WWW.","www.",$out);
$out = str_replace("WWW.","http://www.",$out);
$out = str_replace("http://www.","www.",$out);
$out = str_replace("www.","http://www.",$out);
$out = preg_replace("/([\w]+:\/\/[\w-?&;#~=\.\/\@]+[\w\/])/i","<a href=\"$1\">$1</a>", $out);
return ($out);
}
ob_start("output");
?>
und ganz am Ende der navigation.ccml
HTML-Code:
<?php
ob_end_flush();
?>
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
function forumformatText($text) {
// Ersetzt BB-Formate
$text=str_replace("[i]","<i>",$text);
$text=str_replace("[/i]","</i>",$text);
$text=str_replace("[b]","<b>",$text);
$text=str_replace("[/b]","</b>",$text);
$text=str_replace(":)"," <img src=w2dforumsmile.gif border=0> ",$text);
$text=str_replace(";)"," <img src=w2dforumwink.gif border=0> ",$text);
$text=str_replace(":eek:"," <img src=w2dforumeek.gif border=0> ",$text);
$text=str_replace(":("," <img src=w2dforumsad.gif border=0> ",$text);
$text=str_replace(":o"," <img src=w2dforumwow.gif border=0> ",$text);
$text=str_replace(":roll:"," <img src=w2dforumroll.gif border=0> ",$text);
$text=str_replace(":lol:"," <img src=w2dforumlol.gif border=0> ",$text);
$text.="</i></b>";
return($text);
}
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
function forumformatText($text) {
// Ersetzt BB-Formate
$text=str_replace("[i]","<i>",$text);
$text=str_replace("[/i]","</i>",$text);
$text=str_replace("[b]","<b>",$text);
$text=str_replace("[/b]","</b>",$text);
$text=str_replace(":)"," <img src=w2dforumsmile.gif border=0> ",$text);
$text=str_replace(";)"," <img src=w2dforumwink.gif border=0> ",$text);
$text=str_replace(":eek:"," <img src=w2dforumeek.gif border=0> ",$text);
$text=str_replace(":("," <img src=w2dforumsad.gif border=0> ",$text);
$text=str_replace(":o"," <img src=w2dforumwow.gif border=0> ",$text);
$text=str_replace(":roll:"," <img src=w2dforumroll.gif border=0> ",$text);
$text=str_replace(":lol:"," <img src=w2dforumlol.gif border=0> ",$text);
$text = str_replace("HTTP://WWW.","www.",$text);
$text = str_replace("WWW.","http://www.",$text);
$text= str_replace("http://www.","www.",$text);
$text = str_replace("www.","http://www.",$text);
$text = preg_replace("/([\w]+:\/\/[\w-?&;#~=\.\/\@]+[\w\/])/i","<a href=\"$1\">$1</a>", $text);
$text.="</i></b>";
return($text);
}
|
