<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1491" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Richard,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Try putting something like&nbsp;this inside your 
form:</FONT></DIV>
<DIV><FONT size=2><FONT face=Arial></FONT></FONT>&nbsp;</DIV>
<DIV><FONT size=2><FONT face=Arial>&lt;SELECT NAME='map_size' 
ID='mapsize'&gt;<BR>&lt;OPTION VALUE="600+300"&gt;600 x 300<BR>&lt;OPTION 
VALUE="800+400"&gt;800 x 400<BR>&lt;/SELECT&gt;</FONT></DIV>
<DIV>
<P><FONT face=Arial>Then have a bit of javascript like this:</FONT></P>
<P><FONT face=Arial></FONT><FONT face=Arial><BR>&lt;script&gt;<BR>function 
onLoadFunction ()<BR>{ </P>
<P>urlstring = location.href;<BR>&nbsp;&nbsp; if (urlstring.match("600+300") != 
null)<BR>&nbsp;&nbsp; {<BR>&nbsp;&nbsp; document.forms[0].map_size.value = 
"600+300";<BR>&nbsp;&nbsp; }<BR>&nbsp;&nbsp; else<BR>&nbsp;&nbsp; 
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (urlstring.match("800+400") != 
null)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
document.forms[0].map_size.value = "800+400";<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
}<BR>&nbsp;&nbsp; }</P>
<P>}<BR>&lt;/script&gt;</FONT></P>
<P><FONT face=Arial>Make sure the body has something like:</FONT></P>
<P><FONT 
face=Arial>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
&lt;body onload="onloadFunction()"&gt;</FONT></P>
<P><FONT face=Arial>I have not really tested this code, but it should work. It 
basically puts in a dropdown selector for the mapsize form variable. When the 
page is loaded, the javascript checks out the URL, searching for the value of 
the map_size. Make sure there are no other form variables with similar values, 
because it might pick those up too. It sets the dropdown box to the value it 
found in the URL.</FONT></P>
<P><FONT face=Arial>Let me know if you have any troubles.</FONT></P>
<P><FONT face=Arial>Jacob</FONT></P>
<P><FONT face=Arial></FONT></FONT>&nbsp;</P></DIV>
<DIV><FONT face=Arial size=2>-----Original Message-----<BR>From: UMN MapServer 
Users List [mailto:MAPSERVER-USERS@LISTS.UMN.EDU] On Behalf Of Richard A. 
Milewski<BR>Sent: 11 March 2005 13:29<BR>To: <A 
href="mailto:MAPSERVER-USERS@LISTS.UMN.EDU">MAPSERVER-USERS@LISTS.UMN.EDU</A><BR>Subject: 
Re: [UMN_MAPSERVER-USERS] Controlling mapsize in CGI</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Stephen,</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Thank you for the speedy reply!&nbsp; I don't have 
any trouble setting the size<BR>in the querystring, that works reliably.&nbsp; 
The problem is in showing a<BR>checkbox or the default value in a drop-down box 
that shows the current<BR>setting. How do I handle the problem on the cgi/html 
side.</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Thanks!</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>-- Richard<BR></FONT></DIV></BODY></HTML>