"Stacey" <st****@optonline.net> wrote in message
news:ui*********************@news4.srv.hcvlny.cv.n et...
Here is a function that is declared in my html page. It is part of a
series of javascript that allows the user to draw a rectangle on a graphic. This
is called when the box is done, so I would like to send the screen coords
which I know already to a cgi script at this point below. Can anybody
help me?
Somebody mentioned this code, but I am not sure how exactly to go about
and where to put code etc etc. It uses the urlconnection. Not sure of
syntax. Thanks again.
http://www.javaworld.com/javaworld/j...javatip34.html
function dragDone(x,y) {
startlayer.moveTo(iX,iY)
alert("Box is done")
need to post to cgi here
}
function dragDone(x,y) {
startlayer.moveTo(iX,iY);
alert("Box is done");
if ("java"=="javscript") {
alert("Ask question in comp.lang.java.help");
} else {
alert("Ask question in comp.lang.javascript");
}
}
But if you really want to know, this is what I like to do:
I create a hidden frame, be it an iframe or from a frameset. Have a form in
there that will receive data from the dragDone(x,y) function. Submit the
form to you cgi. This will prevent the main window from submiting the data
(and prevent the user from doing more things). From what I'm guessing, you
may need some way to buffer the input and send larger packets of input
together.