Open BenjaGramsch opened 2 years ago
I have the same issue. Any solution to this problem?
Could you check to see if there are any console errors or warnings in your browser when the map should be rendering? I anticipate there's something that will have to be changed with the render logic on a loop and merge question.
Hi, I have been working with the Javascript script that displays a Google Maps and collect the coordinates of the location, the code works perfectly, but I tried to add it to a Loop and Merge and now the map doesn't display anymore.
Here is a picture of how it looks when the map is on the Loop and Merge![image](https://user-images.githubusercontent.com/57944945/162924050-46a4d654-50ef-440d-bb56-1495d637fdbe.png)
This is the code I'm using
`Qualtrics.SurveyEngine.addOnload(function() { initGoogleMapsQuestion("#"+this.questionId, this.getQuestionContainer(), { // Map Options, set these! See Map Options in Option Documentation Section options: { center: { lat: 47.377749, lng: 8.540780,
}, zoom: 10, }, // Marker Options, set these! markers: [ // First Marker { // See Marker Options in Option Documentation Section options: { title: "Location", draggable: true, label: "1", }, autocomplete: { // If true, an autocomplete will show. enabled: true, // The label shown for the autocomplete field label: "Residence location", // Styles for the label labelCss: "padding-left: 0; padding-right: 0;", // Text to show if an invalid location is selected invalidLocationAlertText: "Please choose a location from the search dropdown. If your location doesn't appear in the search, enter a nearby location and move the marker to the correct location.", }, },
], }); });
Qualtrics.SurveyEngine.addOnReady(function() { /Place your JavaScript here to run when the page is fully displayed/
});
Qualtrics.SurveyEngine.addOnUnload(function() { /Place your JavaScript here to run when the page is unloaded/
});`