Hello,

After upgrade from drupal 6 to 7, I have a problem with FileField source. In drupal 6, I used IMCE Image fields. I ran content migrate to transform IMCE Image field into Image field, then enbled FileField source to add image on this field with IMCE.
When I browse files on a directory with IMCE called throw ckeditor, I see all files existing in this directory.
When I browse files on the same directory with IMCE called by image field, I don't see all files existing in this directory. It seems that I don't see files that were uploaded throw ckeditor before the migration (the files uploaded after the migration are displayed in IMCE, even when they were added with ckediror).

How can I do to see all files ? Did I miss something in the settings ?

Comments

kendouglass’s picture

If a file wasn't initially uploaded via IMCE or a file field, they won't appear in the files table in the Drupal database. Thus, IMCE won't see them.

I suggest that you re-upload all the not-shown files. To speed that task, you can enable plupload on a file field. Or for IMCE, you might try imce_swfupload

lucuhb’s picture

Thank for your response. The problem is that I have several hundred directories so it seems difficult to put everything in hand, even with modules that you suggested.

Is there a script to automatically add references to these files in the database ?

jenlampton’s picture

Category: Support request » Bug report

If a file wasn't initially uploaded via IMCE or a file field, they won't appear in the files table in the Drupal database. Thus, IMCE won't see them.

I think you are misunderstanding. IMCE is a tool that allows you to browse files on disk - regardless of whether they are in the files table in the database or not. There are many other tools for Drupal that allow accessing files that have been manually uploaded, but IMCE is one of the few that let's you see what's there, even if it's not in the files table.

I'm having the same problem as reported here, I can see my directories in the IMCE file browser, but not the files within. I expect there is a bug in sources, since on the IMCE page it says to use the Use the IMCE for File Field module now, instead.

jefftrnr’s picture

The filefield_source_imce_custom_scan_full() function seems to find all of the files and unsets any that aren't already included in the db. What would be great is an option to add any unkn files to the db as it scans. Is that feasible?

jefftrnr’s picture

Perhaps instead of unset(), the way to add the file to the db would be:

filefield_sources_save_file($sql_uri_name . $file['name'], array(), $scheme . '://' . $dirname);
quicksketch’s picture

Title: IMCE not displaying all files when called throw fileField Sources » IMCE not displaying all files when called through fileField Sources
Version: 7.x-1.9 » 7.x-1.10
Category: Bug report » Feature request