Skip to content
This repository was archived by the owner on Jan 1, 2025. It is now read-only.

CORS error #118

Open
Sioweb opened this issue Apr 1, 2019 · 0 comments
Open

CORS error #118

Sioweb opened this issue Apr 1, 2019 · 0 comments

Comments

@Sioweb
Copy link

Sioweb commented Apr 1, 2019

Ho!

wir bekamen folgenden Fehler in der Konsole:

Access to script at 'https://maps.googleapis.com/maps/api/js?key=CODE&language=de' from origin 'https://www.seipp.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource

Der Grund war, dass das Script mit https:// geladen wird, folgender Fix hat den Fehler behoben:

templates/ce_dlh_googlemaps_default.html5

<?php
if($_COOKIE['dlh_googlemaps'] || $this->map['protected']!='1'):
$GLOBALS['TL_JAVASCRIPT'][] = '//maps.googleapis.com/maps/api/js?key=' . $this->map['key'] . '&language=' . $this->map['language'];
$this->map['privacy'] == '';
endif;
?>

Danke für das Modul, funktioniert bei uns auch in 4.7 perfekt.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant