[mapserver-users] web development project with mapserver-
David.Fawcett at state.mn.us
Thu Mar 19 16:27:44 EDT 2009
I don't have an example handy, but here is one way to do it
You have a script that goes out and gathers the current wind data and
writes it to a MySQL Database or a shapefile.
Using CGI MapServer, your map file uses the database table or shape file
as the data source for your wind stations layer.
With MapServer version >=5.2, you can base the rotation of the symbol on
the value in a column of your data source. See 'attribute binding' in
You use MapServer to output an image map using a query template. The
image map can contain data from different columns in your data source.
I know that I put together an example on this somewhat recently. I will
From: Pablo Romero [mailto:romero619 at hotmail.com]
Sent: Thursday, March 19, 2009 3:08 PM
To: David.Fawcett at state.mn.us; mapserver-users at lists.osgeo.org
Subject: RE: [mapserver-users] web development project with mapserver-
Thanks for the response.
Divs arent a requirement; I just mentioned them because the example site
that I posted was using divs, so I suggested them more as a point of
Id be willing to use whatever works, but Id obviously like to avoid
using any hefty solution that could be considered as being 'overkill'.
something simple & lightweight is prefered.
Im not very experienced with mapserver, but would the use of symbols to
add the vector drawings be a feasible solution? can symbols show up on
the image map as clickable regions with mouse-over text?
i.e., something like:
1) use my backend code (php/perl) to generate the markers & select the
appropriate symbol image file & "alt" text
2) pass this info to mapserver prior to drawing the map, & include the
symbols into the map image.
3) create the image map with symbols
does this method sound reasonable/right?
IF so, how would I go about this (creating these custom symbols)? Is
there an existing tutorial that might help me accomplish this?
> Subject: RE: [mapserver-users] web development project with mapserver-
> Date: Thu, 19 Mar 2009 14:35:20 -0500
> From: David.Fawcett at state.mn.us
> To: romero619 at hotmail.com; mapserver-users at lists.osgeo.org
> Do you really need to create divs?
> You could use MapServer to put the marker on the map in the correct
> location (as part of the map image) and have MapServer output it as an
> imagemap if all that you need is mouse-over text.
> If you want to do anything much fancier with putting vector markers on
> a map, you might look at something like OpenLayers.
> http://www.openlayers.org/ Probably overkill for what you need, but
> worth a look.
> -----Original Message-----
> From: mapserver-users-bounces at lists.osgeo.org
> [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Pablo
> Sent: Thursday, March 19, 2009 2:27 PM
> To: mapserver-users at lists.osgeo.org
> Subject: [mapserver-users] web development project with mapserver-
> I need help figuring out a method to do the following:
> 1) use mapserver to create a basic, static image of a given region,
> say,for example the following area: lat1=0.00 lat2=40.00 lng1=-120.00
> lng2=-40.00 (in decimal degrees)
> "markers" over the map image at specific lat/lon points (similiar to
> google map markers, except over a static map image).
> The problem Im having is figuring out a way to create the "marker"
> divs using absolute (pixel) coordinates over the map image. My marker
> locations are in lat/lon, and I would need to translate them to the
> map's image coordinates. I thought about just scaling the points based
> on the maps's bounds and the map image size, but this would only
> provide "linear scaling" which might be fairly inaccurate, and I also
> want a method that will work with most map projections. Does this make
> Does mapserver provide any automated means of creating such "markers"?
> Or, is there an existing method of translating
> Perhaps this question might not be very mapserver-related, but I was
> hoping someone might have experience with this type of setup.
> Here's an example of what Im basically trying to emulate:
> I dont know if this map image was created with mapserver, but the
> general concept stil applies to mapserver: generate a map projection
> image, and place geo-referenced objects over the map image...
> Please help,
> Windows Live(tm): Life without walls.
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
Hotmail(r) is up to 70% faster. Now good news travels really fast.
More information about the mapserver-users