Click to See Complete Forum and Search --> : print webpage as txt file...
Hi out there, i have a problem with printing my page...
I want to print a special *txt file if i use the print button in my webpage.
For example:
I have a disclaimer.htm and if someone want to print it out he get´s the disclaimer.txt
------------------------------------
<form>
<p align="center">
<INPUT TYPE=Button OnClick=?disclaimer.txt?
value="print">
</form>
----------------------------------------------------
i saw it, but did not find it till yet.
Have you heard of this posibility
You can specify an alternate document to print using this:
<link rel="alternate" media="print" href="printversion.txt">
could you give me an complet example?
Would this work with opera browser?
thx
It should work in Opera...
<html>
<head>
<link rel="alternate" media="print" href="printversion.txt">
</head>
<body>
This is the body... it shouldn't be printed.
</body>
</html>
Originally posted by pyro
It should work in Opera...
<html>
<head>
<link rel="alternate" media="print" href="printversion.txt">
</head>
<body>
This is the body... it shouldn't be printed.
</body>
</html>
Hi, this works fine, but how can i hide the info (link) below?
For example:
file://c:\Document%20and%....
What do you want to do? :confused:
Sorry, forget the last question!
Now i have an other problem with this script.
---------------------------------------------------
<script>
if (window.self) window.print();
</script>
<style>
---------------------------------------------------
It does not work with opera. Why?
A couple of things:
One, what is your if (window.self) doing in there?
Two, <script> should be <script type="text/javascript">
Three, Opera needs you to run the window.print() after the entire pages is loaded. Try this:
<script type="text/javascript">
function printPage() {
window.print();
}
window.onload = printPage;
</script>
ok, I see what you mean...
thx for your help!
I´m not as fit in scripting as you are, because I´m an absolutly non programmer, but i try to understand.
Now I´m able to print html page or txt file.
Thats what i wanted...
----------------------------------------------------------------
If i printed out my disclaimer, there i saw the Link (down the page) where it comes from printed out, too! Is it possible to hide this line?
For example the Disclaimer at my page:
look at http://www.hackstube.de/print/eng.htm