Skip to content

Instantly share code, notes, and snippets.

View greenlanegreb's full-sized avatar
😜
Hoping to change the world (eventually)

indieben greenlanegreb

😜
Hoping to change the world (eventually)
  • Grassroots Charity Work (Voluntary)
  • London, United Kingdom
View GitHub Profile
case 'bbcode_htm':
return array(
'#<!\-\- e \-\-><a href="mailto:(.*?)">.*?</a><!\-\- e \-\->#',
'#<!\-\- l \-\-><a (?:class="[\w-]+" )?href="(.*?)(?:(&amp;|\?)sid=[0-9a-f]{32})?" onclick="window\.open\(this\.href\);return false;">.*?</a><!\-\- l \-\->#',
'#<!\-\- ([mw]) \-\-><a (?:class="[\w-]+" )?href="(.*?)" onclick="window\.open\(this\.href\);return false;">.*?</a><!\-\- \1 \-\->#',
'#<!\-\- s(.*?) \-\-><img src="\{SMILIES_PATH\}\/.*? \/><!\-\- s\1 \-\->#',
'#<!\-\- .*? \-\->#s',
'#<.*?>#s',
);
$html = if ($type == MAGIC_URL_EMAIL)
{
$html = "$whitespace<!-- $tag --><a$class href='$url'>$text</a><!-- $tag -->$append";
}
else
{
$html = "$whitespace<!-- $tag --><a$class href='$url' onclick='window.open(this.href);return false;'>$text</a><!-- $tag -->$append";
}
return $html;
$html = if ($type == MAGIC_URL_EMAIL)
{
$html = "$whitespace<!-- $tag --><a$class href='$url'>$text</a><!-- $tag -->$append";
}
else
{
$html = "$whitespace<!-- $tag --><a$class href='$url' onclick='window.open(this.href);return false;'>$text</a><!-- $tag -->$append";