Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Hi, Are you trying to split a polygon using another geo object like a line? Or do you just want to divide the polygon in smaller pieces? You may want to look at triangulation for that. Take a look here: http://en.wikipedia.org/wiki/Polygon_triangulation Best regards, Wim On 7 September 2010 07:46, venkat ven.tammin...@gmail.com wrote: Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Dear Wim, Thanks for your great response...I am not looking for triangulation(tin).I am looking for Split operation based on line...I did it using PostGIS (st_split) function.I want to work it by coding (that can be client or server side code.)..Please let me know is it possible.if it is possible, please let me know.. Thanks and Regards, Ven On Tue, Sep 7, 2010 at 12:25 PM, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi, Are you trying to split a polygon using another geo object like a line? Or do you just want to divide the polygon in smaller pieces? You may want to look at triangulation for that. Take a look here: http://en.wikipedia.org/wiki/Polygon_triangulation Best regards, Wim On 7 September 2010 07:46, venkat ven.tammin...@gmail.com wrote: Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Hmm. No guarantees, but perhaps the geoapi.net or nettopolgysuite have this functionality. Alternatively, what you could do, although it still involves a spatial database, is use the C# Sql Spatial libraries. You could install a microsoft sql server 2008 (spatial) database, reference the spatial libraries and perform the split of the polygon with those spatial functions, using C#. But as you stated, this is probably not the solution you are looking for. Maybe someone else is aware of another third party library that does this :). On 7 September 2010 08:59, venkat ven.tammin...@gmail.com wrote: Dear Wim, Thanks for your great response...I am not looking for triangulation(tin).I am looking for Split operation based on line...I did it using PostGIS (st_split) function.I want to work it by coding (that can be client or server side code.)..Please let me know is it possible.if it is possible, please let me know.. Thanks and Regards, Ven On Tue, Sep 7, 2010 at 12:25 PM, Wim Vanbelle wimvanbe...@gmail.comwrote: Hi, Are you trying to split a polygon using another geo object like a line? Or do you just want to divide the polygon in smaller pieces? You may want to look at triangulation for that. Take a look here: http://en.wikipedia.org/wiki/Polygon_triangulation Best regards, Wim On 7 September 2010 07:46, venkat ven.tammin...@gmail.com wrote: Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Dear Wim, Thanks for your response.I am looking into the same. Thanks and Regards, Ven On Tue, Sep 7, 2010 at 1:39 PM, Wim Vanbelle wimvanbe...@gmail.com wrote: Hmm. No guarantees, but perhaps the geoapi.net or nettopolgysuite have this functionality. Alternatively, what you could do, although it still involves a spatial database, is use the C# Sql Spatial libraries. You could install a microsoft sql server 2008 (spatial) database, reference the spatial libraries and perform the split of the polygon with those spatial functions, using C#. But as you stated, this is probably not the solution you are looking for. Maybe someone else is aware of another third party library that does this :). On 7 September 2010 08:59, venkat ven.tammin...@gmail.com wrote: Dear Wim, Thanks for your great response...I am not looking for triangulation(tin).I am looking for Split operation based on line...I did it using PostGIS (st_split) function.I want to work it by coding (that can be client or server side code.)..Please let me know is it possible.if it is possible, please let me know.. Thanks and Regards, Ven On Tue, Sep 7, 2010 at 12:25 PM, Wim Vanbelle wimvanbe...@gmail.comwrote: Hi, Are you trying to split a polygon using another geo object like a line? Or do you just want to divide the polygon in smaller pieces? You may want to look at triangulation for that. Take a look here: http://en.wikipedia.org/wiki/Polygon_triangulation Best regards, Wim On 7 September 2010 07:46, venkat ven.tammin...@gmail.com wrote: Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] MapServer and MapScript in separate hosts
Hello: Maybe its a silly question but Id like to know if I can use MapScript in a web server with PHP being MapServer installed in a different host. All the examples Ive seen seem to run in the same server and I cant find a way to set up an URL for the MapServer location. Thank you. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] MapServer and MapScript in separate hosts
Hi, If you compile mapserver from source, you can use ./configure --prefix=/path/to/executable to install it in the folder you want. You do need to make sure that LD can find the shared libraries. This should then be set in apache config so that the right environment paths are loaded. As for the external URL thing. Just configure a CGI script at a given URL (as configured in your webserver) and then point to the location of your mapserv executable. Perhaps this is what you are looking for: http://mapserver.org/cgi/wrapper.html 2010/9/7 Román González rgonza...@normagricola.com Hello: Maybe it’s a silly question but I’d like to know if I can use MapScript in a web server with PHP being MapServer installed in a different host. All the examples I’ve seen seem to run in the same server and I can’t find a way to set up an URL for the MapServer location. Thank you. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Ven, First, I took a quick look at the php mapscript documentation (my preferred mapscript) and didn't see anything specific about splitting. Solving a more simplified problem might be a start. Start by getting the bounding box of the polygon ($shp-bounds). Get the two left side coordinates: $p1=(MinX, MaxY), $p2=(MinX, MinY) Build a new polygon using these two points and the endpoints of your line. -- Assumption that your line is not horizontal or intersects the left edge of your bbox. Use the shapeObj::intersection to get the half of your target polygon within the left half of the BBOX. You can repeat this for the right half of the BBOX, or maybe use shapeObj::difference. My first thoughts. You could, alternatively, loop through all of $shp-lines(1..$shp-numlines) and checking for intersection with your split line. A little bookkeeping would allow you to build your two split polygons from this. I think option 1 might be easier. Hope this helps, Josh --- On Tue, 9/7/10, venkat ven.tammin...@gmail.com wrote: From: venkat ven.tammin...@gmail.com Subject: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS To: mapserver-users-requ...@lists.osgeo.org, mapserver-users@lists.osgeo.org Date: Tuesday, September 7, 2010, 1:46 AM Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven -Inline Attachment Follows- ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Dear Josh, Thanks for your great response.Yes You done my work around... Thanks alot..Let me work on that...i will update you once i done ... Thanks again. Ven On Tue, Sep 7, 2010 at 4:11 PM, Joshua Hevenor jheve...@rogers.com wrote: Ven, First, I took a quick look at the php mapscript documentation (my preferred mapscript) and didn't see anything specific about splitting. Solving a more simplified problem might be a start. Start by getting the bounding box of the polygon ($shp-bounds). Get the two left side coordinates: $p1=(MinX, MaxY), $p2=(MinX, MinY) Build a new polygon using these two points and the endpoints of your line. -- Assumption that your line is not horizontal or intersects the left edge of your bbox. Use the shapeObj::intersection to get the half of your target polygon within the left half of the BBOX. You can repeat this for the right half of the BBOX, or maybe use shapeObj::difference. My first thoughts. You could, alternatively, loop through all of $shp-lines(1..$shp-numlines) and checking for intersection with your split line. A little bookkeeping would allow you to build your two split polygons from this. I think option 1 might be easier. Hope this helps, Josh --- On *Tue, 9/7/10, venkat ven.tammin...@gmail.com* wrote: From: venkat ven.tammin...@gmail.com Subject: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS To: mapserver-users-requ...@lists.osgeo.org, mapserver-users@lists.osgeo.org Date: Tuesday, September 7, 2010, 1:46 AM Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven -Inline Attachment Follows- ___ mapserver-users mailing list mapserver-users@lists.osgeo.orghttp://mc/compose?to=mapserver-us...@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
RE: [mapserver-users] formatting query and identify results
You can embed javascript in a template result but it's up to the client to execute it (MapServer won't). Steve -Original Message- From: mapserver-users-boun...@lists.osgeo.org [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Mark Volz Sent: Friday, September 03, 2010 9:09 AM To: Andy Colson Cc: mapserver-users@lists.osgeo.org Subject: RE: [mapserver-users] formatting query and identify results Andy, Thank you for your reply. I could add a new column to the data to create a new mask so that the application will work. However, once I am complete with the development of the application, I will no longer be in control of the data. Since the data source has the wrong mask, any data updates from my client will not include the correct mask. Mark Volz GIS Specialist -Original Message- From: Andy Colson [mailto:a...@squeakycode.net] Sent: Friday, September 03, 2010 9:02 AM To: Mark Volz Cc: mapserver-users@lists.osgeo.org Subject: Re: [mapserver-users] formatting query and identify results On 9/3/2010 8:12 AM, Mark Volz wrote: Hello, I have an application that I am working on. The parcel id is in a xx.xxx.xxx.x format, however I need to change the format to xx-xxx-xxx-x for an external tax database application. I will not be updating the data, and therefore I will need to make this change through code. I have worked on previous applications using java. For example I would use parcel = ( this.substring(0,2) + - + this.substring(3,9). However, unless I am wrong, mapserver does not appear to pass javascript through templates. Is there a way that I can convert the format of numbers directly in the template? Thanks Mark Volz GIS Specialist Not sure if this is relevant, but I have kinda the same problem, some of my data has parcel masking and some does not. I usually add a new column (I'm use PostGIS, not shapefiles, but I assume you could still do it) and set it with the masking I'd like to display. So I have a pin field and a display_pin field, and can query/join on one and display the other. I know you said you would not update the data, but if I carefully read that as not modify the existing pin, then adding a new column would not count as modify the existing pin. -Andy ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Dynamically draw different sized ellipses on map
Was hoping on some guidance as to the best way to attack this... My app uses the cgi interface. I have been succesful at drawing lines, squares and small circles on the fly by sending mods to the .map file via the URL. I have been doing this by dynamically adding points to various POINT layers with the afforementioned symbols. Up to this point, the squares and circles have been uniform in size and aspect. Now I find myself needing to add multiple ellipses of varying sizes at different locations on the map. Technically they would be circles of area, but the aspect will change as the location approaches the poles. (almost a true circle at the equator and verly long ellipse toward the poles due to map projection). Ideally the ellipses will be filled with either a hatch pattern or a transparent solid color. Any suggestions as to the best way to accomplish this? Cheers -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/Dynamically-draw-different-sized-ellipses-on-map-tp5508425p5508425.html Sent from the Mapserver - User mailing list archive at Nabble.com. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users