Attachment Downloads

General discussion of development ideas and the approaches taken in the 3.x branch of phpBB. The current feature release of phpBB 3 is 3.3/Proteus.
Forum rules
Please do not post support questions regarding installing, updating, or upgrading phpBB 3.3.x. If you need support for phpBB 3.3.x please visit the 3.3.x Support Forum on phpbb.com.

If you have questions regarding writing extensions please post in Extension Writers Discussion to receive proper guidance from our staff and community.
User avatar
Fyorl
Google Summer of Code Student
Posts: 27
Joined: Mon Apr 02, 2012 4:51 am
Location: UK
Contact:

Attachment Downloads

Post by Fyorl »

I'm in the process of adding a feature to allow downloading all the attachments in a post and all the attachments in a topic. The files should be archived before the user is prompted for a download but as far as I can tell, none of the archiving libraries is enabled by default in PHP. Should the feature be disabled if there are no archiving options or just download each of the files unarchived?

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 1904
Joined: Thu Mar 02, 2006 4:29 pm
Location: Earth
Contact:

Re: [RFC] Attachment Downloads

Post by DavidIQ »

phpBB has it's own archiving routines available. Check includes/functions_compress.php.
Image

User avatar
Fyorl
Google Summer of Code Student
Posts: 27
Joined: Mon Apr 02, 2012 4:51 am
Location: UK
Contact:

Re: [RFC] Attachment Downloads

Post by Fyorl »

So it seems tar is always supported but anything else is optional. Seems reasonable.

User avatar
Pony99CA
Registered User
Posts: 986
Joined: Sun Feb 08, 2009 2:35 am
Location: Hollister, CA
Contact:

Re: [RFC] Attachment Downloads

Post by Pony99CA »

Why is this an RFC? I see no Request for Comments or detailed proposal here, just a statement that you're working on code and a question. Are you going to edit the first post later?

Steve
Silicon Valley Pocket PC (http://www.svpocketpc.com)
Creator of manage_bots and spoof_user (ask me)
Need hosting for a small forum with full cPanel & MySQL access? Contact me or PM me.

User avatar
bantu
3.0 Release Manager
3.0 Release Manager
Posts: 557
Joined: Thu Sep 07, 2006 11:22 am
Location: Karlsruhe, Germany
Contact:

Re: [RFC] Attachment Downloads

Post by bantu »

Yes, it looks like tar is always available. zip and gz will likely be available too but depend on zlib. So it looks like you should offer all available formats.

I moved this to discussion because it's not in RFC format.

User avatar
EXreaction
Registered User
Posts: 1555
Joined: Sat Sep 10, 2005 2:15 am

Re: [RFC] Attachment Downloads

Post by EXreaction »

Wouldn't it be a good idea to look into a 3rd party library for compression? I thought there was something in Symfony for it (or maybe it was Zend) that worked really well.

User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

Re: [RFC] Attachment Downloads

Post by nickvergessen »

The one which is already available in phpBB works just fine?
Member of the Development-TeamNo Support via PM

User avatar
bantu
3.0 Release Manager
3.0 Release Manager
Posts: 557
Joined: Thu Sep 07, 2006 11:22 am
Location: Karlsruhe, Germany
Contact:

Re: [RFC] Attachment Downloads

Post by bantu »

EXreaction wrote:Wouldn't it be a good idea to look into a 3rd party library for compression? I thought there was something in Symfony for it (or maybe it was Zend) that worked really well.
Since we already have infrastructure for creating packages, that infrastructure should be used. It might make sense to replace that infrastracture with something better. This would should be a different project however and probably won't get high priority if there is no real gain.

User avatar
EXreaction
Registered User
Posts: 1555
Joined: Sat Sep 10, 2005 2:15 am

Re: [RFC] Attachment Downloads

Post by EXreaction »

Good point. If we already have zip support built in anyways that should be enough (everyone can extract either a zip or tar, so that should be fine).

Paul
Infrastructure Team Leader
Infrastructure Team Leader
Posts: 373
Joined: Thu Sep 16, 2004 9:02 am
Contact:

Re: [RFC] Attachment Downloads

Post by Paul »

For at least some archives extracting does not work correctly, IIRC, it was reported a while back by me, and davidMJ couldnt find it back then. It should be somewhere in the bugtracker. I believe it was related to zips created on osX.

Post Reply