New installations have no galleries yet. Check for that.

gazelle - April 1, 2006 - 19:19
Project:shazamgallery
Version:4.7.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

Installed Drupal4.7RC. Installed CVS version of Image Module, 4.7 view module & shazamgallery 4.7. When I go to create an image I get this error message:

Invalid argument supplied for foreach() in /home/mysite/public_html/drupal/modules/shazamgallery/shazamgallery.module on line 205.

The code for line 205-207 is the folowing.

foreach (shazamgallery_get_galleries() as $gallery) {
        $options[$gallery->nid] = $gallery->title;
      }

#1

Bèr Kessels - April 4, 2006 - 12:40
Title:Invalid argument supplied for foreach()» New installations have no galleries yet. Check for that.

We must cehck the existance of any galleries before we call these into the foreach.

#2

gazelle - September 24, 2009 - 16:04
Title:New installations have no galleries yet. Check for that. » New installations have no galleries yet. Check for that.
Status:active» closed
 
 

Drupal is a registered trademark of Dries Buytaert.