Hi there... i ran into this bug when attempting an end result of Primary links being created from terms horizontally across my top nav.

I have Views installed and if i enable: Default Node view: taxonomy_term (default)

I get:
# warning: Invalid argument supplied for foreach() in /var/www/dstic.com/sites/all/modules/views/includes/handlers.inc on line 807.
# warning: Invalid argument supplied for foreach() in /var/www/dstic.com/includes/common.inc on line 1597

If i disable Taxonomy menu and flush caches, then the error goes away.

On a side note, i am also using pathauto but with pathauto disabled i can reproduce the above so i dont think it's related (buy maybe worth mentioning).

Any ideas how to fix this?

thank you for a very useful module.

CommentFileSizeAuthor
#9 views_invalid_argument.patch392 bytesfernao

Comments

indytechcook’s picture

Thanks, I'll take a look.

indytechcook’s picture

Version: 6.x-2.1 » 6.x-2.2
Status: Active » Fixed

This is fixed in the newest version. Sorry, some untested code found it's way into the stable release.

zigx’s picture

wow, thanks for such a quick fix!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Hadrien KOHL’s picture

Same issue with 2.3 version.

jvieille’s picture

Category: support » bug
Status: Closed (fixed) » Active

Subscribe
Change issue setting back to active

jvieille’s picture

Version: 6.x-2.2 » 6.x-2.3
fernao’s picture

same here :/

even when I delete the view, the message still appearing...

but we're using 6.x-2.5

fernao’s picture

Status: Active » Needs review
StatusFileSize
new392 bytes

I've looked at line 807 and realized that an array was coming with no values... and was just passing, directly, right to the foreach (what raises a php error).

So, I've created a patch for that case, because the error handling at line 802 was letting this case to go on, empty...

I simply took off the $str var check of that line, because all the times it was filled, but not the array...

Well, for me, it worked.

[]s

indytechcook’s picture

fernao, that's patching views. Has anyone looked in that module for an issue? There is no direct integration between Taxonomy Menu and views. Taxonomy Menu just creates the URL and then Views does everything else.

Sorry I've been MIA. Can one of you give me a more detail explanation of your setup of taxonomy menu and the view so I can attempt to reproduce.

Heilong’s picture

Hi everyone,

I got the same problem after activating the default view taxonomy_term.
Here are the errors I got :

* warning: Invalid argument supplied for foreach() in (...)/sites/all/modules/views/includes/handlers.inc on line 807.
* warning: Invalid argument supplied for foreach() in (...)/includes/common.inc on line 1606.
* warning: Invalid argument supplied for foreach() in (...)/sites/all/modules/views/includes/handlers.inc on line 807.
* warning: Invalid argument supplied for foreach() in (...)/includes/common.inc on line 1606.

By the way I disabled and uninstalled the Pathauto and Taxonomy menu module, and I still have the warnings displayed.

Then I disabled the taxonomy_term default view and the warnings disappeared. So, I exported the same view from a previous drupal installation, when I saved the view, the menu generated by taxonomy menu disappeared.

Taxonomy menu : V 6.x-2.3
Views : V 6.x-2.5
Pathauto : 6.x-1.1

fernao’s picture

sorry, I'm posting in a wrong forum, because I'm not usign taxonomy menu... but I think this can be passed to views...

really sorry.

k3vin’s picture

+1

indytechcook’s picture

Status: Needs review » Closed (won't fix)

This issue was with the views module not taxonomy menu. @fernao, did you ever get what you needed

startuplab’s picture

I'm having this same exact problem: here are my errors

* warning: Invalid argument supplied for foreach() in /home/content/04/4760604/html/modules/acquia/views/includes/handlers.inc on line 807.
* warning: Invalid argument supplied for foreach() in /home/content/04/4760604/html/includes/common.inc on line 1607.
* warning: Invalid argument supplied for foreach() in /home/content/04/4760604/html/modules/acquia/views/includes/handlers.inc on line 807.
* warning: Invalid argument supplied for foreach() in /home/content/04/4760604/html/includes/common.inc on line 1607.

It appears that when i disable the taxonomy_term view that the errors go away.

Can anyone help?

startuplab’s picture

Please! Anyone?????

startuplab’s picture

Anybody out therrrrrrrrrrrrrrrrrrrrrreeeeeeeeeeeeee?

indytechcook’s picture

startuplab, please read through the comments are see that it's an issue with views and not taxonomy menu. There is a patch on comment #9 that may be able to help.

THis issue has been marked as won't fix because it's an issue with views. Please pursue this issue there.

emilyf’s picture

did anyone here post this to views? if so, link please?

emilyf’s picture

here's another similar issue actually posted to views in case anyone needs it: http://drupal.org/node/407538