[mapserver-users] Fwd: Zoom to something and display in one shot from MapServer CGI.

Basques, Bob (CI-StPaul) bob.basques at ci.stpaul.mn.us
Tue Jul 11 09:22:00 PDT 2017



Hi Steve,

I want to send a CGI request like :  ServerName?pin=202923230045

And zoom to the pin (parcel polygon) in the returned image and also add a buffer percentage.  This is for a reporting application.  I can do it with an intermediate service, but it’s been awhile since I did this, and was wondering if anything new in MapServer might help with this for a single pass approach.

The zoom parameters would be hardcoded into the MapFILE in an ideal world, I can build an SQL for this for example, but I recall I couldn’t use the BBOX returned from the SQL as a BBOX for Mapserver parent call, my memory is cloudy on that capability from MapServer though, hence the question.  Now that you have me talking it through though, I think the last time I asked about this it was to inquire about possibly chaining more than one MapServer call together to get the result.  I think there were fears at the time about possible runaway processes being created . . . .

bobb


On Jul 11, 2017, at 10:38 AM, Stephen Woodbridge <woodbri at swoodbridge.com<mailto:woodbri at swoodbridge.com>> wrote:

On 7/11/2017 10:39 AM, Basques, Bob (CI-StPaul) wrote:
All,
It’s probably because it’s Tues. but I think I’ve asked this before in the past . . .
I have a DB with PIN numbers for PARCELS and I want to be able to auto-zoom(with buffer)  to a PARCEL by just sending in a PIN number via CGI.
can the BBOX be pulled from the DB based on the geom in one shot?  I’ve done this in the past with a Webservice that went and grabbed the BBOX separately, then assembled the url for getting the graphic back from Mapserver.

Bobb,

What are you trying to zoom? the image or the client?

If it is the client then how is mapserver on the server supposed to tell the client it needs to zoom? You have to query the server to get the bbox then make the client zoom appropriately.

For the image, assuming you want a static image showing the parcel, then I would write a php/python/perl script the you pass the PIN to and it does the work to figure out the extents and return the image.

-Steve W

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

_______________________________________________
mapserver-users mailing list
mapserver-users at lists.osgeo.org<mailto:mapserver-users at lists.osgeo.org>
https://lists.osgeo.org/mailman/listinfo/mapserver-users


"If you're going through hell, keep going. “
- Winston Churchill





"Be nice to people on your way up because you meet them on your way down."
- Jimmy Durante



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20170711/bcd3f00c/attachment-0001.html>


More information about the mapserver-users mailing list