[RSS Feed/News] Templates: "if" conditions in some cases not translated correctly into PHP

Status
Not open for further replies.

XenForo

Administrative
  • Thread starter
  • Admin
  • #1
If you have this if condition in a template:

HTML:

Code:
<xf:if is="(!(FALSE OR TRUE OR TRUE))">
FTT.
</xf:if>

then the compiled PHP code looks like this:

PHP:

Code:
    if (!(false OR true) OR true) {
        $__finalCompiled .= '
FTT.
';

It would be expected that nothing was printed, but because of falsely set brackets (!(false OR true), the outcome is different.

Origin: Conditional Statements for XenForo 2

ادامه مطلب...
 
Status
Not open for further replies.
Back
Top Bottom