Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The way the behaviors are declared causes CTools to fail at locating them: it only gets the 'class' and 'parent' subkeys, and builds a (name).class.php file name, which does not exist because the files are named (class).inc.
copying the 'path' and 'file' keys below the 'behavior' key in _openlayers_openlayers_behaviors()
allows CTools to load them from their declared file and installation to succeed.
Comment | File | Size | Author |
---|---|---|---|
#8 | 0001-Fix-the-path-file-declaration-for-behaviors.patch | 1.05 KB | fgm |
#6 | 0001-Fix-the-path-file-declaration-for-behaviors.patch | 1.03 KB | fgm |
#1 | 0001-Fix-the-path-file-declaration-for-behaviors.patch | 1.02 KB | fgm |
Comments
Comment #1
fgmSuggested patch for those who still have to use 7.x-2.0-alpha2 instead of more recent versions.
Comment #3
PolIt's funny because I'm working on that stuff for #1895530: Use the new 'openlayers' element. and #1897328: Implement ctools_plugins_directory for OpenLayers.
I would like to be able to autoload JS and CSS file related to a behavior or a class, but that implies to have them correctly defined.
I don't like to have to define them in the plugin definition, I think it would be better if we can find a way to detect the class filename and autoload JS and CSS from it.
For your patch, you should use the 7.x-2.x-dev branch !
Comment #4
fgmHi: I think this has been fixed in later versions (although I didn't checkà, but for compatibility reasons (OL taxonomy), we needed to use alpha2 and not a more current version. Hence the patch agains alpha2 instead of 2.x. Maybe it can help with later versions too...
Comment #5
PolIt's also in my todo list to fix the OpenLayers Taxonomy module, if you can tell me what's wrong, I can work on it!
Comment #6
fgmMaybe there's some funky reference reuse in the patch... retrying a bit differently.
Comment #8
fgmActually, as MacWeber noticed, I forgot the return $ret at the end.
Comment #9
PolI think it would be a good idea to fix OpenLayers Taxonomy too, if you can provide some informations about what's not working with the latest beta, I can try to fix it !
Comment #10
Mac_Weber CreditAttribution: Mac_Weber commented@Pol OL Taxonomy is outdated and returning many errors.
If you install it and test with the included demo Feature you can see the error messages going to OL maps listing page.
If you are available on IRC we can chat better there.
Comment #11
Mac_Weber CreditAttribution: Mac_Weber commentedPatch #8 fix the issue on OL alpha2 and make it possible to use OL Taxonomy.
Some error messages are still being returned from OL Taxonomy, but they have nothing to do about this bug report.
Comment #12
PolComment #13
fgmHmm, I don't see something like my patch in the commit log. Did you fix it another way ?
Comment #14
PolThis doesn't exists anymore in 7.x-2.x.
Each behaviors are not defined in a file and even the function
_openlayers_openlayers_behaviors()
doesn't exists.Comment #15
fgmAh, great ! Thanks for the followup.