[Javascript] Getting New Data

Tim Makins timothy at utvinternet.com
Sat Feb 22 11:59:20 CST 2003


----- Original Message -----
From: "Peter Brunone" <peter at brunone.com>
To: <javascript at LaTech.edu>
Sent: 21 February 2003 19:37
Subject: Re: [Javascript] Getting New Data
> Tim,
>..... If not, consider creating a hidden frame that can reload
>and send its contents to its visible counterpart.  To notify the
>script that new data has arrived, you could trip some event on
>the page that you've wired to the positioning function, and
>you've got it made.

Hi Peter - thanks for your comments. I wonder if you would mind expanding on
your ideas just a little. I can see what you mean about the hidden frame,
but as to 'sending its contents', and 'trip some event', I'd like to hear
just a little more.

I came up with an idea of my own: Assume 'Frame_A' is the master, which has
a link to load 'Frame_B' with page_B.html. I can see page_B.html as
containing the following:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head>
<SCRIPT SRC="data_processor.js"></SCRIPT>
</head>
<body  onload="data_processor()">
<SPAN ID="data">datadatadatadatadatadatadata</SPAN>
</body></html>

and this should work, but ideally, I'd like the file to contain only data,
not the headers/footers as well, though this may be impossible.

Another idea: I wonder if I could use

<FORM name=F1 action="javascript:data_processor();"><input type="file"
name="data"></FORM>

to let someone locate a datafile on their PC, and get it processed. Has
anybody tried this ?

Tim in Ireland.





More information about the Javascript mailing list