Closed (duplicate)
Project:
Calendar
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
16 May 2007 at 04:22 UTC
Updated:
24 Jan 2008 at 11:46 UTC
Jump to comment: Most recent file
Comments
Comment #1
kaw3939 commentedHello,
I receive the same error. Just thought you should know.
Comment #2
jiangxijay commentedI get the following error when selecting View type: Tagdelic ...
warning: Invalid argument supplied for foreach() in /home/ sites/all/modules/calendar/calendar.module on line 1201.
Modules:
Calendar 5.x-1.x-dev (packaged 2007-10-12)
Tagadelic views 5.x-1.x-dev (packaged 2007-07-28)
Tagadelic 5.x-1.x-dev (packaged 2007-09-03)
Comment #3
jiangxijay commentedI would add that, when I change the view type to, say, Teaser, the error does not appear. Strange ...
Comment #4
marcoBauli commentedadding my warning to the list:
warning: Invalid argument supplied for foreach() in /home/tm/public_html/drupal/sites/all/modules/calendar/calendar.module on line 1204.
Latest Calendar, Tagadelic and Tagadelic Views modules.
Comment #5
marcoBauli commentedhere's a small workaround that fixes the warning:
Comment #6
misterlawrence commentedHi Marco,
This is the exact problem I am having as well. I would like to implement your solution, but can't quite figure out what I am supposed to do with the snippet you provided.
I imagine that I should include this snippet in the text of the calendar.module. Is that correct? If so, where does it go in the module, and is it in addition to the other parts of the module, or is it to replace a particular portion of the module?
Any help would be appreciated!
Comment #7
akasman commentedmisterlawrence,
I replaced these, existing lines:
+ foreach ($args as $delta => $arg) {
+ if (!in_array($delta + $bump, calendar_arg_positions($view)) && !empty($arg)) {
+ array_push($parts, $arg);
with these ones:
- if(is_array($args)) {
- foreach ($args as $delta => $arg) {
- if (!in_array($delta + $bump, calendar_arg_positions($view)) && !empty($arg)) {
- array_push($parts, $arg);
- }
(Of course not including the diff + and - signs). That did it for me.
Hope that helps.
Comment #8
douggreen commentedI'm switching the project issue queue for this, since the fix for issue is against the calandar module and not tagadelic_views. I'm also attaching the patch (instead of having it inline) and marking as CNR.
Comment #9
misterlawrence commentedakasman and Marcos,
Thank you both so much for your kind replies. It does indeed work...like magic (to a non-programmer like me!).
Take care,
David
Comment #10
karens commentedMaybe a duplicate of http://drupal.org/node/212040.