[wp-trac] [WordPress Trac] #39550: Some Non-image files fail to upload after 4.7.1

WordPress Trac noreply at wordpress.org
Wed Jan 18 15:24:31 UTC 2017


#39550: Some Non-image files fail to upload after 4.7.1
------------------------------------+------------------------
 Reporter:  greatislander           |       Owner:  joemcgill
     Type:  defect (bug)            |      Status:  assigned
 Priority:  normal                  |   Milestone:  4.7.2
Component:  Upload                  |     Version:  trunk
 Severity:  normal                  |  Resolution:
 Keywords:  has-patch dev-feedback  |     Focuses:
------------------------------------+------------------------

Comment (by shazahm1@…):

 I could be wrong... but late static binding (correct term???) was
 introduced in PHP5.3, correct? So, the method calls using the `static`
 keyword for scope resolution such as `static::method_name()` would not be
 compatible with PHP5.2.

 Replying to [comment:62 blobfolio]:
 > Replying to [comment:61 rmccue]:
 >
 > > @blobfolio Thanks for the patch. Can't comment on the functionality
 (not really my area), but in terms of structure: WordPress requires PHP
 5.2+, so cannot use namespaces. To use your library, it would need to be
 5.2-compatible.
 >
 > Thank you Ryan! I removed the namespace, and also added a condition to
 check whether the constant `FILEINFO_MIME_TYPE` is defined, as that also
 did not make an appearance until PHP 5.3.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/39550#comment:63>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list