SMF Development > Fixed or Bogus Bugs
Subs-Editor.php trim & strtolower
Labradoodle-360:
Thanks...you never know if I just made things up ;) ;D
Arantor:
Question of the day, what's the difference between $smcFunc's version and regular htmlspecialchars?
There are plenty of cases where $smcFunc's version should NOT be used. How do you know whether these are some of them or not?
Just because a certain function is used does not imply that it is a bug. For all you know it may very well be intentional.
Labradoodle-360:
Not necessarily a bug, but probably something that should be patched. The difference is $smcFunc incorporates utf-8 support. I was told $smcFunc alternatives should be used as replacements for the regular functions in all scenarios.
Arantor:
Probably most excitingly, doing so will break package management because strlen() is byte counts as opposed to $smcFunc['strlen'] is character counts - which for opening binary files is quite important. There's a bug report on Mantis where years ago I took exactly the same view as you and was told why it should not be the case.
In any case, the characters in question that are being processed do not need to be UTF-8 safe.
Navigation
[0] Message Index
[*] Previous page
Go to full version