Skip to main content

Thread: PHP $_FILES['file']['type'] now returns double quoted string


hello guys,

yesterday updated bunch of packages on server, , of sudden php started returning mime types on uploaded files double quoted strings:

before: $_files['file']['type'] contain example: application/pdf

now: $_files['file']['type'] contains "application/pdf"

of course breaks string comparisons $_files['file']['type'] == "application/pdf"

know if it's bug php, or if information fetched system, or browser? i'm blaming php5 package because thing involved noticed being updated before issue presented itself.

if knows i'd love hear it. in meantime updated code reflect change , maintain retro-compatibility, change smells bug more new feature, code break because of this.

ubuntu server:
code:
linux 2.6.32-36-generic #79-ubuntu smp tue nov 8 22:29:53 utc 2011 x86_64 gnu/linux  ubuntu 10.04.3 lts
my php version:
code:
php 5.3.2-1ubuntu4.11 suhosin-patch (cli) (built: dec 13 2011 18:49:27)

what var_dump( $_files['file']['type']) return?


Forum The Ubuntu Forum Community Ubuntu Specialised Support Ubuntu Servers, Cloud and Juju Server Platforms [ubuntu] PHP $_FILES['file']['type'] now returns double quoted string


Ubuntu

Comments

Popular posts from this blog

How to set the order of FAQs instead of alphabetical

Thread: Get UK Keyboard working

how do I change the e-mail address for my merchant account