/    Sign up×
Community /Pin to ProfileBookmark

Hiding certain data when printing

I have a page where there are some buttons to set parameters for the page. When printing I would like not to print those buttons. Is there something with ‘@media print’ that I can use to hide this when printing?

to post a comment
CSS

4 Comments(s)

Copy linkTweet thisAlerts:
@NogDogAug 23.2005 — I believe (but have not tried it) that you could do:

CSS:
<i>
</i>@media print {
.noprint {
display: none;
}
}

HTML:
<i>
</i>&lt;a href="somelink.html" class="noprint"&gt;&lt;button img="button.gif"&gt;&lt;/a&gt;
Copy linkTweet thisAlerts:
@DecebalauthorAug 23.2005 — I tried it with a <div class="noprint"> and it works. ?

Thanks.
Copy linkTweet thisAlerts:
@NogDogAug 23.2005 — I tried it with a <div class="noprint"> and it works. ?

Thanks.[/QUOTE]

You're welcome. ?
Copy linkTweet thisAlerts:
@Ben_RogersAug 23.2005 — Please take note to check common reference sites first. [url=http://www.alistapart.com/articles/goingtoprint/]"Going To Print,"[/url] on A List Apart.
×

Success!

Help @Decebal spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.5,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...