I have a views page that lists nodes that contain uploaded PDF and bibtex files (see here). Everything looks fine when you view the page, but when you go to print it in the browser, the node path (from the linked title) and the path to the uploaded files are displayed. The client would like to be able to print the page without those paths being shown. Is there a way to suppress these paths when printing from the browser? I suggested having a link to another print friendly page, but he just wants to be able to print from the browser.

1 Answer 1


It sounds like a CSS issue. The most efficient way is to add a CSS to your theme whose media type is print (see below for example).

Assuming the part you want to hide is an element (div, span, etc) whose class is mycustomclass, inside that stylesheet you could add something like this.

.mycustomclass {
  display: none;
  visibility: hidden;

And this is the example mentioned above.

<link type="text/css" rel="stylesheet" href="http://www.example.com/sites/all/themes/mytheme/print.css" media="print" />

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.