[mapserver-users] Re: Problem with OpenStreetMap, osm2pgsql, MapServer, OpenLayers and epsg=900913

roshni.spain roshni.aruna at gmail.com
Sun May 9 09:36:49 EDT 2010


Hi Milo, thanks for your reply.

I have gone through the link you sent and after doing many tests i decided
to start again from zero without WMS. I downloaded the Frida_tutorial and
implemented it and it works perfectly fine (connecting to postgis and
reading info from the db). 
After checking this, i just copy-pasted everything and just changed the info
of the connection and the table from where get the data and again the image
comes blank, so i guess the problem is between the db and the projection.
This is my new map file.

MAP
  IMAGETYPE   JPEG
  EXTENT       3428000 5787000 3444000 5800000
  SIZE        600 600

  IMAGECOLOR  100 100 100
  SHAPEPATH   "C:/ms4w/apps/palmarouting/data"
SYMBOLSET    "C:/ms4w/apps/palmarouting/symbols.sym"
  FONTSET     "C:/ms4w/apps/palmarouting/fonts/fonts.list"
  DEBUG 5
  CONFIG "MS_ERRORFILE" "C:\ms4w\apps\palmarouting\ms_error.txt"
  
  WEB
  TEMPLATE "template.html"
    #IMAGEPATH "C:/ms4w/Apache/htdocs/tmp/"
	IMAGEPATH "C:/ms4w/apps/palmarouting/tmp/"
    IMAGEURL  "C:/ms4w/apps/palmarouting/tmp/"
    
    

  END
		
  PROJECTION
   "init=epsg:900913"
  END


  LAYER 
    NAME "roads"
    TYPE LINE
   CONNECTION "user=postgres password=postgres dbname=gis host=localhost
port=5432"
   CONNECTIONTYPE postgis
   DATA "way from planet_osm_line using unique gid"
  
   STATUS DEFAULT
  #LABELITEM 'strname'
  CLASSITEM    'highway'
        CLASS
        	  EXPRESSION '1'
        	  STYLE
        	  COLOR	255 0 0 
			  SIZE 6
        	  END 	
        END
      CLASS
	       EXPRESSION '3'
	       STYLE
		     COLOR	0 255 0 
	       END 	
      END
      CLASS
	       EXPRESSION /./
	       STYLE
		     COLOR	200 200 200 
	       END 	
      END
END

  LAYER
      NAME "path"
      CONNECTION "user=postgres password=postgres dbname=gis host=localhost
port=5432"
      CONNECTIONTYPE postgis
    STATUS ON
      TYPE LINE
			  
      CLASS
        NAME "path"
	STYLE
	SYMBOL 'circle'
COLOR 255 0 0
SIZE 8
	END
      END
END
END 


The only difference i can see between the Frida db and mine is that in
Fridadb the srid set in the geometry_columns is set to -1, but in mine its
900913. I have tried to apply this diff in my map file but with no success
:(

What can i do??? Thanks a lot!!
-- 
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Problem-with-OpenStreetMap-osm2pgsql-MapServer-OpenLayers-and-epsg-900913-tp5022925p5026547.html
Sent from the Mapserver - User mailing list archive at Nabble.com.


More information about the mapserver-users mailing list