Is there a way to do a “Print” to a web browser without it automatically inserting the etc. ?
I want to have it Print JUST what I specify, nothing more.
Thanks!
Is there a way to do a “Print” to a web browser without it automatically inserting the etc. ?
I want to have it Print JUST what I specify, nothing more.
Thanks!
Subject: Web “Print” without HTML padding
Sure – make sure the first line printed is:
Print {content-type: }
That can be “text/plain”, “application/vnd.excel”, “image/xml+svg” or whatever your heart desires.
Subject: RE: Web “Print” without HTML padding
Interesting. I just tried this (with both “text/plain” and “text/html”, and instead of printing out just the text as desired, the browser prompts to save the resulting output.
Any way around this, so that it prints out just the text?
Subject: RE: Web “Print” without HTML padding
If your url ends with “.txt”, it may reliably display in the browser without prompting for a save. To get “.txt”, just add a parameter to the URL – myurl?OpenDocument&display=file.txt
Subject: RE: Web “Print” without HTML padding
That’s up to the browser. When you print anything other than HTML, the browser (and the user prefs locally) determine what to do. Essentially, you are creating a text file. If you want it to display in the browser reliably, then it NEEDS to have the stuff.
Subject: RE: Web “Print” without HTML padding
I understand. Thanks a bunch!