If you can make this an ASP page, code your two <input>
tags:
<INPUT Class="Text" NAME="102"
VALUE="<%=request("102")%>" TYPE="TEXT" SIZE="7"
MAXLENGTH="5">
and
<INPUT TYPE="text" NAME="103"
VALUE="<%=request("102")%>" SIZE="3"
MAXLENGTH="3" CLASS="Text">
If you can't use ASP, add this code to the <head> section
of your page.
<script>
function qsobj (){
var qvbl;
var qstring = "" + document.location.search.substring(1);
if (qstring != ""){
var qpairs = qstring.split("&");
for (i=0; i < qpairs.length; i++) {
qvbl = qpairs[i].split("=");
this["" + qvbl[0]] =
unescape(qvbl[1].replace("+"," "));
}
}
}
function getQS(avbl){
if (qstr[avbl] == null){
return "";
}else{
return qstr[avbl];
}
}
var qstr = new qsobj();
</script>
and then code your form fields like this:
<script>
document.write("<INPUT Class='Text' NAME='102' VALUE='" +
getQS("102") +
"' TYPE='TEXT' SIZE='7' MAXLENGTH='5'>");
</script>
and
<script>
document.write("<INPUT Class='Text' NAME='103' VALUE='" +
getQS("103") +
"' TYPE='TEXT' SIZE='3' MAXLENGTH='3'>");
</script>
Jim Buyens
Microsoft FrontPage MVP
http://www.interlacken.com
Author of:
*------------------------------------------------------*
|\----------------------------------------------------/|
|| Microsoft Office FrontPage 2003 Inside Out ||
|| Microsoft FrontPage Version 2002 Inside Out ||
|| Web Database Development Step by Step .NET Edition ||
|| Troubleshooting Microsoft FrontPage 2002 ||
|| Faster Smarter Beginning Programming ||
|| (All from Microsoft Press) ||
|/----------------------------------------------------\|
*------------------------------------------------------*
>-----Original Message-----
>Hi all,
>
>I would like to create a link on my page that sends a
zip code and radius to
>the following form:
>
><form method="POST"
action="http://zipfind.net/scripts/miles.exe">
> </TD>
> <TD>
> <FONT FACE="MS Sans Serif, Arial, Helvetica"
SIZE="1"><B>ZIP
>Code:</B></font><BR>
> <INPUT Class="Text" NAME="102" VALUE=""
TYPE="TEXT" SIZE="7"
>MAXLENGTH="5">
> </td>
> <TD>
> <FONT FACE="MS Sans Serif, Arial, Helvetica"
>SIZE="1"><B>Radius:</B></font><BR>
> <INPUT TYPE="text" NAME="103" VALUE=""
SIZE="3" MAXLENGTH="3"
>CLASS="Text">
> </TD> <td>
> <INPUT NAME="1002" TYPE="SUBMIT" VALUE="Find
Zip Codes"
>Class="Submit">
> </td>
> <TD></form>
>
>I tried http://http://zipfind.net/scripts/miles.exe?
102=80241&103=5 to
>submit a zip of 80241 and a radius of 5, but it does not
return a valid
>page. Can anyone decipher what I am doing wrong?
>
>Thanks in advance,
>
>hyperless in denver
>
>
>.
>