@Cem It’s a little of both. FF Matrix builds it’s array using what the various field types build. File field stores data in it’s own array currently (soon will only be a file name) which is in turn is stored by FF Matrix. Hope that makes sense.
When I upload a file that alredy exists, I get the following error:
Notice: Undefined offset: 1 in /home/xxx/public_html/backend/extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 411
after that the stylesheet is out of place, but when I refresh everything is in place again. file uploaded, thumb created…
it’s a minor bug, just to let you know…
I needed to use this extension on a MSM enabled site, and found that in the custom field settings, it doesn’t denote which site you’re on for file upload destinations.
I changed the select_upload_destinations function to the following to get Site labels. (i did not add any default settings however. I’ll polish it up and repost when I do that).
* just added the site specific name and labels to the query so it selects that info as well, ordering by site_id, then name.
$dls = $DB->query("SELECT exp_upload_prefs.id, exp_upload_prefs.name, exp_sites.site_name, exp_sites.site_label, exp_sites.site_id FROM exp_upload_prefs, exp_sites WHERE exp_sites.site_id = exp_upload_prefs.site_id ORDER BY exp_sites.site_id, exp_upload_prefs.name ASC"); foreach($dls->result as $dl) { $selected = ($dl['id'] == $current_option) ? " selected=\"true\"" : ""; $block .= "<option value=\"{$dl['id']}\"$selected>{$dl['site_label']} - {$dl['name']}</option>"; }
• New feature: Select an existing file
• Delete or de-associate: Now that you can use an existing file, you can either remove a file from the server (even if other entries use it) or just remove it from use with a particular entry via a new delete interface
• MH File compatability: can now be a drop in replacement for single file uploads. NOTE!This will not work with fields that have multiple files uploaded. You will need to migrate those fields to an FF Matrix
• File data is no longer stored as an array
• Thumbnails are automatically create for use in the CP
• “thumbs” directory under the upload directory for the field will be created to store the thumbnails
• Image detection has been improved for thumbnail display - only GIF/JPG/PNG will show thumbnails
Before I update, are there any compatibility issues with updating over the previous version due to how the data was stored in an array and now is not? Will my existing file upload data still work fine or be converted over to the new storing method?
I’ve uploaded this to 2 different installs and seem to have some strange behavior. On one site which has both a FF Matrix field(w/nGen File) and a seperate nGen File Field, when I click “Use an Existing File” the link seems to jump to the top of the page, but nothing happens.
On the 2nd install, using just a FF Matrix(w/nGen File) the 1st row works perfectly. When I try to add a second row, I get the same behavior as above. If I fill in another field in the 2nd row and save, I can then use the nGen File’s “Use an Existing File” control. The options that pop up next to the trash icon (also really nice idea) also fail under the same conditions.
I’ve uploaded this to 2 different installs and seem to have some strange behavior. On one site which has both a FF Matrix field(w/nGen File) and a seperate nGen File Field, when I click “Use an Existing File” the link seems to jump to the top of the page, but nothing happens.
On the 2nd install, using just a FF Matrix(w/nGen File) the 1st row works perfectly. When I try to add a second row, I get the same behavior as above. If I fill in another field in the 2nd row and save, I can then use the nGen File’s “Use an Existing File” control. The options that pop up next to the trash icon (also really nice idea) also fail under the same conditions.
yes, if you want to choose an existing file within a matrix, you can only do it with the top row…
but.. it’s working… hell yeah! woudn’t have thougth this possible…
gREAT extension!!
I was getting that same error too. It seemed like if I went into each existing entry and re-saved that it would not show that error anymore. But it was not consistent.
I was getting that same error too. It seemed like if I went into each existing entry and re-saved that it would not show that error anymore. But it was not consistent.
that’s only if I’m logged in.. maybe that helps…
cheers
stefan
The caffeine is kicking in I now see the new link for 0.9.5. The new features…I cannot say enough how usable this one is, how did EE ever live without it, good job!!!
Two things:
1. I get open base restriction warnings, I assume that I need to loosen up on my PHP.ini if I want the thumbnail to appear?
2. Will Mark’s old file extension convert over, I started using his back when it came out and now I want to use File Field exclusively but don’t want to destroy all the work I have done.
I’m getting really strange errors when trying to upload a file in the new extension version. Despite these errors, the file is uploaded.
Notice: Undefined variable: file_path in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 523
Notice: Undefined index: dirname in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 710
Notice: Undefined variable: im in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 724
Warning: imagesx(): supplied argument is not a valid Image resource in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 724
Notice: Undefined variable: im in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 725
Warning: imagesy(): supplied argument is not a valid Image resource in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 725
Warning: Division by zero in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 740
Warning: Division by zero in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 750
Notice: Undefined variable: im in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 758
Warning: imagecopyresampled(): supplied argument is not a valid Image resource in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 758
Warning: mkdir() [function.mkdir]: Permission denied in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 761
Warning: chmod() [function.chmod]: No such file or directory in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 762
Warning: filemtime() [function.filemtime]: stat failed for /thumbs/_thumb.jpg in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 766
Warning: chmod() [function.chmod]: No such file or directory in extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php on line 772
Warning: Cannot modify header information - headers already sent by (output started at extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php:523) in core/core.functions.php on line 726
Warning: Cannot modify header information - headers already sent by (output started at extensions/fieldtypes/ngen_file_field/ft.ngen_file_field.php:523) in core/core.functions.php on line 296