[MOD] File Upload Module (v0.1) -- Looking for testers

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 06-20-2007, 07:52 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi All,

I'm looking for anyone that has a development server that will be interested in alpha testing a file upload module. It will basically allow submissions to include a file attachment. You can control by Mime Type which files you allow to be uploaded and the max file size. All files are stored locally as file_xxxx.dat -- where xxxx is the link id. This is to prevent file name collisions from other entries. However, when the file is downloaded, it is saved as the original name that was uploaded.

It's still pretty early in its stages and I'm testing locally. However, it can be used to upload the following file types:
- MS Word
- MS Excel
- EXE files (not recommended)
- Photoshop files
- PDF
- EPS
- Real Audio, Real Video, Real Media
- ZIP files
- Flash SWF
- Flash FLA
- AVI, Quicktime Mov, MPEG
- JPG, BMP, PICT, PNG, GIF files
- HTML
- Plain text

and more can be added by including the file's mime type in an array. Each mime type has a corresponding icon for easy identification.

I've attached a screenshot of the module working so you can see what it will possibly look like.

Best,
Cent
Attached Thumbnails
[MOD] File Upload Module (v0.1) -- Looking for testers-fileupload_screenshot.jpg  
Reply With Quote
  #2 (permalink)  
Old 06-21-2007, 03:45 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
If anyone is up to test it on a development server, you can download the File Upload module (v0.1) here.

The default is link_field1, so you may want to change. If you do, change module_fileupload_filename_field and [module_fileupload_filename_field2[/b] in the settings file to match as commented.

In file_upload_main.php look for the function called file_upload_process_handler. The allowedMimeTypes is an array of file types you will allow to be uploaded to your server. This will eventually be moved into the settings file at some point. Though for some reason I can't put it in that file and still read it during the function execution.

As it stands now (by default), you can upload PDF, ZIP and HTML files. You can add to this by copying and pasting mime types from the allMimeTypes variable in the file_upload_preview_handler function.

You can see it working (to some degree) at: here. And what an entry might look like here.

I don't think its quite ready for prime time yet. However, let me know how it works for you and things you think I should add or change.

Best,
Cent
Reply With Quote
  #3 (permalink)  
Old 06-21-2007, 03:56 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
You´ve heard my voice!
Thank you, I´ll definitely test the mod in the next few days.

Will it work with images as the image upload module?

Last edited by tbones; 06-21-2007 at 03:57 PM. Reason: Way of dealiing with images
Reply With Quote
  #4 (permalink)  
Old 06-21-2007, 05:44 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi tbones,

You can use it to upload any type of file as long as you know the mime type you're expecting. Unlike the image upload module, this module simply allows users to download the file... there is no image preview/thumbnail.

Best,
Cent

Quote:
Originally Posted by tbones View Post
YouŽve heard my voice!
Thank you, IŽll definitely test the mod in the next few days.

Will it work with images as the image upload module?
Reply With Quote
  #5 (permalink)  
Old 06-21-2007, 06:05 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
Can both modules be used simultaneously?

Quote:
Originally Posted by cent View Post
Hi tbones,

You can use it to upload any type of file as long as you know the mime type you're expecting. Unlike the image upload module, this module simply allows users to download the file... there is no image preview/thumbnail.

Best,
Cent
Reply With Quote
  #6 (permalink)  
Old 06-21-2007, 06:55 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Yes. Unfortunately each module requires their own extra link field. However, the default link field for each module is link_field1. So be sure to set the link fields accordingly and you can use them together. I would suggest however, to first try the file upload on a development site as its still pretty early in its development life.

Best,
Cent


Quote:
Originally Posted by tbones View Post
Can both modules be used simultaneously?
Reply With Quote
  #7 (permalink)  
Old 06-21-2007, 09:28 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 168
Cent, I think the functionality of this module would be useful for 2 areas -

1) Within Stories
2) within user profiles (users can upload resumes to their profile page, etc.)

Ash, is this something that we can also integrate into user profiles?

I think Pligg could benefit tremendously from enabling more informative user profile pages (eg. About me section, resumes, etc.)

Thx
-A

Last edited by aaronpais; 06-22-2007 at 01:19 PM.
Reply With Quote
  #8 (permalink)  
Old 06-22-2007, 12:07 AM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
While I haven't tried it, it can be tailored to receive the field containing the data by directly including the field in the check_actions.

Ie. check_actions('file_upload_process', yourformfield). Whereas yourformfield could either be a link_field or a custom field. It doesn't really matter. The other modification would be that it would need to point to the right DB table. Right now, it just points to table_links.

That would require a slight modification to the module, though its quite possible.

Best,
Cent
Reply With Quote
  #9 (permalink)  
Old 06-22-2007, 03:09 AM
not2serious's Avatar
Pligg Donor
Pligg Version: 1.1.5
Pligg Template: Westie
 
Join Date: Apr 2007
Location: East Coast, USA
Posts: 229
Sounds like a nice idea.

However, I do not have a development machine at this time. I will look forward to a bata version, maybe I can test at that point.
Reply With Quote
  #10 (permalink)  
Old 06-22-2007, 09:40 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
I´ve tried to install with v9.5:

- I´ve copied the subfolder file_upload to ./modules
- I´ve changed to <form action="{$URL_submit}" method="post" name="thisform" id="thisform" enctype="multipart/form-data"> at submit_step2.tpl
- I´ve placed the code above <div class="top"> at editlink.php
- I´ve activated the module Profile Extra Fields v0.2

and did the rest as mentioned in Readme.

Result: I don´t get any extra field. Does it have to be defined somewhere?


Edit: I left ./modules/file_upload/file_upload_settings.php untouched.

Last edited by tbones; 06-22-2007 at 10:10 PM. Reason: Edit: No changes in settings
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Upload Module (File and Image Attachment) Yankidank Free Modules 268 02-03-2012 12:19 PM
Index.php won't open to install nigelnix Questions and Comments 8 04-15-2010 06:19 PM
[MOD] File Upload Module for 9.8.2 Is here for download :) Redux Questions and Comments 7 01-27-2008 09:21 AM
[MOD] File Upload Module -- seeking requests for features cent Questions and Comments 2 08-11-2007 05:39 AM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development