Posted by mallet on December 24, 2009 at 6:06pm
2 followers
Jump to:
| Project: | Flash Node |
| Version: | 6.x-3.0 |
| Component: | User interface |
| Category: | bug report |
| Priority: | minor |
| Assigned: | Unassigned |
| Status: | needs work |
Issue Summary
I have a production site where users can upload flash files. but I still review files before putting the file on the site.
I have double checked flash nodes files settings option as well as Settings for authenticated user to be set to only accept SWF files and I can confirm it accepts any files despite the settings to only accept SWF files.
Have I miss another setting some where?
Comments
#1
Sorry. Forgot to enable SWF tools and is working the way I wanted it. Keep up the great works guys.
#2
I have SWF tools enabled along with FlashNode, and users are still able to create nodes with non SWF/FLV uploads, regardless of what my allowed extensions are set to. I hope I don't have to edit the module code to force validation before submit... Any suggestions?
#3
As time was of the essence, I've temporarily added the most basic check to the flashnode_validate() function in the module that rejects node creation if the file is not SWF or FLV:
<?phpif (substr($_FILES['files']['name']['flashfile'], -3) !== 'swf' && substr($_FILES['files']['name']['flashfile'], -3) !== 'flv') {
form_set_error('flashfile', t('Only <strong>.swf</strong> and <strong>.flv</strong> files are allowed. You\'ve tried to upload a <strong>.' . substr($_FILES['files']['name']['flashfile'], -3) . '</strong> file.'));
}
?>
Would still like to know what's going wrong here in the first place. Thanks.