mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 00:45:14 +02:00
strip duplicate code blocks bb2d*
This commit is contained in:
parent
6d507a840a
commit
02a1fdacd7
2 changed files with 109 additions and 68 deletions
|
@ -149,13 +149,11 @@ function bb2diaspora($Text,$preserve_nl = false) {
|
|||
// Check for font change text
|
||||
// $Text = preg_replace("(\[font=(.*?)\](.*?)\[\/font\])","<span style=\"font-family: $1;\">$2</span>",$Text);
|
||||
|
||||
// Declare the format for [code] layout
|
||||
|
||||
$Text = preg_replace_callback("/\[code\](.*?)\[\/code\]/is",'stripdcode_br_cb',$Text);
|
||||
$Text = preg_replace_callback("/\[code\](.*?)\[\/code\]/is",'stripdcode_br_cb',$Text);
|
||||
|
||||
// $CodeLayout = '<code>$1</code>';
|
||||
// Check for [code] text
|
||||
$Text = preg_replace("/\[code\](.*?)\[\/code\]/is","\t$1\n", $Text);
|
||||
$Text = preg_replace("/(\[code\])+(.*?)(\[\/code\])+/is","\t$2\n", $Text);
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue