I am a total beginner to JavaScript, but have coded in VBScript for a while.
I want to get the HTML source code for a file, so that the client can then send it out as a HTML formatted email newsletter.
I used jaredn's great tip in a previous thread, as follows:
<html id="wholedoc">
<body onLoad="allcode=wholedoc.innerHTML">
I than have a form with a hidden field named fullcode. I simply want to set the value of fullcode to the allcode variable! (should be easy)
When I write:
<input type="hidden" name="fullcode" value="document.write(allcode)">,
and the form is submitted, the value of fullcode is literally "document.write(allcode)"!!
How do I access this allcode variable?
many thanks in advance
I want to get the HTML source code for a file, so that the client can then send it out as a HTML formatted email newsletter.
I used jaredn's great tip in a previous thread, as follows:
<html id="wholedoc">
<body onLoad="allcode=wholedoc.innerHTML">
I than have a form with a hidden field named fullcode. I simply want to set the value of fullcode to the allcode variable! (should be easy)
When I write:
<input type="hidden" name="fullcode" value="document.write(allcode)">,
and the form is submitted, the value of fullcode is literally "document.write(allcode)"!!
How do I access this allcode variable?
many thanks in advance