[mapserver-users] Mapplet - Boxoff()

Steve Lime steve.lime at dnr.state.mn.us
Tue May 7 11:58:13 EDT 2002


There is a parameter called "box" that you can set to "off" when you
initialize the applet. Like so:

  <applet codebase="/java/mapplet" code="mapplet.class" width="125"
height="125" name="mapplet" MAYSCRIPT>
    ... other parameters ...
    <param name="box" value="off">
  </applet>

Steve

Stephen Lime
Data & Applications Manager

Minnesota DNR
500 Lafayette Road
St. Paul, MN 55155
651-297-2937

>>> "Hankley, Chip" <Chip.Hankley at GASAI.com> 05/07/02 10:25AM >>>
I'm trying to fine tune the Mapplet. What I want is for 'boxoff' to be
set
whenever the 'zoomin' button is not selected.

I can do this by doing something like this:

ZOOM IN  <input type="radio" name="zoomdir" value="1"
onClick="document.mapplet.boxon();" [zoomdir_1_check]><BR>
PAN<input type=radio name="zoomdir" value="0"
onClick="document.mapplet.boxoff();" [zoomdir_0_check]>
ZOOM OUT<input type=radio name="zoomdir" value="-1"
onClick="document.mapplet.boxoff();" [zoomdir_0_check]>

However, it appears that AFTER the mapplet executes, the default state
is
boxon. So, what happens is that if I click the PAN button, I get the
boxoff
state the FIRST time I try to pan, but the next time I attempt to PAN
(i.e.
2 successive clicks on the image) the state has returned to boxon.

How do you overcome this?

TIA

Chip Hankley



More information about the mapserver-users mailing list