Open bttrx opened 4 years ago
(I hate GitHub web interface for being so limited in Firefox 52.x: No edit, no preview, ...)
After searching myself for $bbcode_img
I came to the same conclusion. The variable name exists only in this one function but nowhere else in the whole project. And even if the variable would exist anywhere else, it' value would not exist inside the function because it is neither globalised nor given as a function parameter.
So I would tend to change the if-statement to if ($settings['bbcode_img'] == 1)
. Any thoughts
I looked over my old mlf versions. $bbcode_img
is a remaining from v1.3 (!), where mlf stores all settings in settings.php
. Back then $bbcode_img
existed as a global variable.
So, yes, please change it.
Worked for me in 1.7.11. But looks a bit awkward to have, e.g., "img/uploaded/image81.png" written in the mail for relative paths. Maybe this should be expanded by adding the forum's URL (+ "/img/uploaded/") from the "Link to the entry" statement already in the mail.
mlf 1.x (at least 1.7.6 to 1.7.11) does not strip the BBCode tags
[img]
and[/img]
from the mail body. Problem seems to be in functionunbbcode()
in filefunctions.php
. I guess, it is because no variable$bbcode_img
exists somewhere else in mlf source code.