This was originally discovered in #2600834: Existing grey geometry missing from add/edit area ~FarmOS installed in subdirectory and is also a follow-up to #2543622: Do not use absolute URL in default Openlayers sources

It seems that the URLs of the Openlayers JSON sources that are automatically generated by this module do not work when Drupal is installed in a subdirectory.

This is because line 21 of views_geojson.default_openlayers_sources.inc uses the url() function:

        $ol_source->options = array(
          'url' => url($view->display_handler->get_url(), array('absolute' => FALSE)),
        );

Comments

m.stenta created an issue. See original summary.

m.stenta’s picture

Title: Auto-generated Openlayers sources don't work when Drupal is installed in subdirectory » Do not use url() in default Openlayers sources
Status: Active » Needs review
StatusFileSize
new693 bytes

Patch attached!

  • Pol committed 9e4d8a0 on 7.x-1.x authored by m.stenta
    Issue #2606092 by m.stenta: Do not use url() in default Openlayers...
m.stenta’s picture

Status: Needs review » Closed (fixed)

Committed and included in the latest release. Thanks @Pol!