SMF 2.1 RC3 - BBC tags on board description

Started by Massl, October 18, 2020, 04:50:31 PM

Previous topic - Next topic

Massl

I don't know if it has already been reported.

1. Add a board description with BBC tag


2. Board description on index


3. Board description

shawnb61

Board titles & topic subjects don't support bbc (2.0 or 2.1).  The problem is they can affect row height on board lists, etc.

They do support emojis, etc., because those are just characters...
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Illori

Quote from: shawnb61 on October 18, 2020, 05:00:16 PM
Board titles & topic subjects don't support bbc (2.0 or 2.1).  The problem is they can affect row height on board lists, etc.

They do support emojis, etc., because those are just characters...

that is the description of the board on the message index of that board.

seems some of the bbc is not parsed on the message index


Illori

MessageIndex.php

line 58

$context['description'] = $board_info['description'];

change to

$context['description'] = parse_bbc($board_info['description']);


shawnb61

That does work...

2.0 behaves the same way, for the same reasons, though, even in the board description. 
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Arantor

2.0 doesn't bbc the field at all, raw HTML just works. But in 2.1 the field is parsed out in some places and should be made consistent.

shawnb61

I don't see any place the board description is parsed.  If you have something factual in mind, please share, or, better yet, log an issue on GH.
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Arantor

https://github.com/SimpleMachines/SMF2.1/blob/release-2.1/Sources/Subs-BoardIndex.php#L211

But I thought it was a hoot doing this? (Also am glad to see that my memory is as good as it ever was about the behaviours of this system)

shawnb61

Issue logged:  https://github.com/SimpleMachines/SMF2.1/issues/6307

Looks like there was a change made last year to honor a subset of bbc tags for descriptions & such lists.  Bold was supposed to be honored, but it's not.  So I logged the issue - that b tag should have worked.

That code is intended to be the one place for the data to be pulled & parsed - specifically for consistency.  You should not have to apply bbc in multiple places, e.g., the template & the query.  You should only need to do it once.  But the question remains why it didn't work.  Issue logged.


Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Arantor

That code is for the whole board index, not individual boards though.

m4z

The bug reported in the first post also existed in RC2 (I have a board that uses [url] in the description; it works fine on the main index, and I see the same behavior of the BBC not being rendered inside the board view).
"Faith is what you have in things that don't exist."
--Homer Simpson

Es gibt hier im Forum ein deutsches Support-Board!

Advertisement: