Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-13075

and() executes all conditiuons even though first one returns false

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Obsolete
    • Icon: Medium Medium
    • None
    • 4.0.0, 4.2.0, 4.3.0beta1
    • Misc
    • None

    Description

      The following code will give an error when the ini variable is undefined:

      {if and(
        ezini_hasvariable( 'Custom_block', 'Required', 'content.ini' ),
        ezini( 'Custom_block', 'Required', 'content.ini' )|eq('true')
      )}
          do something
      {/if}
      

      But this will not:

      {if ezini_hasvariable( 'Custom_block', 'Required', 'content.ini' )}
        {if ezini( 'Custom_block', 'Required', 'content.ini' )|eq('true')}
          do something
        {/if}
      {/if}
      

      Error: eZTemplate:ezini
      !!!No such variable 'Required' in group 'Custom_block' for content.ini

      Attachments

        Activity

          People

            unknown unknown
            andre1 andre1
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: