Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Asset Manager / Image Upload Fix to upload multiple files like the Flash uploader Details »
Asset Manager / Image Upload Fix to upload multiple files like the Flash uploader
Mod Version: 1.1.0, by BirdOPrey5 (IB Staff) BirdOPrey5 is offline
Developer Last Online: Dec 2017 I like it Show Printable Version Email this Page

vB Version: 4.1.10 Rating: (13 votes - 4.92 average) Installs: 88
Released: 11 Jan 2014 Last Update: Never Downloads: 299
Supported Uses Plugins Auto-Template Re-usable Code  

2017 Update - Google Chrome and other browsers are starting to end support for Flash. As Flash gets deprecated and removed from browsers users trying to upload will see the Ajax Uploader instead. Without this add-on the Ajax Uploader will only allow uploading one image at a time. I've tested and this still works on VB 4.2.5 using PHP 5.6.x (I wasn't able to test PHP 7 but it should work on that as well.) Although it wasn't designed for this issue, it does work great to bring back multiple uploads in the post-Flash era.


---

(Old info from 2014...)

If you weren't aware an exploit was found in the flash uploader (uploader.swf) file supplied with vBulletin 4.x. This file was part of the Yahoo YUI 2 package and Yahoo will not be fixing the exploit- Yahoo instructs anyone to remove the file since they no longer use Flash.

Officially vBulletin says it is better to replace the file with an empty file of the same name.
Official announcement here: http://www.vbulletin.com/forum/forum...n-uploader-swf

The problem was however that if you remove the flash uploader the default Ajax uploader did not allow multiple files to be selected at one time (using CTRL+Click or Shift+Click to select multiple files) like the Flash uploader used to allow.

However FranzBanz thankfully posted a template edit on vBulletin.com that uses the power of HTML 5 to restore the ability to select multiple files at once!

The template edit is fairly easy, but I took it a step further and made this into a basic vBulletin modification.

There are a few things you need to be aware of-

1) This does not work on IE9 or lower, these users must upload one at a time. IE10, Chrome, Firefox, Safari, Opera should all be OK. (See here: http://www.w3schools.com/tags/att_input_multiple.asp)

Note: It has come to my attention this will not work in IE at all if IE10 or IE11 are running in IE9 Compatibility mode, which is required on vBulletin for the WYSIWYG editor to work in those versions.

2) There is no easy way to limit the number of files users can choose to upload. If they choose more files then your forum is set to allow they will get an error message when attempting to upload the extra files. Not a big deal but be aware of this limitation, maybe let your users know ahead of time. What I have done is added text that informs the user the max number of uploads allowed. See screenshots for details.

3) Requires vBulletin 4.1.10 or higher, one of the hooks needed doesn't exist in older versions. If you have 4.1.9 or older do the manual template edit linked above.

4) If you need to translate the one phrase used by this mod is a GLOBAL phrase: max_fileassets_bop5

There are no settings for this mod, just install and it is active.

Note- You should go to Admin CP -> Settings -> Options -> Message Attachment Options and do the following:
  • Set Attachment Upload Inputs to a value greater than 1. This will be the max that can be uploaded at once before getting an error.
  • Make sure Attachments Per Post is set higher than or equal to Attachment Upload Inputs
  • Set Asset Manager - Enable to Yes, Ajax Upload by Default


------------------------------------------------------

Please "Mark as Installed" if you use this.
Nominate MOTM if you LOVE it!
Please direct any donations toward FranzBanz on vBulletin.com

Download Now

Only licensed members can download files, Click Here for more information.

Screenshots

Click image for larger version

Name:	asset-manager-multi-files-ss.jpg
Views:	673
Size:	93.1 KB
ID:	147790   Click image for larger version

Name:	image-upload-multi-files-ss.jpg
Views:	675
Size:	26.6 KB
ID:	147791  

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
  #31  
Old 09 Jul 2014, 01:06
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
That is correct- zero Flash.
__________________
-Joe (@BirdOPrey5) Former Moderator. Fighting for a free & independent vb.org.
BirdOPrey5.com - Exclusive VB Mods! (Formerly Qapla.com) | Joe's Ultimate Off Topic
Note - I do not read my PMs often, do not expect quick replies.
Reply With Quote
  #32  
Old 31 Aug 2017, 20:41
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Just wanted to bring this to the top, this still works on VB 4.2.5 in my test.

Now that Google Chrome has started blocking Flash by default the flash uploader built into vB 4.x is also being blocked like any other flash code. Other browsers may be doing the same. If users complain about only being able to upload one file at a time, this is the fix.
__________________
-Joe (@BirdOPrey5) Former Moderator. Fighting for a free & independent vb.org.
BirdOPrey5.com - Exclusive VB Mods! (Formerly Qapla.com) | Joe's Ultimate Off Topic
Note - I do not read my PMs often, do not expect quick replies.
Reply With Quote
  #33  
Old 31 Aug 2017, 21:10
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Yes. It's still working fine on my 4.2.5 forums under PHP7.1.x
Reply With Quote
  #34  
Old 15 Nov 2017, 17:18
keyla31 keyla31 is offline
 
Join Date: Feb 2009
My flash multiple uplaoder was working fine til yesturday, didnt change anything now it doesnt work - 4.2.5
Reply With Quote
  #35  
Old 27 Nov 2017, 20:24
dwwright dwwright is offline
 
Join Date: Feb 2009
Not working in 4.2.5 with php 7.1 on the Manage Attachments dialog.

Multiple file upload still works using the image icon on a new post, but from the Manage Attachments dialog, if I look at the console, I see the following error in Chrome.

Same-origin plugin content from https://myforum.org/forums/clientscr...s/uploader.swf must have a visible size larger than 6 x 6 pixels, or it will be blocked. Invisible content is always blocked.

The message is thrown on the newattachment.php
Reply With Quote
  #36  
Old 27 Nov 2017, 20:32
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Weird because uploader.swf shouldn't be involved at all as this would be instead of the flash uploader. Unfortunately I can't test on PHP 7.1 but if you go to Admin CP -> Settings -> Options -> Message Attachment Options, make sure "Asset Manager - Enable" is set to Yes, Ajax Uploader by default.
__________________
-Joe (@BirdOPrey5) Former Moderator. Fighting for a free & independent vb.org.
BirdOPrey5.com - Exclusive VB Mods! (Formerly Qapla.com) | Joe's Ultimate Off Topic
Note - I do not read my PMs often, do not expect quick replies.
Reply With Quote
  #37  
Old 27 Nov 2017, 23:31
dwwright dwwright is offline
 
Join Date: Feb 2009
Originally Posted by BirdOPrey5 View Post
Weird because uploader.swf shouldn't be involved at all as this would be instead of the flash uploader. Unfortunately I can't test on PHP 7.1 but if you go to Admin CP -> Settings -> Options -> Message Attachment Options, make sure "Asset Manager - Enable" is set to Yes, Ajax Uploader by default.
Already set to that.

I do also get two errors just before the newattachment.php error of:
vbulletin_asset.js:11 vB_Asset :: NaN
vbulletin_asset.js:11 vB_Asset :: NaN

So could be an unrelated javascript error causing it to default to the flash plugin I guess.

Another strange behavior is that once I have images in the bottom tray of the dialog, the Insert Inline shows the correct number of images to insert are correct, but clicking the button does nothing, the image tags are not inserted into the post. If I close and re-open the dialog, the insert images will work at that point.
Reply With Quote
  #38  
Old 29 Nov 2017, 11:42
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Well does removing this mod cause the Ajax uploader to work correctly, albeit one file at a time? That would be the test if it is a mod issue or something else.
__________________
-Joe (@BirdOPrey5) Former Moderator. Fighting for a free & independent vb.org.
BirdOPrey5.com - Exclusive VB Mods! (Formerly Qapla.com) | Joe's Ultimate Off Topic
Note - I do not read my PMs often, do not expect quick replies.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 11:48.

Layout Options | Width: Wide Color: