Re: [Gistoolkit-editor] quickwms and gistoolkit server
Brought to you by:
bitterstorm,
ithaqua
From: ithaqua <it...@at...> - 2004-03-24 04:19:29
|
I have updated the code to accept "JPEG", and "PING" as valid image types as well as "jpg", and "png". Till then, use the 3 letter abbreviations, instead of the 4 letter ones. ithaqua On Sun, 2004-03-21 at 22:33, ithaqua wrote: > Hi, > It took some experimentation with the Java Script to get it to work, > but eventually I did. Here is the sample code that I used: > > <script language='Javascript'> > // WMS servers - list here other OGC compliant map servers > var demisWMS = "http://localhost:40320/USA"; > > function writeMaps(){ > var map = new quickWMS(-180, -90, 180, 90); > map.addLayer(demisWMS, "States", "1.0.0", "Modis Mosaic"); > map.onError = function (layer){alert("error")} > map.layers[0].format="png"; > map.writeDOM("myMap", 350, 195, 350, 175, > "background-color:white;border-style:solid;border-width:1;border-color:black;"); > map.toolbar = new toolBar(map); > map.toolbar.writeDOM(350,170,true); > map.refresh(); > } > writeMaps() > </script> > > So, the key things that need to change, are to remove the trailing "/" > from your URL, and change the format to either "jpg", or "png". > > Hope that helps., > Ithaqua > > > On Fri, 2004-03-19 at 16:34, Johannes Buehler wrote: > > hi, > > does anyone known how to connect quickwms to the gistoolkit server? > > quickwms is a simple javascript client for accessing wms servers. > > (http://giserver.esrin.esa.int/quickwms/) > > > > as descriped in the documentation the wms server can be accessed > > through the url of the wms service (http://localhost:40320/dhm/) and the layername, > > in my example (NewLayer). > > > > <script language='Javascript'> > > > > // WMS servers - list here your favorite server > > // Changes: 2003-10-24 : Added http:// to the DEMIS and ESRIN server urls > > var gistoolkit = "http://localhost:40320/dhm/"; > > > > function writeMaps(){ > > > > var map = new mapWMS(-180,-90,180,90); > > map.addLayer(gistoolkit, "NewLayer"); > > map.layers[0].format="JPEG"; > > map.writeDOM("myMap", 350, 175, 350, 175, "background-color:white; border-style:solid; border-width:1; border-color:black;"); > > map.refresh(); > > > > } > > writeMaps(); > > </script> > > > > but i dont know what to parameters the gistoolkitserver requires to return the map. > > using these settings i do not get a result. > > > > Thanks for any hints, also with accessing the gistoolkit server with other wms clients > > could be interesting for me. > > > > Johannes -- ithaqua <it...@at...> Ithaqua Enterprises Inc. |