Account Options

  1. Sign in
The old Google Groups will be going away soon.
Switch to the new Google Groups.
Google Groups Home
« Groups Home
ESRI shapefiles
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  Messages 1 - 25 of 32 - Collapse all  -  Translate all to Translated (View all originals)   Newer >
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
GT GIS in NJ  
View profile  
 More options Aug 24 2005, 8:42 pm
From: "GT GIS in NJ" <jtf...@hotmail.com>
Date: Wed, 24 Aug 2005 17:42:55 -0700
Local: Wed, Aug 24 2005 8:42 pm
Subject: ESRI shapefiles
I am an experienced GIS guy, but new to the Google map API.  I can see
from reading back in this forum that there is a way to overlay an ESRI
shapefile into the GMap.  Can someone give me a quick jumpstart please.
 What other data formats are supported.  It looks as if you can render
a polyline as a series of LAT/LON points in decimal degrees if need be.
 Is this the only way?  JTF

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Bill  
View profile  
 More options Aug 24 2005, 9:01 pm
From: "Bill" <bcoo...@msn.com>
Date: Wed, 24 Aug 2005 18:01:03 -0700
Local: Wed, Aug 24 2005 9:01 pm
Subject: Re: ESRI shapefiles
JT,

I think that Lat/Lon is the only way.

I tried ESRI Ungenerate, but found MapInfo MIF format to be easier to
deal with -- still had to do a little manipulating in Excel to get it
into the proper format.

This is what I ended up with from the MIF export.

http://www.fairdata2000.com/GoogleMaps/July_2005_Draft_Mellette.html

http://www.fairdata2000.com/GoogleMaps/July14_Draft_Grenada.html

Bill


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Kyle Mulka  
View profile  
 More options Aug 24 2005, 9:32 pm
From: "Kyle Mulka" <repalvigla...@yahoo.com>
Date: Wed, 24 Aug 2005 18:32:05 -0700
Local: Wed, Aug 24 2005 9:32 pm
Subject: Re: ESRI shapefiles
Have you looked into WFS? I've almost got the WFS to Google Maps
conversion for simple features (points, lines, polygons) figured out.

-Kyle Mulka
http://maps.kylemulka.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Bill  
View profile  
 More options Aug 24 2005, 9:49 pm
From: "Bill" <bcoo...@msn.com>
Date: Wed, 24 Aug 2005 18:49:49 -0700
Local: Wed, Aug 24 2005 9:49 pm
Subject: Re: ESRI shapefiles
Kyle,

I am just taking the easy way out and exporting the files from
Maptitude.

Here is what they look like.

http://www.fairdata2000.com/GoogleMaps/mellette.mif

http://www.fairdata2000.com/GoogleMaps/mellette.lin

But it would be nice to have something that automatically puts it into
GMap polyline format......wouldn't be too hard to do with the MIF file.

Bill


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 25 2005, 12:00 am
From: "MattPF" <mattfar...@gmail.com>
Date: Wed, 24 Aug 2005 21:00:00 -0700
Subject: Re: ESRI shapefiles
Bill,

I've written a PHP script that reads any .mif files in the same
directory as the PHP script and converts all the points to polylines
then plots it on a Gmap.

It's at work, I'm at home :)  I promise to post it in the morning.
(are you comfortable editing PHP code to fit your needs?)

-Matt


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Bill  
View profile  
 More options Aug 25 2005, 12:38 am
From: "Bill" <bcoo...@msn.com>
Date: Wed, 24 Aug 2005 21:38:21 -0700
Local: Thurs, Aug 25 2005 12:38 am
Subject: Re: ESRI shapefiles
Thanks, Matt.

That will be extremely helpful (to me and others I am sure). I am very
much a neophyte re: PHP, but this will give me some real incentive to
learn something.

Bill


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
PebbleBreeze  
View profile  
 More options Aug 25 2005, 1:12 am
From: "PebbleBreeze" <mapme...@sbcglobal.net>
Date: Wed, 24 Aug 2005 22:12:13 -0700
Local: Thurs, Aug 25 2005 1:12 am
Subject: Re: ESRI shapefiles
Yes. Please post the script.

I am plotting polylines and have converted the lines to nodes (points)
with start/stop
coordinates, and was thinking to generate polylines between them, but
WOW is
that a lot of coding for 2,000 nodes.

I was hoping Gmap had a similar design as Jshape.

PB


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 25 2005, 12:21 pm
From: "MattPF" <mattfar...@gmail.com>
Date: Thu, 25 Aug 2005 09:21:16 -0700
Local: Thurs, Aug 25 2005 12:21 pm
Subject: Re: ESRI shapefiles
Ok guys script is ready.  Note that it uses XMaps to shade the
polygons, but this can be easily done via regular GMap polylines.

Example is here:
http://www.fightthebite.net/mif2gmap/ (for Bill's data)

Download is here:
http://www.fightthebite.net/mif2gmap/mif2gmap.zip

You'll need to edit index.php and change the $key variable.

Other than that, just put any .mif files in the MIFs folder, and it
looks in there and automatically reads and plots the data.

Note that this script should work with any text files containing a list
lat/long points.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Bill  
View profile  
 More options Aug 25 2005, 12:41 pm
From: "Bill" <bcoo...@msn.com>
Date: Thu, 25 Aug 2005 09:41:24 -0700
Local: Thurs, Aug 25 2005 12:41 pm
Subject: Re: ESRI shapefiles
Thanks a bunch, Matt. Look forward to experimenting with it. The
shading adds a nice touch.

Bill


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
PebbleBreeze  
View profile  
 More options Aug 25 2005, 4:28 pm
From: "PebbleBreeze" <mapme...@sbcglobal.net>
Date: Thu, 25 Aug 2005 13:28:57 -0700
Local: Thurs, Aug 25 2005 4:28 pm
Subject: Re: ESRI shapefiles
Hey Matt, thanks.

Thats funny that you are working on fightthebite because I am
consulting for the
vector agency on water quality issues! And I goto the website daily to
get updates
and have been impressed with the Gmap use - very nice.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 25 2005, 4:41 pm
From: "MattPF" <mattfar...@gmail.com>
Date: Thu, 25 Aug 2005 13:41:49 -0700
Local: Thurs, Aug 25 2005 4:41 pm
Subject: Re: ESRI shapefiles
What a coincidence!  I'm the webmaster and in-house IT Admin for the
agency.  I get calls at midnight to update the spraying status on the
website!  argg!

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Lance  
View profile  
 More options Aug 25 2005, 6:34 pm
From: "Lance" <weaver.la...@gmail.com>
Date: Thu, 25 Aug 2005 15:34:36 -0700
Local: Thurs, Aug 25 2005 6:34 pm
Subject: Re: ESRI shapefiles

Tried it, for some reason it is not reading the .mif file     It
returns the following error.

<b>Warning</b>:  file(MIFS/mellette.mif): failed to open stream: No
such file or directory in <b>/srv/www/mywebsite/index.php</b> on line
<b>82</b><br />
<br />
<b>Warning</b>:  Invalid argument supplied for foreach() in
<b>/srv/www/mywebsite/scripture/satmap_gpx.php</b> on line <b>84</b><br
/>

        Any suggestions?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 25 2005, 11:32 pm
From: "MattPF" <mattfar...@gmail.com>
Date: Thu, 25 Aug 2005 20:32:25 -0700
Local: Thurs, Aug 25 2005 11:32 pm
Subject: Re: ESRI shapefiles
Hmm.. Make sure you have the folder:
/srv/www/mywebsite/MIFs/

and the file
/srv/www/mywebsite/MIFs/mellette.mif

Also your server may be case sensative.  Check to make sure it's MIFS
or MIFs or mifs, etc.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Bill  
View profile  
 More options Aug 26 2005, 12:51 am
From: "Bill" <bcoo...@msn.com>
Date: Thu, 25 Aug 2005 21:51:13 -0700
Local: Fri, Aug 26 2005 12:51 am
Subject: Re: ESRI shapefiles
Works great, Matt.

It loaded two MIF files -- one with the South Dakota districts and the
other with Mississippi districts -- 10 polylines in all without a
hitch.

Thanks again,

Bill


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 26 2005, 9:06 am
From: "MattPF" <mattfar...@gmail.com>
Date: Fri, 26 Aug 2005 06:06:10 -0700
Local: Fri, Aug 26 2005 9:06 am
Subject: Re: ESRI shapefiles
Awesome Bill.. I admit the code may be sloppy, it was something I threw
together for test purposes only, but good to hear it suits you well.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joel in NJ  
View profile  
 More options Aug 26 2005, 10:16 am
From: "Joel in NJ" <jtf...@hotmail.com>
Date: Fri, 26 Aug 2005 07:16:05 -0700
Local: Fri, Aug 26 2005 10:16 am
Subject: Re: ESRI shapefiles

MattPF wrote:
> Awesome Bill.. I admit the code may be sloppy, it was something I threw
> together for test purposes only, but good to hear it suits you well.

Thanks everyone - it looks like my path of least resistence at this
point will be ESRI Shp > MIF > Bill's script > GMap poly.  I am
interested in looking into WMS & WFS as well and look forward to
joining into the discussion.  Joel

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joel in NJ  
View profile  
 More options Aug 26 2005, 10:19 am
From: "Joel in NJ" <jtf...@hotmail.com>
Date: Fri, 26 Aug 2005 07:19:17 -0700
Local: Fri, Aug 26 2005 10:19 am
Subject: Re: ESRI shapefiles
Sorry - I meant Matt's script - give credit where credit is due.  Joel

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 26 2005, 11:51 am
From: "MattPF" <mattfar...@gmail.com>
Date: Fri, 26 Aug 2005 08:51:55 -0700
Local: Fri, Aug 26 2005 11:51 am
Subject: Re: ESRI shapefiles
Joel,

I used to do the ESRI Shp > MIF > Bill's script > GMap poly, but I've
found it more functional to go with:

ESRI Shp -> PostgreSQL Database

Then in my Google Maps use an XMLHTTP request to query the database for
the lat/long points and plot them live. So:

ESRI Shp -> PostgreSQL Database -> Gmaps

For example:
http://www.fightthebite.net/ulv/routes.php?planned=Past

Selects all the polygons in the database where the planned column is
set to "Past" then plots them live.  It's easier to store, manage, and
query a library of polygons inside a spatial database such as
PostgreSQL/PostGIS instead of a bunch of MIF files.

One example I've used is a query of all zip code "polygons" overlapping
sacramento county "polygon"  -> which plots all zip codes in sac
county.

-Matt


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
58sniper  
View profile  
 More options Aug 26 2005, 12:58 pm
From: "58sniper" <innervat...@gmail.com>
Date: Fri, 26 Aug 2005 16:58:04 -0000
Local: Fri, Aug 26 2005 12:58 pm
Subject: Re: ESRI shapefiles

MattPF wrote:
> One example I've used is a query of all zip code "polygons" overlapping
> sacramento county "polygon"  -> which plots all zip codes in sac
> county.

> -Matt

If anyone comes up with a PHP/MySQL solution to do that, I'd be
interested. I need to plot zip codes, and I also need to plot city
boundaries (although not at the same time).

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 26 2005, 4:54 pm
From: "MattPF" <mattfar...@gmail.com>
Date: Fri, 26 Aug 2005 13:54:18 -0700
Local: Fri, Aug 26 2005 4:54 pm
Subject: Re: ESRI shapefiles
sniper,

I use PHP/PostgreSQL which isn't too far from what you're looking for.
This is my first venture with Postgre and it's not much different than
MySQL at this level.

If you're not going to be running spatial queries (searching for points
within polygons, or polygons overlapping other polygons) then you can
just store the outlines/boundaries as a series of lat/longs in a normal
MySQL table.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
gizoto316  
View profile  
 More options Aug 26 2005, 5:16 pm
From: "gizoto316" <d_g...@hotmail.com>
Date: Fri, 26 Aug 2005 14:16:23 -0700
Local: Fri, Aug 26 2005 5:16 pm
Subject: Re: ESRI shapefiles
Now how do you get the shapfiles to MIF format using map info?  I tried
opening it and the shapefile does not come up.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
MattPF  
View profile  
 More options Aug 26 2005, 5:35 pm
From: "MattPF" <mattfar...@gmail.com>
Date: Fri, 26 Aug 2005 14:35:27 -0700
Local: Fri, Aug 26 2005 5:35 pm
Subject: Re: ESRI shapefiles
A suite of free GIS software called FWTools available at:

 http://fwtools.maptools.org/

You could use them to translate the shapefiles to MapInfo mid/mif
format which is a simple readable ASCII format.  The command would be
something
like:

  ogr2ogr -f "MapInfo File" out.mif in.shp

Are the input shapefiles already in lat/long coordinates or are they in
a projected coordinate system?  If they are in a projected coordinate
system, and you want to convert them to geographic (lat/long)
coordinates then you can use a slightly more complex command:

  ogr2ogr -t_srs WGS84 -f "Mapinfo File" out.mif in.shp


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Polygon Shapefile How-To" by dbally@gmail.com
dbally@gmail.com  
View profile  
 More options Aug 29 2005, 11:40 pm
From: "dba...@gmail.com" <dba...@gmail.com>
Date: Mon, 29 Aug 2005 20:40:08 -0700
Local: Mon, Aug 29 2005 11:40 pm
Subject: Polygon Shapefile How-To
I got a method to work (finally) to add polygons to Google Maps. I am
by no stretch of the imagination a programmer. Keeping that in mind,
the basic process is:

1. Link to xmaps.1b.js at http://xmaps.busmonster.com/ (its an uber
useful extension for the Google API)
2. Create (or use existing) polygon in ArcMap. Be sure to set the data
frame coordinate system to WGS 84 (View --> Data Fram Properties -->
Coordinate System --> Predefined --> Geographic Coordinate Systems -->
World --> WGS 84)
3. Convert Verticies to Points (AcrToolbox --> Data Management Tools
--> Features --> Feature Verticies to Points)
4. Add XY Coords - there are scripts to do this in 8.x (check out
www.ian-ko.com) and a built in funcion (ArcToolbox --> Data Management
Tools --> Features --> Add XY Coordinates) in 9.x.
5. In ArcCatalog, create a new empty personal geodatabase
6. Back in ArcMap, export the TABLE of the verticies to the
geodatabase, not the shapfile.
7. Upload the geodatabase to your web server.
8. Use an asp file to create xml. For this example, Polytable is the
name of the geodatabase I created in step 4. Harris is the name of the
table I exported into it. Copy and paste this section and save as an
*.asp. Upload to your web server. It creates a file in the format that
Goolge expects a la
http://www.google.com/apis/maps/documentation/#Using_XML_and_Asynchro....
I got hints and tips from http://www.w3schools.com/xml/xml_server.asp

<%
response.ContentType = "text/xml"
set conn=Server.CreateObject("ADODB.Connection")
conn.provider="Microsoft.Jet.OLEDB.4.0;"
conn.open server.mappath("/maps/polytable.mdb")
sql="select POINT_X, POINT_Y from harris"
set rs=Conn.Execute(sql)

rs.MoveFirst()

response.write("<?xml version='1.0' encoding='ISO-8859-1'?>")
response.write("<markers>")

while (not rs.EOF)

  response.write("<marker" & "space" & "lat" & "equalsign" & "quote" &
rs("POINT_Y") & "quote" & "space" & "lng" & "equalsign" & "quote" &
rs("POINT_X") & "quote" & "/>")

  rs.MoveNext()
wend

rs.close()
conn.close()

response.write("</markers>")

%>

Go to http://maps.danielbally.com/harris.asp to see it in action.

Back to the point about me not being a programmer. I was having issues
in Firefox creating the proper xml (something partially about not
closing the <marker> tag and partially someting about having an '='. To
circumvent these types of errors I just have it write 'quote' where
there needs to be a ", 'equalsign' where there should be a =, 'space'
where there needs to be a " " to take care of punctuation. I copied the
output from Firefox into a text editor and did a Find-Replace to find
and replace (creatively enough) the writtin out punctuation with the
symbol version. I then saved the xml.

9. Then upload said xml to the web server too. See
http://maps.danielbally.com/harris.xml for the output.

The test website I've been playing with is
http://maps.danielbally.com/harris.html

I hope these instructions will be useful! Not the easiest process in
the world, I know, but it should work. Thanks.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
dbally@gmail.com  
View profile  
 More options Aug 31 2005, 7:07 pm
From: "dba...@gmail.com" <dba...@gmail.com>
Date: Wed, 31 Aug 2005 23:07:22 -0000
Local: Wed, Aug 31 2005 7:07 pm
Subject: Re: Polygon Shapefile How-To
I've got an update. The new asp code is . . .

<%
response.ContentType = "text/xml"
set conn=Server.CreateObject("ADODB.Connection")
conn.provider="Microsoft.Jet.OLEDB.4.0;"
conn.open server.mappath("/maps/polytable.mdb")
sql="select POINT_X, POINT_Y from harris"
set rs=Conn.Execute(sql)

rs.MoveFirst()

response.write("<?xml version='1.0' encoding='ISO-8859-1'?>")
response.write("<markers>")

while (not rs.EOF)
  response.write("<marker" & " " & "lat=" & chr(34) & rs("POINT_Y") &
chr(34) & " " & "lng=" & chr(34) &rs("POINT_X") & chr(34) & "/>")
    rs.MoveNext()
wend

rs.close()
conn.close()
response.write("</markers>")
%>

If you check out the source of maps.danielbally.com/harris2.html you'll
see where you can refer to asp instead of xml in the request.open
portion. It works exactly the same and, this way, you can skip the last
part of #8. Good times.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
dbally@gmail.com  
View profile  
 More options Aug 31 2005, 7:44 pm
From: "dba...@gmail.com" <dba...@gmail.com>
Date: Wed, 31 Aug 2005 16:44:10 -0700
Local: Wed, Aug 31 2005 7:44 pm
Subject: Re: Polygon Shapefile How-To
Another update. This is still a work in progress, so please bear with
me. Skip step 6. Exporting the shapefile works just fine. A dbf is a
dbf anyway it gets in the geodatabase. Thanks.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Messages 1 - 25 of 32   Newer >
« Back to Discussions « Newer topic     Older topic »