Attached patch try to detect if '$feat['icon']['iconUrl']' is a Drupal relative path, if yes, attach the site base_path()

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

paolomainardi’s picture

revagomes’s picture

+1

paolomainardi’s picture

up

paolomainardi’s picture

Feedback ?

Perignon’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: +base_path
FileSize
690 bytes

This needed to be rerolled against the current dev. There was a release on this module last month.

I also cleaned up the patch to only address the issue here. There were some formatting changes in the first page.

Putting to RTBC as this works and I made no changes to the code from the first patch.

jenlampton’s picture

Status: Reviewed & tested by the community » Needs review
FileSize
845 bytes

After entering a relative URL for the marker icon /sites/default/files/marker.svg this patch made my markers disappear, as it added a second leading slash to the URL for the image: //sites/default/files/marker.svg.

I've rerolled the patch to check if both base_url() and a relative path include a leading slash, and if so, not include them both.