I was getting this error when trying to access the OpenLayers settings page: Fatal error: Unsupported operand types in /var/www/drupal/sites/default/modules/openlayers/includes/openlayers.admin.inc on line 36.

I looked at the code and realised it was because I didn't have the Advanced Help module installed. This patch fixes this issue.

CommentFileSizeAuthor
openlayers.admin_.inc_.patch928 bytesAnonymous (not verified)

Comments

phayes’s picture

Status: Needs review » Fixed
shiraz dindar’s picture

Status: Fixed » Needs work

hiya patrick,

fyi, installing this fix created a new error when going to same page:

Fatal error: Call to undefined function openlayers_preset_options() in (snip)\sites\all\modules\openlayers\includes\openlayers.admin.inc on line 52

openlayers preset_ui is enabled.

for now i've resolved by simply enabling advanced help and reverting your patch. just a heads up.

shiraz

phayes’s picture

Could you try again with the latest dev? That's a really weird error since 6.x-1.x-dev does not have openlayers_preset_options being called anywhere in openlayers.admin.inc, and line 52 is a comment..

???

zzolo’s picture

Status: Needs work » Fixed

I am not seeing any errors and I do not have Advanced Help enabled. And after installing advanced_help, everything is still fine. Closing.

Status: Fixed » Closed (fixed)

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

shunting’s picture

Same error as #2 with 6.x-2.x-dev. When I installed advanced_help 6.x-1.2 the error went away.

Drupal 6.19.

tmcw’s picture

shunting: the file /includes/openlayers.admin.inc doesn't exist in OpenLayers 2.x, so you've either installed 1.x, or you're getting a different error.

shunting’s picture

A fresh install solved this.