I am trying to write a single piece of data (that is generated from a
Javascript) to a text file on my server via a Perl script.
The Javascript is setup so that I can display the required data on my
website using the following HTML:
<span name='Data1' class='data1'></span>
But I need it sent to a text file. :(
I have tried using the following code (thanks to saxifrax) to send the data
to a Perl script:
var i=new Image();
i.src="http://www.mydomain.co m/cgi-bin/write.pl?" + span;
But it doesn't return anything.
If I test my Perl script with this:
var i=new Image();
i.src="http://www.mydomain.co m/cgi-bin/write.pl?" + "test";
Then it returns the word "test" - so I know the Perl script is working.
When I try this:
var i=new Image();
i.src="http://www.mydomain.co m/cgi-bin/write.pl?" + allSpans;
Then it returns "Object" - whatever that means.
Anyone have any advice on how to get the data sent to my Perl file?
Thanks :)
-Von
Javascript) to a text file on my server via a Perl script.
The Javascript is setup so that I can display the required data on my
website using the following HTML:
<span name='Data1' class='data1'></span>
But I need it sent to a text file. :(
I have tried using the following code (thanks to saxifrax) to send the data
to a Perl script:
var i=new Image();
i.src="http://www.mydomain.co m/cgi-bin/write.pl?" + span;
But it doesn't return anything.
If I test my Perl script with this:
var i=new Image();
i.src="http://www.mydomain.co m/cgi-bin/write.pl?" + "test";
Then it returns the word "test" - so I know the Perl script is working.
When I try this:
var i=new Image();
i.src="http://www.mydomain.co m/cgi-bin/write.pl?" + allSpans;
Then it returns "Object" - whatever that means.
Anyone have any advice on how to get the data sent to my Perl file?
Thanks :)
-Von
Comment