[thelist] java script and forms

Jon Hall jonhall at ozline.net
Thu Jun 7 10:52:17 CDT 2001


O'Reilly's Javascript book is the best.

jon
----- Original Message -----
From: "Oliver Lockwood" <isdarksaber at hotmail.com>
To: <thelist at lists.evolt.org>
Sent: Thursday, June 07, 2001 10:55 AM
Subject: RE: [thelist] java script and forms


> cheers for that but I don't know how to use a url "scope" ro recall the
> values so I'm still suck!! How do I do this?
>
>
> >:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> >: From: Oliver Lockwood
> >:
> >:
> >: brotherb.html?mfa=asdf&mfb=asdf&mfc=asdf&ffa=asdf
> >:
> >: I'm just wondering how I actually recall these
> >: variables in the new page??
> >:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> >
> >if you've gotta do it client-side, then you only need 8 lines of script
to
> >accomplish it.
> >
> >var qs = location.search.substring(1);
> >var nv = qs.split('&');
> >var url = new Object();
> >for(i = 0; i < nv.length; i++)
> >{
> >   eq = nv[i].indexOf('=');
> >   url[nv[i].substring(0,eq).toLowerCase()] = unescape(nv[i].substring(eq
+
> >1));
> >}
> >
> >the variables will now be available in a url "scope".
> >
> >url.mfa, url.mfb, url.mfc, url.ffa, etc.
> >
> >good luck,
> >
> >.jeff
> _________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
>
>
> ---------------------------------------
> For unsubscribe and other options, including
> the Tip Harvester and archive of TheList go to:
> http://lists.evolt.org Workers of the Web, evolt !





More information about the thelist mailing list