| version 1.29, 2006/08/14 10:15:17 |
version 1.30, 2006/08/27 12:10:34 |
|
|
| * http://platon.sk/projects/Metafox/ |
* http://platon.sk/projects/Metafox/ |
| */ |
*/ |
| |
|
| /* $Platon: Metafox/functions.inc.php,v 1.4 2005/11/07 18:33:18 nepto Exp $ */ |
/* $Platon: Metafox/functions.inc.php,v 1.29 2006-08-14 10:15:17 nepto Exp $ */ |
| |
|
| function ezin_eval($evalcode) /* {{{ */ |
function ezin_eval($evalcode) /* {{{ */ |
| { |
{ |
| Line 43 function ezin_process_text_flags(&$str, |
|
| Line 43 function ezin_process_text_flags(&$str, |
|
| // pad it with a space so we can match things at the start of the 1st line. |
// pad it with a space so we can match things at the start of the 1st line. |
| $str = ' ' . $str; |
$str = ' ' . $str; |
| |
|
| $http_substs && $str = preg_replace("#([\n ])([a-z]+?)://([a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]+)#i", "\\1<a href=\"\\2://\\3\" target=\"_blank\">\\2://\\3</a>", $str); |
$http_substs && $str = preg_replace( |
| $www_substs && $str = preg_replace("#([\n ])www\.([a-z0-9\-]+)\.([a-z0-9\-.\~]+)((?:/[a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]*)?)#i", "\\1<a href=\"http://www.\\2.\\3\\4\" target=\"_blank\">www.\\2.\\3\\4</a>", $str); |
"#([\n ])([a-z]+?)://([a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]+)#ie", |
| $email_substs && $str = preg_replace("#([\n ])([a-z0-9\-_.]+?)@([\w\-]+\.([\w\-\.]+\.)?[\w]+)#i", "\\1<a href=\"mailto:\\2@\\3\">\\2@\\3</a>", $str); |
"'\\1<a href=\"\\2://\\3\" target=\"_blank\">\\2://'.Platon::pretty_substr('\\3',80).'</a>'", $str); |
| |
|
| |
$www_substs && $str = preg_replace( |
| |
"#([\n ])www\.([a-z0-9\-]+)\.([a-z0-9\-.\~]+)((?:/[a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]*)?)#i", |
| |
"\\1<a href=\"http://www.\\2.\\3\\4\" target=\"_blank\">www.\\2.\\3\\4</a>", $str); |
| |
|
| |
$email_substs && $str = preg_replace( |
| |
"#([\n ])([a-z0-9\-_.]+?)@([\w\-]+\.([\w\-\.]+\.)?[\w]+)#i", |
| |
"\\1<a href=\"mailto:\\2@\\3\">\\2@\\3</a>", $str); |
| |
|
| if ($line_wrap_p) { |
if ($line_wrap_p) { |
| if ($special) { |
if ($special) { |