hi
after the fix from yesterday (thanks!) i get this error msg Notice: Undefined index: filefield_sources in filefield_sources_field_process() (Zeile 132 von ./all/modules/filefield_sources/filefield_sources.module).
this comes up when i try to upload a picture and for a secound i see a ajax error msg. i have make a pic
| Comment | File | Size | Author |
|---|---|---|---|
| #36 | filefield_sources-filefield_sources_undefined_index-1138380-36.patch | 656 bytes | JaakkoL |
| #32 | 1138380-32.patch | 801 bytes | sammys |
| #13 | filefield_sources_1138380.patch | 780 bytes | camsoft2000 |
| #9 | filefield_sources_1138380.patch | 635 bytes | ts145nera |
| filefieldsource.jpg | 201.89 KB | eule |
Comments
Comment #1
quicksketchThere have been some changes to the settings locations. You may need to edit each file field you have created and re-save it's settings (even without changing anything). Would you check if that solves the problem? This problem should not occur with new fields that you set up.
Comment #2
eule commentedyup works..but the ajax error appers for a secound
Comment #3
quicksketchTry clearing your Drupal caches on the performance settings page. It looks like FileField Sources can't find the callback for displaying the upload progress bar during remote transfers.
Comment #4
steinmb commentedExperienced the same error on a D6->D7 upgraded site. Edit and save all file-field (not only image fields) and the warning goes away.
Comment #5
eliza411 commentedIn case it's useful: with filefield sources 7.x-1.4 working fine, when I enable Video module 7.x-1.x-dev, I consistently get:
Notice: Undefined index: filefield_sources in filefield_sources_field_process() (line 132 of /var/www/drupal/sites/all/modules/filefield_sources/filefield_sources.module).
The error ceases when Video module is disabled. I'm planning to keep it disabled until it has a stable release, but I thought it might be worth mentioning since it erroneously point toward this module.
Comment #6
otx commentedI got the same Undefined index error and your suggestion about re-saving everything and clearing caches seems to work.
Comment #7
bryancasler commentedsubscribe
Comment #8
W.M. commentedIdea by quicksketch works fine. Thanks. Moving now to other D6 -> D7 upgrade issues. It looks like I should have waited more time before upgrading. I should have waited more for the development of better codes (especially those related to CCK fields). I just upgraded yesterday.
Comment #9
ts145nera commentedHello,
I've the same question.
I use D7 with Filefiled_sources to manage image and Video module to manage video.
I have two content type, one with images (managed by filefield_sources, IMCE) and one with video (managed by Video module).
When I upload image all work fine, but when I upload video I've the notice:
I try to fix it with this patch. Please review.
Comment #10
ts145nera commentedComment #11
dqdpatch failed
error message:
@ Bitvise Tunnelier Terminal and patch file token via "wget" and "patch"
Comment #12
dqdpatch applied manually. error message seems to disappear from a brief glimpse so far.
(Can anyone confirm that terminal bash patch doesn't work? Just to know if I did something wrong.)
Comment #13
camsoft2000 commentedDid not work for me, I've tested the change manually and I can confirm it works. I've generated my own version of the patch.
Comment #14
dqdcamsoft2000++
Comment #15
Frederic wbase commentedAplied path from camsoft 2000 and works like a charm!
Comment #16
hugojoe commentedWhen Audiofield module enabled, I got the same error as above:
Undefined index: filefield_sources in filefield_sources_field_process() (line 132 of /var/www/drupal/sites/all/modules/filefield_sources/filefield_sources.module).
Then I download camsoft2000's patch to sites/all/modules/filefield_sources, but failed to apply (git apply -v ). Error shows:
error: sites/all/module/filefield_sources/filefield_sources.module: No such file or directory
Best regards
Hugo
Comment #17
hugojoe commentedI copy the patch to /var/www/drupal, the error disappears.
But the audiofield does not work: screen shows no "Upload | Remote URL | Reference existing | File attach"
Thanks
Hugo
Comment #18
Frederic wbase commented@hugojoe: maybe problem with audiofield?
Comment #19
philbar commentedI'm having this problem as well.
Comment #20
philbar commentedThe patch in #13 did not fix this issue for me.
Also, I'm not using the Video or Audio modules.
Comment #21
Frederic wbase commented@philbar, strange, wich version are you using?
Comment #22
philbar commented7.x-1.4
Comment #23
bserem commentedhad the same issue, until I flushed my caches!
Comment #24
philbar commentedFlushing my caches does not fix the issue for me.
Comment #25
carteriii commentedGuys, I think I see the problem, and I believe the suggested patches earlier in this thread to check the condition a few lines earlier are just hiding the problem.
My source file has the following on line 132:
$enabled_sources = $instance['widget']['settings']['filefield_sources']['filefield_sources'];Note that the array element 'filefield_sources' is being used *twice*. I believe that line of code is just wrong, would never work, and needs to be
$enabled_sources = $instance['widget']['settings']['filefield_sources'];As part of my own testing, I printed out the $instance array, and this is what I got
Note that $instance['widget']['settings']['filefield_sources'] is a valid array with elements of imce, remote, reference, and attach. That seems legit, so I think the proper fix is to remove the duplicate array indexing of ['filefield_sources']['filefield_sources'].
Comment #26
jox commented@carteriii: I can not confirm this. What version of the module are you using? Here - using filefield_sources 7.x-1.4 - it looks like this:
Comment #27
carteriii commentedWow. That's not what I expected anyone to be able to show. I am also using filefield_sources 7.x-1.4.
So there must be some variation in how $instance is being set. I did upgrade from Drupal & filefield_sources 6.x. Could that be it? Did you start with a clean v7 installation? An upgrade from v6 would seem a reasonable/possible cause.
Since I changed line #132 to remove what I saw as the extraneous ['filefield_sources'] index, everything has been running smoothly for me so I haven't looked back. Your variable contents have me worried my change to the source may come back to bite me.
I'll dig a bit more later (can't do much this weekend). Do you know where the ['filefield_sources']['filefield_sources'] is getting built for you (just to help me pinpoint the difference from what I see)?
Comment #28
jox commented@carteriii: Yes, my installation is a pure Drupal 7. I get the undefined Index error for some other image fields that existed before installation of filefield_sources. The one field I'm using filefield_sources on is working correctly.
Did you try the resave/cache-clear thing on your field? You could also try to create a new field only for testing and print out the $instance array for that, to see if there is any difference.
Comment #29
renegaed commentedThank you camsoft2000 ur patch worked!
Comment #30
philbar commentedMy problem was from upgrading to D7 which the field settings were corrupted. I reapplied the settings for my image fields and saved them, and the error is no more.
Comment #31
bdimaggioYep the patch in #13 fixed it. Thanks camsoft2000!
Comment #32
sammys commentedIt appears the check in patch #13 isn't cutting it anymore with 1.4. Here is another patch. I haven't tested this with 7.x-1.x nor have I tested functionality. The error isn't appearing anymore. YMMV functionally.
Comment #33
enekid commentedPatch #14 seems to work OK in 1.4, no error appears, thanks!
Comment #34
chrowe commentedThe fix from #32 seems to have worked for me.
I changed the patch file to use relative links from the module directory and used
patch -p0 < 1138380-32.patch
Comment #35
steinmb commented@sammy pls. reroll #32 with correct paths.
@chrowe p0 patch format is deprecated.
Both pls. read http://drupal.org/node/707484
Comment #36
JaakkoL commentedHere's updated version of #32 with correct paths.
Comment #37
vaccinemedia commented#36 works perfectly. Thanks!
Comment #38
steinmb commentedLet's get this one liner committed.
Comment #39
quicksketchThanks guys, committed. There should be a new release out this week.
Comment #41
Bensbury commentedHi,
What happened to this patch?
I don't see a link to the Dev version of filefield sources, and the latest commit info on the module page reads as 2011-Apr-29 and Last modified: May 11, 2012.
Am I missing something?
I'm getting this error and thought to fix it, or has it been added to the current release but the error still exists?
Thanks.