From eda1d40861fb5a2b74e7e5ade618cc9fa83cafd1 Mon Sep 17 00:00:00 2001 From: Henry Sudhof Date: Mon, 28 Jul 2008 14:24:37 +0000 Subject: Okay. Frozen, we never said anything about it being permafrost. Also, this is not 100% tested, expect troubel with store_db (I'm waiting for the bug reports) git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8697 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/bbcode.php | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'phpBB/includes/bbcode.php') diff --git a/phpBB/includes/bbcode.php b/phpBB/includes/bbcode.php index ef73762582..fd8fadf3a7 100644 --- a/phpBB/includes/bbcode.php +++ b/phpBB/includes/bbcode.php @@ -134,10 +134,21 @@ class bbcode { $this->template_bitfield = new bitfield($user->theme['bbcode_bitfield']); $this->template_filename = $phpbb_root_path . 'styles/' . $user->theme['template_path'] . '/template/bbcode.html'; - + if (!@file_exists($this->template_filename)) { - trigger_error('The file ' . $this->template_filename . ' is missing.', E_USER_ERROR); + if (isset($user->theme['template_inherits_id']) && $user->theme['template_inherits_id']) + { + $this->template_filename = $phpbb_root_path . 'styles/' . $user->theme['template_inherit_path'] . '/template/bbcode.html'; + if (!@file_exists($this->template_filename)) + { + trigger_error('The file ' . $this->template_filename . ' is missing.', E_USER_ERROR); + } + } + else + { + trigger_error('The file ' . $this->template_filename . ' is missing.', E_USER_ERROR); + } } } -- cgit v1.2.1 From 20b08e296186e8ae812a0928d387bb01468af846 Mon Sep 17 00:00:00 2001 From: Meik Sievertsen Date: Fri, 19 Sep 2008 16:40:24 +0000 Subject: support tabs in code selections (Bug #25445). Still does not solve the strange "4 spaces prefixed on every line" problem in firefox. :/ git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8893 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/bbcode.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'phpBB/includes/bbcode.php') diff --git a/phpBB/includes/bbcode.php b/phpBB/includes/bbcode.php index fd8fadf3a7..09830ac97e 100644 --- a/phpBB/includes/bbcode.php +++ b/phpBB/includes/bbcode.php @@ -581,10 +581,10 @@ class bbcode // no break; default: - $code = str_replace("\t", '   ', $code); +/* $code = str_replace("\t", '   ', $code); $code = str_replace(' ', '  ', $code); $code = str_replace(' ', '  ', $code); - +*/ // remove newline at the beginning if (!empty($code) && $code[0] == "\n") { -- cgit v1.2.1 From 0a98003d91113336cf095c634447d4c14968cebc Mon Sep 17 00:00:00 2001 From: Meik Sievertsen Date: Sun, 28 Sep 2008 17:08:09 +0000 Subject: revert r8893 - there were massive problems with the display and select all code git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8953 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/bbcode.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'phpBB/includes/bbcode.php') diff --git a/phpBB/includes/bbcode.php b/phpBB/includes/bbcode.php index 09830ac97e..fd8fadf3a7 100644 --- a/phpBB/includes/bbcode.php +++ b/phpBB/includes/bbcode.php @@ -581,10 +581,10 @@ class bbcode // no break; default: -/* $code = str_replace("\t", '   ', $code); + $code = str_replace("\t", '   ', $code); $code = str_replace(' ', '  ', $code); $code = str_replace(' ', '  ', $code); -*/ + // remove newline at the beginning if (!empty($code) && $code[0] == "\n") { -- cgit v1.2.1