Skip to content
This repository has been archived by the owner on May 24, 2019. It is now read-only.

Commit

Permalink
Update font bbcode to support unicode
Browse files Browse the repository at this point in the history
  • Loading branch information
iMattPro committed May 25, 2012
1 parent dc5883a commit 788cfa3
Showing 1 changed file with 28 additions and 2 deletions.
30 changes: 28 additions & 2 deletions mssti_abbc3/root/install_abbc3.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,12 @@

// Version 3.0.12
'3.0.12' => array(
// enable some new BBvideo IDs
'custom' =>'bbvideo_updater',
'custom' => array(
// enable some new BBvideo IDs
'bbvideo_updater',
// We have some BBCodes to update
'abbc3_bbcode_handler',
),

// purge the cache
'cache_purge' => array(),
Expand Down Expand Up @@ -2369,6 +2373,28 @@ function get_abbc3_bbcodes($action = 'install', $version = '3.0.8')
'bbcode_group' => '0',
),
),
// BBCodes new and/or changed in version 3.0.12
'3.0.12' => array(
// updated with INTEXT to support unicode characters for fonts with foreign language names
'font' => array(
'bbcode_tag' => 'font=',
'bbcode_order' => 1,
'bbcode_id' => 1,
'bbcode_helpline' => 'ABBC3_FONT_TIP',
'bbcode_match' => '[font={INTTEXT}]{TEXT}[/font]',
'bbcode_tpl' => '<span style="font-family: {INTTEXT};">{TEXT}</span>',
'first_pass_match' => '!\[font\=([\p{L}\p{N}\-+,_. ]+)\](.*?)\[/font\]!iues',
'first_pass_replace' => '\'[font=${1}:$uid]\'.str_replace(array("\r\n", \'\"\', \'\\\'\', \'(\', \')\'), array("\n", \'"\', \'&#39;\', \'&#40;\', \'&#41;\'), trim(\'${2}\')).\'[/font:$uid]\'',
'second_pass_match' => '!\[font\=([\p{L}\p{N}\-+,_. ]+):$uid\](.*?)\[/font:$uid\]!su',
'second_pass_replace' => '<span style="font-family: ${1};">${2}</span>',
'display_on_posting' => 1,
'display_on_pm' => 1,
'display_on_sig' => 1,
'abbcode' => 1,
'bbcode_image' => ' ',
'bbcode_group' => '0',
),
),
);

// return a string
Expand Down

0 comments on commit 788cfa3

Please sign in to comment.