• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.5 Flash uploader not working

#1
When uploading images using the flash uploader i get the following error:

"The following error occurred There was a problem uploading your file."

When i turn off the flash uploader it appears fine,

Can anyone point me in the right direction to find a fix for the flash uploader?
 

Brogan

XenForo moderator
Staff member
#2
Which browser and OS?

Is it for any size file, or particularly large ones?

Does it work here on this site with the same browser, OS and file?
 
#5
Yes its all members, i also have a couple of other strange things happening

- When editing posts - in wysiwyg mode when saving it appears to add bb code at the end of the post
upload_2016-4-7_17-13-16.png

- When creating a new post - in Chrome only - i need to refresh the page to see the post box to write a new post.

Just upgraded to php 7, not sure if that has anything to do with it?
 
#6
Im not getting any server errors in Xenforo,

but on on server i am getting the following error
attachments/do-upload.json" failed (2: No such file or directory),
"POST /xxxxx/attachments/do-upload.json?hash=5e0fb3c3de561e578d1e2ad01e92e289&content_type=post HTTP/1.1"
 

Mike

XenForo developer
Staff member
#7
Can you provide the full error message (including the surrounding data)? What log are you finding this in?
 
#8
This is from Nginx error log:
2016/04/07 11:30:24 [error] 22142#0: *4354 open() "/var/www/html/overlandsphere/overland-forum/attachments/do-upload.json" failed (2: No such file or directory), client: 88.240.91.94, server: overlandsphere.com, request: "POST /overland-forum/attachments/do-upload.json?hash=5e0fb3c3de561e578d1e2ad01e92e289&content_type=post HTTP/1.1", host: "overlandsphere.com"
 

Mike

XenForo developer
Staff member
#9
Is that error appearing every time, no matter the file?

That would seem to by implying that it's failing to open the connection to (presumably) your PHP-FPM server, which I presume you are connecting to using a socket. The "no such file or directory" message would likely be referring to the socket file.

If so, that's very bizarre and I have no idea why that would trigger for the Flash uploader. The error would be happening internal to Nginx, as PHP isn't even started then.
 

Mike

XenForo developer
Staff member
#11
Honestly, I'm not sure. It's certainly not something I've seen before. (And we use Nginx without issue.)

Out of curiosity, what shows in the Nginx access log for the request? I'm curious what the response code is.

What version of Nginx are you using? What about PHP (in case this is some how related)? What's your PHP configuration in Nginx?
 
#12
Hi Mike,

Thanks for helping with this,

I'm using:
PHP Version 7.0.5
Nginx 1.6.3

Php and Nginx config attached

Errors from log files:
Nginx Error

2016/04/10 11:18:36 [error] 14009#0: *47 open() "/var/www/html/overlandsphere/overland-forum/attachments/do-upload.json" failed (2: No such file or directory), client: 88.244.211.177, server: overlandsphere.com, request: "POST /overland-forum/attachments/do-upload.json?hash=7604acd4a929ee2047069974bad180af&content_type=post HTTP/1.1", host: "overlandsphere.com", referrer: "http://overlandsphere.com/overland-forum/threads/welcome-please-read.10/"

Nginx Access log
88.244.211.177 - - [10/Apr/2016:11:18:36 -0400] "POST /overland-forum/attachments/do-upload.json?hash=7604acd4a929ee2047069974bad180af&content_type=post HTTP/1.1" 404 564 "http://overlandsphere.com/overland-forum/threads/welcome-please-read.10/" "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36"

Php Modules installed
> php -m
PHP Warning: Module 'apcu' already loaded in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/newrelic.so' - /usr/lib64/php/modules/newrelic.so: undefined symbol: zval_used_for_init in Unknown on line 0
[PHP Modules]
apcu
bcmath
bz2
calendar
Core
ctype
curl
date
dom
exif
fileinfo
filter
ftp
gd
gettext
hash
iconv
intl
json
libxml
mbstring
mcrypt
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_sqlite
Phar
posix
readline
Reflection
session
shmop
SimpleXML
sockets
SPL
sqlite3
standard
sysvmsg
sysvsem
sysvshm
tokenizer
wddx
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zip
zlib

[Zend Modules]
Zend OPcache
 

Attachments

#13
A temporary fix appears to be to add the following rewrite rule:

location ~* /attachments/do-upload
{
try_files /overland-forum/index.php?attachments/do-upload.json?$args /overland-forum/index.php?$uri&$args;
}
 

Mike

XenForo developer
Staff member
#14
It seems like that might imply that some rule is causing that URL to hit a different location block, since Nginx only triggers one per request. As a related example, I just noticed your RSS feeds don't work because this rule:
Code:
location ~* ^.+\.(ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|rss|atom|jpg|jpeg|gif|png|ico|zip|tgz|gz|rar|bz2|doc|xls|exe|ppt|tar|mid|midi|wav|bmp|rtf)$ {
Which preempts this location block:
Code:
location /overland-forum/ {
I'm not seeing an obvious rule doing that in the zip you provided (which I only just noticed now), though I'm not sure if there are other config files being included (perhaps your local nginx.conf file, mentioned in default.conf).