3.2.0

Saving contents of a frame through another frame

Hi,
i have a html page which contains 2 frames. How can i save the contents of frame2 as a html file using a button click in frame1?
Manu
June 26,
u cant save the file in client using javascript, however to get content of html its simple:
<html>
<head>
<script>
function showMeFrame2() {
   alert(document.getElementById("fm2").innerHTML);
}
</script>
</head>
<body>
<input type='button' name='b1' id='b1' value='Show FM2 Content' onClick='showMeFrame2()'>
<iframe id='fm2' name='fm2' src='another_file.html'></iframe>
</body>
</html>
// another_file.html
<html>
<body>
<h1>HELLO WORLD!</hi>
</body>
</html>
Paulo Cesar Silva Reis (PC from Brazil)
June 27,

This topic is archived.

See also:


Back to support forum