[Cartoweb-users] Problem with EPSG

Oliver Christen oliver.christen at camptocamp.com
Mon Jun 23 06:20:50 EDT 2008


Hi

did you try to use an projection which already existed in the epsg file before your modified it?
if you get the same error, it would mean your epsg file is simply not found.

did you also restart apache ?

regards
Oliver
  ----- Original Message ----- 
  From: Giovanni Virdis 
  To: cartoweb-users at lists.maptools.org 
  Sent: Monday, June 23, 2008 11:09 AM
  Subject: [Cartoweb-users] Problem with EPSG


  Hi list, 

   

  I have the following problem:

   

  I define a WMS layer  but when I run the program the return this error

   

  Class : SoapFaultWrapper
  Message : MapServer error: Error in msProcessProjection(): no options found in 'init' file

   

  This is my map file

   

  MAP

    CONFIG "PROJ_LIB" "C:/ms4w/proj/nad/"

   

    NAME "myFirstProject"

    EXTENT 1426149 4397252 1570992 4528332

    #EXTENT       420000 2250000 430000 2260000

    IMAGETYPE PNG

    IMAGECOLOR 255 255 255

    STATUS ON

    UNITS METERS

    FONTSET "fonts.txt"

    SYMBOLSET "symbols.txt"

    SHAPEPATH "data"

    PROJECTION

     "init=epsg:26591"

    END  

    

    OUTPUTFORMAT

      NAME png

      DRIVER "GD/PNG"

      MIMETYPE "image/png"

      IMAGEMODE PC256

      EXTENSION "png"

      FORMATOPTION "INTERLACE=OFF"

      TRANSPARENT OFF

    END

   

    OUTPUTFORMAT

      NAME jpeg

      DRIVER "GD/JPEG"

      MIMETYPE "image/jpeg"

      IMAGEMODE RGB

      EXTENSION "jpg"

      FORMATOPTION "INTERLACE=OFF"

      FORMATOPTION "QUALITY=80"

    END

   

    REFERENCE

      IMAGE images/keymap_france.png

      EXTENT -168827.05 1620431 1414509.05 2677441

      STATUS ON

      COLOR -1 -1 -1

      OUTLINECOLOR 200 0 0

      SIZE 224 150

    END

   

    SCALEBAR

      POSTLABELCACHE TRUE

      STYLE 0

      UNITS kilometers

      SIZE 350 3

      TRANSPARENT TRUE

      COLOR 77 77 88

      IMAGECOLOR 242 255 195

      BACKGROUNDCOLOR 222 222 222

      LABEL

        TYPE BITMAP

        SIZE SMALL

        COLOR 0 0 0

        POSITION UR

        BUFFER 10

      END

    END

   

    LEGEND

      KEYSIZE 20 15

    END

   

    ##########

    # LAYERS #

    ##########

    

     #add your layers definitions here

    

     

    LAYER

      NAME "province"

      TYPE POLYGON

      DATA "province_lr10_03.shp"

      TEMPLATE "ttt"

              TRANSPARENCY 50

      LABELITEM "NOMEPROV"

      CLASS

        NAME "province"

        STYLE

          OUTLINECOLOR 255 165 96

        END

      END

      METADATA

        'id_attribute_string' 'NUMCOM' 

      END

    END

    

    LAYER

      NAME "edificato"

      TYPE POLYGON

      DATA "EdificatoSparsoCTR"

      TEMPLATE "ttt"

      CLASS

        NAME "edificato"

        STYLE

          COLOR 240 240 240

          OUTLINECOLOR 255 165 96

        END

      END

    END 

    

    LAYER

     NAME "ORTOFOTO2006"

     TYPE RASTER

     STATUS ON

     CONNECTION "http://10.0.0.205/cgi-bin/mapserv_wms.exe?"

     CONNECTIONTYPE WMS  

     METADATA

      "wms_srs"              "EPSG:3003"

              "wms_srs"              "EPSG:AUTO"

      "wms_name"             "ORTOF2006"

      "wms_server_version"   "1.1.1"

      "wms_format"           "image/gif"

      "wms_connectiontimeout " "60"

     END

    END  

    

    LAYER

      NAME "Esposti_PPC"

      STATUS ON

      TYPE POLYGON

      CONNECTIONTYPE POSTGIS

      CONNECTION 'dbname=iwork_ppc user=iwork_ppc password=colapasta host=10.0.0.3'

      DATA 'geometria from (select geometria, oid, id_esposto, ds_esposto, ubicazione, n_civico, rectel, popolazione,non_autosuf, num_nonautosuf, note, tpe_fun_id_funuso, tpe_id_tipesposti from ppc_esposti) as foo using unique "id_esposto" using srid=-1'

      TEMPLATE 'ttt'

      TRANSPARENCY 50

      LABELITEM "ds_esposto"

      CLASS

        NAME "class"

        STYLE

          COLOR 50 50 255

          OUTLINECOLOR 255 50 50

        END

        LABEL

          TYPE TRUETYPE

          FONT "Vera"

          SIZE 7

          COLOR 0 0 0

          POSITION cc

          BACKGROUNDCOLOR 245 235 235

          BACKGROUNDSHADOWCOLOR 55 55 55

          BACKGROUNDSHADOWSIZE 1 1

        END

      END

      LABELMAXSCALE 50000

      METADATA

                'id_attribute_string' 'id_esposto' # query

        'query_returned_attributes' 'id_esposto ds_esposto ubicazione n_civico rectel popolazione non_autosuf num_nonautosuf note tpe_fun_id_funuso tpe_id_tipesposti'

        'edit_table' 'ppc_esposti' # PostGIS table

        'edit_geometry_column' 'geometria' # PostGIS geometry column

        'edit_geometry_type' 'polygon' # PostGIS geometry type

        'edit_srid' '-1'

                'edit_attributes' 'ds_esposto|string,ubicazione|string,n_civico|string,rectel|string,popolazione|integer,non_autosuf|string,num_nonautosuf|integer,note|string,tpe_fun_id_funuso|integer,tpe_id_tipesposti|string' # list of the editable fields

                'edit_filter' '' # mapserver filter

      END

    END

   

    LAYER

      NAME "cartoweb_point_outline"

      TYPE POINT

      CLASS

        STYLE

          SYMBOL "circle"

          COLOR 0 0 205

          SIZE 10

        END

        LABEL

          TYPE TRUETYPE

          FONT "Vera"

          SIZE 7

          COLOR 0 0 0

          OUTLINECOLOR 255 255 255

          POSITION lc

        END

      END

    END

   

    LAYER

      NAME "cartoweb_line_outline"

      TYPE LINE

      TRANSPARENCY 100

      CLASS

        STYLE

          OUTLINECOLOR 255 0 0

          SYMBOL "line-dashed"

          SIZE 3

        END

        LABEL

          TYPE TRUETYPE

          FONT "Vera"

          SIZE 7

          COLOR 0 0 0

          OUTLINECOLOR 255 255 255

          ANGLE auto

          POSITION uc

        END

      END

    END

   

    LAYER

      NAME "cartoweb_polygon_outline"

      TYPE POLYGON

      TRANSPARENCY 60

      CLASS

        STYLE

          COLOR 255 153 0

          OUTLINECOLOR 0 0 0

        END

        LABEL

          TYPE TRUETYPE

          FONT "Vera"

          SIZE 7

          OUTLINECOLOR 255 255 255

          COLOR 0 0 0

          POSITION cc

        END

      END

    END

    

   

    ##############

    # END LAYERS #

    ##############

    

    

  END

   

  As you can see I use the mapfile parameter CONFIG to force the location of the epsg file.

  I have define the epsg code in my epsg file (C:/ms4w/proj/nad/) but not work.

   

  # Monte Mario (Rome) / Italy zone 1

  <26591> +proj=tmerc +lat_0=0 +lon_0=21.45233333333333 +k=0.999600 +x_0=1500000 +y_0=0 +ellps=intl +pm=rome +units=m +no_defs  no_defs <>

  # Monte Mario (Rome) / Italy zone 2

  <26592> +proj=tmerc +lat_0=0 +lon_0=27.45233333333333 +k=0.999600 +x_0=2520000 +y_0=0 +ellps=intl +pm=rome +units=m +no_defs  no_defs <>

  # Monte Mario (Rome) / Italy zone 1

  <3003> +proj=tmerc +lat_0=0 +lon_0=9 +k=0.9996 +x_0=1500000 +y_0=0 +ellps=intl +units=m +no_defs <>

   

  Can someone help me?  Thanks

   

   

   

   



------------------------------------------------------------------------------


  _______________________________________________
  Cartoweb-users mailing list
  Cartoweb-users at lists.maptools.org
  http://lists.maptools.org/mailman/listinfo/cartoweb-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/cartoweb-users/attachments/20080623/15f73e79/attachment-0001.html


More information about the Cartoweb-users mailing list