Upload Multiple problem in FireFox
Permalink
When I try to add files using the upload multiple finction in FireFox, it will not detect image files in any folders on my pc. this function was working up until about a week ago. I'm not sure, but it seems that the dropdown to select file types has changed to displaying an asterisk before the file type names. See attached acreenshot.
The function works fine in IE.
Any help would be greatly appreciated.
The function works fine in IE.
Any help would be greatly appreciated.
I also have found the same problem with fire fox.
If you type a letter into the file name field then files starting with that letter will show for you to select. you can then add them to the upload list one at a time. very slow and tedious.
Colin
If you type a letter into the file name field then files starting with that letter will show for you to select. you can then add them to the upload list one at a time. very slow and tedious.
Colin
Same here... I haven't updated anything on my end and it has to be a recent Firefox update. Not only that, but I can't get into the site again in IE. Chrome is the only browser that still works for Upload Multiple on my end.
I'm also getting the same problem. Firefox is not listing any images in the upload dialogue box.
I am using an older, modified version of Concrete, but I have fixed the problem for myself.
In \concrete\tools\files\import.php
find and comment out this line:
add:
Your code should now look like this
The file type validation set up in concrete/config/app.php will still stop unwanted filetypes from being uploaded.
I believe the problem is an incompatiblity between Firefox and some recent update to Windows 7. I can recreate the problem on Firefox 13 with a recently updated Windows 7 system. I can't recreate the problem with Firefox 13 or 14 on an as yet un-updated Windows 7 system.
In \concrete\tools\files\import.php
find and comment out this line:
$types = $ch->serializeUploadFileExtensions($types);
add:
$types='*.*';
Your code should now look like this
//$types = $ch->serializeUploadFileExtensions($types); $types='*.*';
The file type validation set up in concrete/config/app.php will still stop unwanted filetypes from being uploaded.
I believe the problem is an incompatiblity between Firefox and some recent update to Windows 7. I can recreate the problem on Firefox 13 with a recently updated Windows 7 system. I can't recreate the problem with Firefox 13 or 14 on an as yet un-updated Windows 7 system.
Excellent that sorted it, thanks!
I personally don't think the problem is related solely to Windows 7 as I'm running Vista and still got this issue. However the update could apply to both Vista and Windows 7.
Maybe it is to do with the new FF and Flash having some incompatibility.
Anyway, thanks again for the fix.
I personally don't think the problem is related solely to Windows 7 as I'm running Vista and still got this issue. However the update could apply to both Vista and Windows 7.
Maybe it is to do with the new FF and Flash having some incompatibility.
Anyway, thanks again for the fix.
Thanks so much. I too believe it has something to do with flash incompatibility
This didn't resolve my particular instance, but thanks for posting anyway. If I ever come across another possible solution, I'll post it.
Lando:
Please specify your specifics
Operating System/version
Browser version
Concrete version
Also please as a check copy/paste the specific code changes you made to import.php (including several lines above and below the change) -- or download the file, turn it into a txt file, and attach to your message.
Please specify your specifics
Operating System/version
Browser version
Concrete version
Also please as a check copy/paste the specific code changes you made to import.php (including several lines above and below the change) -- or download the file, turn it into a txt file, and attach to your message.
Sure - here you go:
ENVIRONMENT:
MODIFIED import.php AS FOLLOWS:
OS VERSION:
Windows 7 Professional (64 bit)
BROWSER MAKE/VERSION:
Firefox 14.0.1
I also have IE9 and Chrome installed on my computer, neither of them exhibit this problem.
Thanks for your help!
ENVIRONMENT:
# concrete5 Version 5.5.2.1 # concrete5 Packages Designer Content (3.1), Galleria image gallery (2.0), Toolbar Quick Links (1.0), Yosemite (1.0). # concrete5 Overrides blocks/autonav, blocks/home_feature_block, blocks/main_half_left_a, blocks/main_half_right_a, blocks/slideshow, blocks/sub_title_block, blocks/test_block, blocks/thumbnail_index_item, jobs/poll_ldap_users.php, themes/landoll_steel_2012 # Server Software Microsoft-IIS/7.5 # Server API cgi-fcgi # PHP Version 5.3.9 # PHP Extensions bcmath, bz2, calendar, cgi-fcgi, com_dotnet, Core, ctype, curl, date, dom, ereg, exif, filter, ftp, gd, gettext, gmp, hash, iconv, imap, json, ldap, libxml, mbstring, mcrypt, mhash, mysql, mysqli, mysqlnd, odbc, openssl, pcre, PDO, pdo_mysql, PDO_ODBC, pdo_sqlite, pgsql, Phar, Reflection, session, SimpleXML, soap, sockets, SPL, sqlite3, sqlsrv, standard, tidy, tokenizer, wddx, xml, xmlreader, xmlrpc, xmlwriter, zip, zlib. # PHP Settings
Viewing 15 lines of 45 lines. View entire code block.
MODIFIED import.php AS FOLLOWS:
<?php defined('C5_EXECUTE') or die("Access Denied."); $u = new User(); $ch = Loader::helper('concrete/file'); $h = Loader::helper('concrete/interface'); $form = Loader::helper('form'); $fp = FilePermissions::getGlobal(); if (!$fp->canAddFiles()) { die(t("Unable to add files.")); } //$types = $fp->getAllowedFileExtensions(); $types='*.*'; $searchInstance = $_REQUEST['searchInstance']; $ocID = $_REQUEST['ocID']; $types = $ch->serializeUploadFileExtensions($types);
Viewing 15 lines of 17 lines. View entire code block.
OS VERSION:
Windows 7 Professional (64 bit)
BROWSER MAKE/VERSION:
Firefox 14.0.1
I also have IE9 and Chrome installed on my computer, neither of them exhibit this problem.
Thanks for your help!
Sorry: except for your Concrete5 version my system looks almost exactly like your system, and like I say, mine now works, so WTF?
The *.* change you made to import.php is where Firefox learns what files to display on its file browser. There are other places around the concrete rats nest of code where the file types get reviewed. But that change should tell Firefox that you want all available filetypes displayed (although not available for upload).
So why isn't his happening? Since we have similar systems, the likely fault lies in the communications between your server and the file browser in Firefox. For example: the *.* is not getting done because the old info is (a) in the browser's cache or (b) in some kind of cache the your server is using. Or (c) you uploaded the change to the wrong directory or other asleep-at-the-switch mistake (of which I am SO regularly guilty that I have no problem saying 'these things happen').
SO: check the upload, check the server isn't caching and sending an old file, check that Firefox isn't caching an old file. Maybe this will work? Or maybe you just get to hope that Concrete's Smart Guys get around to fixing the problem.
Has this problem been submitted as a bug report anywhere?
The *.* change you made to import.php is where Firefox learns what files to display on its file browser. There are other places around the concrete rats nest of code where the file types get reviewed. But that change should tell Firefox that you want all available filetypes displayed (although not available for upload).
So why isn't his happening? Since we have similar systems, the likely fault lies in the communications between your server and the file browser in Firefox. For example: the *.* is not getting done because the old info is (a) in the browser's cache or (b) in some kind of cache the your server is using. Or (c) you uploaded the change to the wrong directory or other asleep-at-the-switch mistake (of which I am SO regularly guilty that I have no problem saying 'these things happen').
SO: check the upload, check the server isn't caching and sending an old file, check that Firefox isn't caching an old file. Maybe this will work? Or maybe you just get to hope that Concrete's Smart Guys get around to fixing the problem.
Has this problem been submitted as a bug report anywhere?
user blank array insted of *.*
Because its use array argument in some another page.
so you can write like
$types = array();
Because its use array argument in some another page.
so you can write like
$types = array();
Today I encountered the same issue with FF 15.0 (Linux 3.2.0-23).
With Opera 12.02 (Linux) it works fine.
With Opera 12.02 (Linux) it works fine.
The solution is very simple: it is required a space between file-types in file_types param of flash. The source of problem is in ConcreteFileHelper.serializeUploadFileExtensions (/concrete/helpers/concrete/file.php)
To fix create a file /helpers/concrete/file.php with code below.
To fix create a file /helpers/concrete/file.php with code below.
<?php defined('C5_EXECUTE') || die(t('Access Denied.')); class SiteConcreteFileHelper extends ConcreteFileHelper { public function serializeUploadFileExtensions($types){ $serialized = ''; $types = preg_replace(self::REGEX_INVALID_EXTENSION_CHARS,'',$types); foreach ($types as $type) { $serialized .= '*.'.$type.'; '; } //removing trailing ; unclear if multiupload will choke on that or not $serialized = substr ($serialized, 0, strlen($serialized)-1); return $serialized; } }
That worked on mine - thanks very much for the fix, SieGe!
Hi - tried this so creating a file in a folder on the first level called helpers/concrete/file.php
and then added your code...it seemed to break the file manager. Am I doing it right or do I need to edit the file /concrete/helpers/concrete/file.php and if so which bit should I edit.
Sorry could you expand on this please....?
Thanks
and then added your code...it seemed to break the file manager. Am I doing it right or do I need to edit the file /concrete/helpers/concrete/file.php and if so which bit should I edit.
Sorry could you expand on this please....?
Thanks
I don't suggest to modify the core in concrete folder. I create the fix for v5.5 or latest versions. I don't make any other modification.
If you think, change the core code. Only a space is required in the foreach after the semicolon.
If you think, change the core code. Only a space is required in the foreach after the semicolon.
i add JPEG and JPG in Allowed File Types, go to filemanager -> access
and multiple upload work find, although in some PC you must update your flash extension from adobe
i am using 5.4.2.x, maybe because i update my firefox and new firefox start to strict uppercase and lowercase
and multiple upload work find, although in some PC you must update your flash extension from adobe
flv, jpg, gif, jpeg, ico, docx, xla, png, psd, swf, doc, txt, xls, xlsx, csv, pdf, tiff, rtf, m4a, mov, wmv, mpeg, mpg, wav, avi, m4v, mp4, mp3, qt, ppt, pptx, kml, xml, JPEG, JPG
i am using 5.4.2.x, maybe because i update my firefox and new firefox start to strict uppercase and lowercase
My first guess is the updates that have been recently pushed out to FF. There have been no changes to C5 since then - at least none that we have applied to our environment.
I'll continue to research this and let you know if I find anything.