Happy New Years everyone. I'm new to Drupal, and I think it absolutely rocks.

I'm running Drupal 6.15 for a client, and getting the following error:

warning: Illegal offset type in /home/client/web_root/drupal/modules/system/system.module on line 885.

Here's line 885. I'm using the Zeropoint Theme. Any thoughts on what's causing this error and how to resolve it?

      // Give the scripts proper path information.
      $scripts = array();
      foreach ($themes[$key]->info['scripts'] as $script) {

        //This is line 885
        $scripts[$script] = dirname($themes[$key]->filename) .'/'. $script;

      }
      $themes[$key]->info['scripts'] = $scripts;
      // Give the screenshot proper path information.
      if (!empty($themes[$key]->info['screenshot'])) {
        $themes[$key]->info['screenshot'] = dirname($themes[$key]->filename) .'/'. $themes[$key]->info['screenshot'];
      }
    }

Comments

natedawg5969’s picture

Having Same issue!!!

please help....

However, I am getting two warnings;

* warning: Illegal offset type in ../htdocs/drupal-6.15/modules/system/system.module on line 885.
* warning: Invalid argument supplied for foreach() in ../htdocs/drupal-6.15/modules/system/system.module on line 876.

mjk73’s picture

I haven't resolved this yet NateDawg, but I'll be sure to update this thread when/if I do. I'd be psyched if you'd do the same. Two heads are better than one, as the saying goes.

vodoleq’s picture

Having Same issue :
warning: Invalid argument supplied for foreach() in \modules\system\system.module on line 876.
Were you able to fix the problem. thanks !

mjk73’s picture

I'll post here if I ever do.

What theme are you using?

vodoleq’s picture

Acquia Marina 6.x-1.9 and Drupal 6.14
strange is that I have not touched anything on modules and themes and this error show up

natedawg5969’s picture

Hey...

I just did the security upgrade from 6.15-6.16 and was hoping this would be one issue resolved in the upgrade. Still get the same Error:

warning: Illegal offset type in /modules/system/system.module on line 885.

HAS ANYONE FOUND A FIX?! My .info file are correct, i double checked those a bunch of times.

Any help would be great.
Thanks

blowski’s picture

I had the same problem until I noticed that my .info file for the theme should look like:
stylesheets[all][] = style.css

Notice the extra set of empty square brackets.

puya’s picture

Thanks a lot blowski .. right on the point

mrcroc’s picture

Same problem :

warning: Illegal offset type in /home/client/web_root/drupal/modules/system/system.module on line 885

Is anyone resolve it ?
I don't find any solution on the web !

stefan93’s picture

i had the same error
it was in my theme-name.info
syntax error while i tried to add .js file
ex:scripts[]= js/earthMaps.js (this is the right syntax actually)
i hope it help

sylvain lecoy’s picture

Resolved by adding the following syntax in my theme info:

stylesheets[all][] = screen.css

scripts[] = theme.css

kristin.e’s picture

The above adding of '[]' worked for me too. Add it to theme-name.info file.
Thanks all!