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

download headers filename error

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Medium Medium
    • None
    • 2011.6
    • Misc
    • None
    • Operating System: Ubuntu
      PHP Version: 5.3.2

    Description

      I get invalid header errors after upgrading to 2011.6.

      I tracked the issue down to operator precedence in php.

      When a string and ternary operator are concatenated you need to surround the ternary of you get the boolean value concatenated.

      The issue is in /lib/ezfile/classes/ezfile.php

      line 253 has

      header(
      "Content-Disposition: " .
      ( $isAttachedDownload ? 'attachment' : 'inline' ) .
      ( $overrideFilename !== false ) ? "; filename={$overrideFilename}" : ''
      );

      should have

      header(
      "Content-Disposition: " .
      ( $isAttachedDownload ? 'attachment' : 'inline' ) .
      (( $overrideFilename !== false ) ? "; filename={$overrideFilename}" : '')
      );

      Attachments

        Activity

          People

            e8318ba6-e4ae-477c-9116-36c073bd11a3@accounts.ibexa.co Patrick Allaert
            feb52ca2-9206-4fa9-818f-2c4dcf3f42b0@accounts.ibexa.co Douglas Hammond
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: