[ka-Map-users] XML Points File

Pete Giencke pgiencke at glc.org
Wed Jan 11 13:06:43 EST 2006


Oops, it appears Outlook doesn't like .js attachments, so I've zipped both
files together instead..


-----Original Message-----
From: ka-map-users-bounces at lists.maptools.org
[mailto:ka-map-users-bounces at lists.maptools.org] On Behalf Of Paul Spencer
Sent: Wednesday, January 11, 2006 12:25 PM
To: David Bitner
Cc: ka-map-users at lists.maptools.org
Subject: Re: [ka-Map-users] XML Points File


one problem with this is that you cannot load an XML document from an
arbitrary URL.  Due to browser restrictions, you can only load it from the
domain from which the page was loaded.  This really, really sucks and there
is (almost) no way around it.

There are two ways you could implement this:

1.  a server-side script (php or other) included with ka-Map or hosted on
the same domain that redirects the request to the remote server, gets the
response and returns it to the client.  I call this the proxy approach.
This would have to be done carefully as it could expose a security risk.

2. the other technique uses the fact that you can create a <script> element
via document.createElement and it will load and execute javascript from
remote sites (and this isn't a security risk!  go figure).  The downside is
that it loads javascript, which probably isn't appropriate for what you are



On 11-Jan-06, at 11:01 AM, David Bitner wrote:

> I know that there has been some discussion on the list regarding 
> similar functionality to the markers in google maps.  I also know that 
> there is a good start in ka-map for adding points that will then pan 
> along with the map.
> I am looking to create a javascript function that takes a url of a 
> "service" and optionally a flag  to indicate that a bounding box 
> should be sent and a new request should be made for each map extent.
> The "service" could then be either a script (php+postgis in my case) 
> or a file that returns either a delimited string or an xml string.
> The return will indicate several points, each point will have an x and 
> y coordinate, a url to an image to be shown on the map, and optionally 
> html that will be included in a div that is used for mouseover events.
> Has anyone done anything along these lines already?  If not, are there 
> any features or specifications that I could include that would help 
> anyone else out?
> Thanks,
> David
> _______________________________________________
> ka-Map-users mailing list
> ka-Map-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/ka-map-users

|Paul Spencer                           pspencer at dmsolutions.ca   |
|Applications & Software Development                              |
|DM Solutions Group Inc                 http://www.dmsolutions.ca/|

ka-Map-users mailing list
ka-Map-users at lists.maptools.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: exampeFiles.zip
Type: application/octet-stream
Size: 1168 bytes
Desc: not available
Url : http://lists.maptools.org/pipermail/ka-map-users/attachments/20060111/adbeb3c5/exampeFiles.obj

More information about the ka-Map-users mailing list