Query templates

Steve Lime Steve.Lime at DNR.STATE.MN.US
Sat Jun 17 09:23:45 EDT 2006


Dave: Sure. In your browse template you'll need to add (or add to) a little bit of javascript that is called when the form is submitted.

Of the top of my head it's like:

<form name=mapserv ... onSubmit='return doSubmit()'>
...
</form>

<script language="javascript">
function doSubmit() {

  // this assumes a radio button for mode with browse listed 1st
  if(!form.mapserv.mode[0].checked) {
    form.mapserv.target = "new"; 
    // or you could open a window with certain properties and set it as the target
  } else {
    form.mapserv.target = "self"; // or something like that
  }

  // other validation here

  return true;
}
</script>

Steve

>>> DjwStone <D.Stone at ED.AC.UK> 06/16/06 11:31 AM >>>
Is there any way to get the query template (LAYER/CLASS/TEMPLATE) to open in
a separate window?

Cheers,

Dave
--
View this message in context: http://www.nabble.com/Query-templates-t1799326.html#a4903724
Sent from the Mapserver - User forum at Nabble.com.



More information about the mapserver-users mailing list