Put your text ad here
WestNIC provides reliable web hosting services
25% off cpanel web hosting and reseller hosting deals. Promo: codestyle25off
This answer is part of the Code Style premium content package. You must have a premium content subscription to log in and view the full answer to this question.
Use the premium content subscription form below for full access to all premium content FAQs, or the FAQ by email option for the answer to this FAQ only.
A: Javascript has practically no print configuration options, so it is not possible to control whether the page background is printed or not. If you want to prevent the page background from being printed you can use a media dependent style sheet to set a plain background colour and override any background images that have been set.
Print media style sheets are attached using stylesheet link elements in the head of an HTML document with a media="print" attribute, as below.
… premium content omitted
Get full access to all FAQs, subscribe now for $40
Can we edit the print background property with Javascript?
You must make a subscription payment to access areas flagged premium content. Use the form below to create an account via PayPal.
The PayPal service allows you to pay securely and independently in your own currency. Payments are billed to Metacentric Internet Limited. We never handle your credit card details.
The Code Style site has accumulated 8 years' worth of answers to the most common Web development questions. Answers are written in clear English with examples and links to other Web resources. Your subscription provides full answers to all premium content questions listed below and other FAQ sections, plus:
onclick event on my button is not working! (stub article)
iframe browser and filter the URLs? (stub article)