Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: javascript

by willdooUK (Beadle)
on Apr 02, 2001 at 15:04 UTC ( #68973=note: print w/ replies, xml ) Need Help??


in reply to Executing CGI script via Javascript

Slightly off-topic (wot no perl), but I'm sure someone can make use of this.

I've written a couple of Javscript modules (with API-like interfaces) that might be useful to cgi guys. In particular there's one called query.js which implements a Query class; this lets you interact and code with the query string using three or four simple commands, eg:

var query = new Query(document.location.search); var names = query.getNames(); var pName = document.forms[0].pName.value; var pValue = document.forms[0].pValue.value; query.addParameter(pName, pValue); alert(query.toQueryString());
Using this interface makes it a lot easier to collect parameters and hit a cgi script. It also makes it easy to send data from one webpage to the next (so forms can be spread over two pages, for example).

This script is online at www.javascriptguru.co.uk (along with examples) if you're interested.

willdooUK
--------------


Comment on Re: javascript
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://68973]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (14)
As of 2014-07-23 21:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (152 votes), past polls