[Mapserver-users] ArcExplorer 4.0.1 as a MapServer WMS client

Brent Fraser bfraser at geoanalytic.com
Thu Aug 28 10:39:06 EDT 2003


Eduardo,

  I've been evaluating serveral WMS clients over the past few weeks.  Here
are a couple of useful tips:

1.  In ArcExplorer, display debugging messages by clicking on the Help ->
ArcExplorer Message Console, then in the dialog, View -> Message Level ->
All

2.  Do a GetCapabilities from your browser.  The browser (at least IE6 does)
will parse the xml and report if there are any problems.

I did some editing of your xml/gml trying to get ArcExplorer to recognize
it.  The message window kept reporting the version as none, even though the
version number seemed ok to me.  So I tried tip 2 above and IE pointed to
several parsing errors.  Apparently ArcExplorer (and IE) will not allow
non-ASCII characters anywhere in the document.

When I changed Rincão to Rincao and Talhões to Talhoes, ArcExplorer worked
with it.

Brent Fraser
GeoAnalytic Inc.
Tel:(403) 213-2700
bfraser at geoanalytic.com
www.geoanalytic.com


----- Original Message -----
From: Eduardo Patto Kanegae
To: mapserver-users
Sent: Wednesday, August 27, 2003 10:43 PM
Subject: [Mapserver-users] ArcExplorer 4.0.1 as a MapServer WMS client


has anyone had 'played' with ArcExplorer 4 as a WMS Client tool?


i've configured a mapfile to setup a WMS MapServer application, but when I
try to connect with ArcExplorer
with the URL http://localhost/msc/ogc_wms_msc.php  I only got the message:

"Invalid Capabilities File. Check Server URL.

what could be wrong?




here's my PHP source:

<?header("Content-type:application/vnd.ogc.gml");?>
<WMT_MS_Capabilities version="1.1.1" updateSequence="0">

<!-- MapServer version 4.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
OUTPUT=PDF OUTPUT=SWF SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER
SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT INPUT=POSTGIS
INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE -->

<Service>
  <Name>OGC:WMS</Name>
  <Title>WMS MapServer SAP Connector</Title>
  <Abstract>WMS MapServer SAP Connector Testing application</Abstract>
  <OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/>
        <KeywordList>
          <Keyword>forest</Keyword>
          <Keyword>vcp</Keyword>
          <Keyword>pulp</Keyword>
          <Keyword>paper</Keyword>
        </KeywordList>
  <ContactInformation>
    <ContactPersonPrimary>
      <ContactPerson>Eduardo Patto Kanegae</ContactPerson>
      <ContactOrganization>(self-employed)</ContactOrganization>
    </ContactPersonPrimary>
      <ContactPosition>Consultant</ContactPosition>
    <ContactAddress>
        <AddressType>Residencial</AddressType>
        <Address>Rua 21 de Novembro, 192</Address>
        <City>Rincão</City>
        <StateOrProvince>SP</StateOrProvince>
        <PostCode>14830-000</PostCode>
        <Country>Brasil</Country>
    </ContactAddress>

<ContactFacsimileTelephone>+55(16)3395-3596</ContactFacsimileTelephone>

<ContactElectronicMailAddress>eduardo at consultoria.eti.br</ContactElectronicM
ailAddress>
  </ContactInformation>
</Service>

<Capability>
  <Request>
    <GetCapabilities>
      <Format>application/vnd.ogc.wms_xml</Format>
      <DCPType>
        <HTTP>
          <Get><OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/></Get>
          <Post><OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/></Post>
        </HTTP>
      </DCPType>
    </GetCapabilities>
    <GetMap>
      <Format>image/gif</Format>
      <Format>image/png</Format>
      <Format>image/jpeg</Format>
      <Format>image/wbmp</Format>
      <Format>application/x-shockwave-flash</Format>
      <Format>text/html</Format>
      <Format>application/x-pdf</Format>
      <Format>image/tiff</Format>
      <DCPType>
        <HTTP>
          <Get><OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/></Get>
          <Post><OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/></Post>
        </HTTP>
      </DCPType>
    </GetMap>
    <GetFeatureInfo>
      <Format>text/plain</Format>
      <Format>text/html</Format>
      <Format>application/vnd.ogc.gml</Format>
      <DCPType>
        <HTTP>
          <Get><OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/></Get>
          <Post><OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&amp;"/></Post>
        </HTTP>
      </DCPType>
    </GetFeatureInfo>
  </Request>
  <Exception>
    <Format>application/vnd.ogc.se_xml</Format>
    <Format>application/vnd.ogc.se_inimage</Format>
    <Format>application/vnd.ogc.se_blank</Format>
  </Exception>
  <VendorSpecificCapabilities />
  <Layer>
    <Name>msc_</Name>
    <Title>WMS MapServer SAP Connector</Title>
    <SRS>EPSG:29183</SRS>
    <LatLonBoundingBox minx="-47.5021" miny="-21.1723" maxx="-47.4265"
maxy="-21.1219" />
    <BoundingBox SRS="EPSG:29183"
                minx="240190" miny="7.65685e+006" maxx="247967"
maxy="7.66231e+006" />
    <Layer queryable="0" opaque="0" cascaded="0">
        <Name>talhoes</Name>
        <Title>Talhões</Title>
        <Abstract>Talhões florestais</Abstract>
        <SRS>EPSG:29183</SRS>
        <LatLonBoundingBox minx="-47.5021" miny="-21.1723" maxx="-47.4265"
maxy="-21.1219" />
        <BoundingBox SRS="EPSG:29183"
                    minx="240190" miny="7.65685e+006" maxx="247967"
maxy="7.66231e+006" />
    </Layer>
  </Layer>
</Capability>
</WMT_MS_Capabilities>




and here's my MapFile:

MAP
 NAME msc_
 EXTENT 240190.130 7656849.304 247967.140 7662309.530
 ##FONTSET "fontset.txt"
 ##SYMBOLSET "symbolset.sym"
 IMAGECOLOR 255 255 255
 IMAGETYPE GIF
 INTERLACE ON
 SHAPEPATH "C:\Program Files\Apache Group\Apache2\htdocs\msc\"
 SIZE 600 450
 STATUS ON
 UNITS METERS

 PROJECTION
  "init=epsg:29183" #UTM SAD60 23S
 END

 # (2) - define web object
 WEB
  #EMPTY ""
  #ERROR ""
  IMAGEPATH "C:\Program Files\Apache Group\Apache2\htdocs\tmp\"
  IMAGEURL "/tmp/"
  LOG "C:\Program Files\Apache Group\Apache2\htdocs\msc\msc.log"
  #MINSCALE 1000
  #MAXSCALE 1000000
  #TEMPLATE ""
  METADATA
   "wms_title"      "WMS MapServer SAP Connector"
      "wms_onlineresource"
"http://localhost/cgi-bin/mapserv.exe?map=C:\Program Files\Apache
Group\Apache2\htdocs\msc\msc.map&"
   "wms_srs"       "EPSG:29183" # ex usando varias projecoes "EPSG:4269
EPSG:4326"
   "wms_abstract"    "WMS MapServer SAP Connector Testing application"
   "wms_addresstype"   "Residencial"
   "wms_address"     "Rua 21 de Novembro, 192"
   "wms_city"      "Rincão"
   "wms_stateorprovince" "SP"
   "wms_postcode"    "14830-000"
   "wms_country"     "Brasil"
   "wms_contactelectronicmailaddress" "eduardo at consultoria.eti.br"
   "wms_contactfacsimiletelephone"   "+55(16)3395-3596"
   "wms_contactperson"  "Eduardo Patto Kanegae"
   "wms_contactorganization" "(self-employed)"
   "wms_contactposition" "Consultant"
   "wms_group_title"   "Forestry"
   "wms_keywordlist"   "forest,vcp,pulp,paper"
   #"wms_server_version"  "1.1.1"
   #wms_resx, wms_resy #(Optional) Used in the BoundingBox tag to provide
info about spatial resolution of the data, values are in map projection
units

  END
 END

 LAYER
  NAME "talhoes"
  TYPE POLYGON
  STATUS DEFAULT
  DATA "C740"
  LABELITEM "N_TALHAO"
  CLASS
   NAME "talhões"
   OUTLINECOLOR 0 0 0
   COLOR 255 255 192
   LABEL
    ANTIALIAS  TRUE
    COLOR   0 0 0
    FORCE   TRUE
    PARTIALS  TRUE
    POSITION   CC
    SHADOWCOLOR  224 224 224 #cor da sombra do texto
    SIZE   SMALL
    TYPE   BITMAP
   END
  END
  METADATA
   "wms_name" "talhoes"
   "wms_title" "Talhões"
   "wms_srs"  "EPSG:29183"
   "wms_abstract" "Talhões florestais"
   "wms_extent" "240190.130 7656849.304 247967.140 7662309.530"
   #"wms_format" "image/gif"
  END
 END



END # end of the Map object




More information about the mapserver-users mailing list