Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Nick 95 posts 492 karma points
    Jun 14, 2024 @ 19:21
    Nick
    0

    Umbraco GMaps Package: JSON Exception

    Hi,

    I'm using the Gmaps Package here https://marketplace.umbraco.com/package/our.umbraco.gmaps in my Umbraco 12 site, I've configured the API call within google and update the AppSettings accordingly I've enterted the coordinates of the location but recive the following overlay on the map with the backend:

    enter image description here

    And then when I try to render the map on the page, I receive the following JSON error below, can anybody please help me get the map working correctly on my page?

    enter image description here

    This is how I am rendering the map within the page template view:

    @using Umbraco.Cms.Web.Common.PublishedModels;
    @inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage<ContentModels.ContactPage>
    @using ContentModels = Umbraco.Cms.Web.Common.PublishedModels;
    @{
        Layout = "Master.cshtml";
    }
    
    <!-- Section -->
    
    <section class="main">
        <header class="invert accent2 paint orange">
            <h1>@Model.Name</h1>
        </header>
        @await Umbraco.RenderMacroAsync("insertUForm", new { formId = Model.Form?.Id })
        @Model.Value("pageContent")
        @Model.Value("locationMap")
        @Html.Raw(Model.LocationMap.Address.Coordinates.Latitude) 
    </section>
    

    Any help from this great community greatly appreciated as always.

    Thanks

    Nick

  • Nick 95 posts 492 karma points
    Jun 18, 2024 @ 09:38
    Nick
    0

    NUDGE Anybody able to help?

  • Simon Napper 113 posts 347 karma points
    Jun 18, 2024 @ 11:38
    Simon Napper
    100

    I don't know if this is the issue as you've mentioned that you've set it up, but I've seen something similar when the API key isn't quite right or the URL hasn't been added to the HTTP referrers in the Key restrictions.

Please Sign in or register to post replies

Write your reply to:

Draft