Because it otherwise fails when using /drupal/sites/mysites/...
But the proper way to do this would be to use the libraries module.
See the attached patch (which has not been really tested).
Then it should be possible to get rid of
/themes/default_dark/openlayers_style.css and some stuff in openlayers.install.
| Comment | File | Size | Author |
|---|---|---|---|
| openlayers-implements-libraries0.patch | 875 bytes | drzraf |
Comments
Comment #1
nod_That's awesome, it's actually a 3.x goal.
Could you work out how to use the new libraries API? they have version dependencies and it'd be nice to enforce that.
Comment #2
nod_since it hasn't been tested.
Comment #3
drzraf commenteddo you mean to enforce the use of OL 2.11 over OL 2.10 ?
Comment #4
nod_indeed.
Comment #5
drzraf commentedI was not able to find how to do this.
There are several non-API alternative, using
hook_requirements()orlibrary_detect().On a side note a solution must be given for the css includes/background imports in order to unbundle all the files in
themes/default_dark/img/.Another point I tried to figure out is where exactly are the .js and .css files needed in the module, so we can see where exactly the call to
libraries_load("openlayers");should happen.(also forgot to say that
dependencies[] = librarieswill obviously be needed in the .info file).Comment #5.0
drzraf commentedtypos
Comment #6
m.stentaI think this is fixed. Openlayers uses Libraries API now (and can also use Libraries CDN to load via CDNJS/JSDelivr). Reopen if anything else needs to be done!