Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. F12 console JavaScript browser errors when browsing to a WIndows 2012 website

F12 console JavaScript browser errors when browsing to a WIndows 2012 website

Scheduled Pinned Locked Moved Web Development
csharpjavascriptsysadminwindows-admindebugging
2 Posts 1 Posters 8 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Stephen Holdorf
    wrote on last edited by
    #1

    I have deployed an ASP .NET application with a JavaScript Google Map on the home page to a Windows 2012 website. Now when I browse to the application it comes up fine except the Google Map never loads. One thing that does work is if I publish it as a Web Application and using localhost works. It's just when it's published as a website to IIS is where it fails. As a WebSite on the F12 Console windows debugger here are the errors I'm getting: SEC7120: Origin http://mymachinename not found in Access-Control-Allow-Origin header. SCRIPTING7002: XMLHttpRequest: Network error 0X80700013, Could not complete operation due to error 80700013. getPreferences failed when constructing GPToolsService: undefined

        var map;
    
        MoW.ready(function () {
            map = new MoW.Map({
                target: 'MoWmap'
            });
        });
    
        window.onload = function () {
    
            MoW.ready(function () {
    
                if (document.getElementById('<%= KMLOPString.ClientID %>').value !== "") {
                    var overlayPropertiesOP = {
                        "name": "Openations KML",
                        "url": document.getElementById('<%= KMLOPString.ClientID %>').value,
                        "type": MoW.protocols.KMLProtocol.TYPE.STRING,
                        "description": "Demonstrating KML overlay",
                        "mapTypeId": "google.map.mapTypeId.ROADMAP"
                    };
    
                    var newOverlayObjectOP = MoW.Factory.createKMLOverlay(overlayPropertiesOP);
    
                    map.addOverlay(newOverlayObjectOP, {
                        showAlert: true
    
                    });
    
       //             map.setBasemap(MoW.Basemap.ID.ROADMAP);
                }
    
                if (document.getElementById('<%= KMLESString.ClientID %>').value !== "") {
                    var overlayPropertiesES = {
                        "name": "Exercises KML",
                        "url": document.getElementById('<%= KMLESString.ClientID %>').value,
                        "type": MoW.protocols.KMLProtocol.TYPE.STRING,
                        "description": "Demonstrating KML overlay",
                        "mapTypeId": "google.map.mapTypeId.ROADMAP"
                    };
    
                    var newOverlayObjectES = MoW.Factory.createKMLOverlay(overlayPropertiesES);
    
                    map.addOverlay(newOverlayObjectES, {
                        showAlert: true
    

    </x-turndown>

    S 1 Reply Last reply
    0
    • S Stephen Holdorf

      I have deployed an ASP .NET application with a JavaScript Google Map on the home page to a Windows 2012 website. Now when I browse to the application it comes up fine except the Google Map never loads. One thing that does work is if I publish it as a Web Application and using localhost works. It's just when it's published as a website to IIS is where it fails. As a WebSite on the F12 Console windows debugger here are the errors I'm getting: SEC7120: Origin http://mymachinename not found in Access-Control-Allow-Origin header. SCRIPTING7002: XMLHttpRequest: Network error 0X80700013, Could not complete operation due to error 80700013. getPreferences failed when constructing GPToolsService: undefined

          var map;
      
          MoW.ready(function () {
              map = new MoW.Map({
                  target: 'MoWmap'
              });
          });
      
          window.onload = function () {
      
              MoW.ready(function () {
      
                  if (document.getElementById('<%= KMLOPString.ClientID %>').value !== "") {
                      var overlayPropertiesOP = {
                          "name": "Openations KML",
                          "url": document.getElementById('<%= KMLOPString.ClientID %>').value,
                          "type": MoW.protocols.KMLProtocol.TYPE.STRING,
                          "description": "Demonstrating KML overlay",
                          "mapTypeId": "google.map.mapTypeId.ROADMAP"
                      };
      
                      var newOverlayObjectOP = MoW.Factory.createKMLOverlay(overlayPropertiesOP);
      
                      map.addOverlay(newOverlayObjectOP, {
                          showAlert: true
      
                      });
      
         //             map.setBasemap(MoW.Basemap.ID.ROADMAP);
                  }
      
                  if (document.getElementById('<%= KMLESString.ClientID %>').value !== "") {
                      var overlayPropertiesES = {
                          "name": "Exercises KML",
                          "url": document.getElementById('<%= KMLESString.ClientID %>').value,
                          "type": MoW.protocols.KMLProtocol.TYPE.STRING,
                          "description": "Demonstrating KML overlay",
                          "mapTypeId": "google.map.mapTypeId.ROADMAP"
                      };
      
                      var newOverlayObjectES = MoW.Factory.createKMLOverlay(overlayPropertiesES);
      
                      map.addOverlay(newOverlayObjectES, {
                          showAlert: true
      

      </x-turndown>

      S Offline
      S Offline
      Stephen Holdorf
      wrote on last edited by
      #2

      One thing that does work is if I publish it as a Web Application and using localhost works. It's just when it's published as a website to IIS is where it fails

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups