Hi; how can a predefined text be printed in a html page? it means, when the "print this page" button/link is clicked all the elements in the window is printed even the button.
now is there any way to print just the texts & etc. without printing the buttons and unuseful elemets?
appreciating your replies.

What you will need is a separate stylesheet for your printing layout.
To insert it, put this into your head:

<link rel="stylesheet" type="text/css" href="/css/print.css" media="print" />

then in the stylesheet simply put: display:none; for each of the elements that you don't want to display.
Done. :)

What you will need is a separate stylesheet for your printing layout.
To insert it, put this into your head:

<link rel="stylesheet" type="text/css" href="/css/print.css" media="print" />

then in the stylesheet simply put: display:none; for each of the elements that you don't want to display.
Done. :)

Hi...

thank you, that's exactly what i was looking for!
regards

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.