<< Click to Display Table of Contents >>

 

Adding SuperGIS Server map service into Google Map

 

 

1.Find out "sample.htm" file under the built virtual directory of GoogleMap and open it with notepad or other text compiler to edit it. You can modify the map services published by SuperGIS Server in initialized function, InitWnd() (code in blue and bold below). For example, if you publish a service named TW under "public" directory of SuperGIS Server, please replace public\world.cfg in sample.htm with public\TW.cfg and then click "Save."

 

………

   function InitWnd()

   {

      var pOMap = document.getElementById("OMap");

      var myOptions =

      {

         mapTypeId: google.maps.MapTypeId.ROADMAP ,

         zoom: 0,

         center: new google.maps.LatLng(0, 0)

      };

      Google_Map = new google.maps.Map(pOMap, myOptions);

      var pConn = new SuperGISServerConnection("http://localhost/sgspws/SGSPAgent.ashx", "public\TW.cfg", ServerConnect);

   }

………

 

 

2.After modifying, you will be able to view SuperGIS Server map service on Google website by entering the website address on the browser.

 

 

 


©2017 Supergeo Technologies Inc.