mapimage applet
Stephen Lime
steve.lime at dnr.state.mn.us
Fri Aug 18 06:54:24 PDT 2000
The url MUST be fully quallified, that is you need the website address
before the reference to the script.
http://www.dnr.state.mn.us/cgi-bin/mapserv?...
The newMap method is intended for replacing the image without loading the
whole page. You can actually create a single page that never refreses.
This means you are NOT using templates. Rather the coordinates etc
are managed on the client using javascript. MapServer is used just
for images, nothing else. To make this work you need a fair amount
of javascript on the client side to keep extents in order. The landview
application (www.dnr.state.mn.us/mapping/landview) is an example
app that does just this. Javascript source can be made available to
those that are interested.
Steve
Stephen Lime
Internet Applications Analyst
Minnesota DNR
500 Lafayette Road
St. Paul, MN 55155
651-297-2937
>>> "marcelo jury" <mjury at impsat1.com> 08/04/00 01:25PM >>>
Hi ALL,
with the intention of make mapimage applet loads a new image,
I tryied to use the " newMap(URLParam) " mapimage applet's method, but the
first problem comes
out trying to figure out how the URLParam should be set. Since it has to
be just a url to a pic, I guess "URLParam" could be
a URL kind of template instead of the HTML type, but I dont know how it
works:
/scripts/mapserver.exe?map=myMap.map?template=[img]
/scripts/mapserver.exe?map=myMap.map?template
="/scripts/mapserver.exe?map=my
Map.map[img]
after many attempts, the result is the same...:
Content-type: text/html returnHTML(): Web application error. Malformed
template name.
so I run into another way: (Mode=map)
<input type="button"
onclick="javascript:document.mapimage.newMap('/scripts/mapserver.exe?map
=[ma
p]&imgext=[minx]+[miny]+[maxx]+[maxy]&imgxy=[center_x]+[center_y]&layers
=[ge
t_layers]&imgbox=-1+-1+-1+-1&mode=map')" value="Apply" >
but it brings nothing.
>From the source code of one of the results I took the url and pasted it
directly into the
browser... and confirmed that the url works properly.
If all this would work the idea was to move this button onclick's code to
a APPLET Tag onmouseup event... but unffortunatly this event is not
triggered.
It should at least in IE5 as this page at MSDN confirm:
http://msdn.microsoft.com/workshop/author/dhtml/reference/objects/applet.asp
Ok..thats all. THANKS A LOT FOR ANY COMMENT about this issues!
More information about the MapServer-users
mailing list