Some bugs into BBCodes
From buttons inserted wrong wrappers for:
Typoscript: insert "typoscript" but work "ts".
HTML: insert "html4strict" but work "html".
[+FEATURE]: Hook for dditional markers in search result (fixes issue #12435)
[#BUGFIX]: Fatal Error with TYPO3 v 4.5 and Extbase v 1.3.0 (fixes issue #12588)
[#BUGFIX]: Error when caching framework is not enabled (fixes issue #12600)
[#BUGFIX]: PNG images are not shown with enabled IE PNG fix (fixes issue #12120)
[#BUGFIX]: [typoscript] bb code is not parsed correctly (fixes issue #7468)
git-svn-id: https://svn.typo3.org/TYPO3v4/Extensions/mm_forum/branches/1.9.x@43299 735d13b6-9817-0410-8766-e36946ffe9aa
#1 Updated by Hauke Hain about 9 years ago
- Status changed from New to Needs Feedback
#2 Updated by Roman Savochenko about 9 years ago
Hauke Hain wrote:
Where manual you mean? If it here http://typo3.org/documentation/document-library/extension-manuals/mm_forum/1.9.0/view/1/1/#id2550386 then no one word about syntax highlighting it present.
The headlines are: “How to include the static templates” & “Static templates: Prototype or jQuery”)
Included "Static templates: Prototype".
Will see for example "HTML" higlight. Open mm_forum config into that page and try select source code into last column. You can select only "html4strict" and if then you save and try insert that block you get code [html4strict]text[/html4strict]. Next try save and you see incorrect block into final text. Correct block you can get only for code [html]text[/html], but that source don't avaible into collumn "Source code" of config. Like problem allowed for some other source codes. I has fixed that problem only manual editing column "lang_code" of table "t3_oscada.tx_mmforum_syntaxhl" of typo3 DB.
#3 Updated by Hauke Hain about 9 years ago
I think I have a clue what you mean. Hopefully anybody can reproduce and fix this error.
#4 Updated by Ines Willenbrock almost 9 years ago
I think, he is talking about the codes, which are inserted after clicking the buttons.
If you e.g. click "TS" then it builds [typoscript][/typoscript]. But the config for the replacement expects [ts][/ts].
The easy fix would be to change the config within the backend module in tools -> Syntax Highlighting.
Which is the string we want to use? [typoscript] or [ts]?
#9 Updated by Ines Willenbrock almost 9 years ago
If we want to have highlighting for the longer form, we should change ext_tables_static+adt.sql to contain something like this:
INSERT INTO tx_mmforum_syntaxhl (uid, pid, tstamp, crdate, deleted, hidden, lang_title, lang_pattern, lang_code, fe_inserticon) VALUES (2, 0, UNIX_TIMESTAMP(), UNIX_TIMESTAMP(), 0, 0, 'Typoscript' , '/\\[typoscript\\](.*?)\\[\\/typoscripts\\]/isS' , 'typoscript' , 'ts.gif');
It seems impossible to have both forms without some ugly hacks.
If there are no objections, I'd attach a patch to this bug for review.
regards - Ines
#10 Updated by Martin Helmich over 8 years ago
Just adding a second entry for the [typoscript] tag is not as easy, as for some reason there is a UNIQUE KEY on the lang_code column of the regarding database table.
Instead of removing this unique-key, I would suggest modifying the regular expression to match both [ts] and [typoscript] (untested):