[Resolved] print stylesheet

Home Forums Support [Resolved] print stylesheet

Home Forums Support print stylesheet

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #134547
    xdaniel

    Hello Tom,

    is there an easy way to get a printable version only of the content? I tried to add this:


    @media
    print {
    .side-header, .main-navigation, .secondary-navigation, .right-sidebar, .left-sidebar, .footer-widgets {
    display: none;
    }

    body {
    font-family: Tahoma, Verdana, Arial, sans-serif;
    }
    }

    but now the complete print preview is empty ๐Ÿ˜‰

    Best, Daniel

    #134579
    Tom
    Lead Developer
    Lead Developer

    Weird, it shouldn’t be completely empty.

    Try this:

    @media print {
          .side-header, 
          .main-navigation, 
          .secondary-navigation, 
          .widget-area, 
          .footer-widgets {
                display: none;
          }
    
          body {
                font-family: Tahoma, Verdana, Arial, sans-serif;
          }
    }
    #134811
    xdaniel

    Yes Tom, that worked.

    I had a problem with my breadcrumbs i inserted in the hook “after header”.

    Thanks a lot, Daniel

    #134812
    Tom
    Lead Developer
    Lead Developer

    What was wrong with them?

    #134816
    xdaniel

    I insert Breadcrumbs NavXT in the hook with this code:

    <div class="grid-container grid-parent">
          <div style="background: #fff; padding: 5px;">
               <div class="breadcrumbs" xmlns:v="http://rdf.data-vocabulary.org/#">
        <?php if(function_exists('bcn_display'))
        {
            bcn_display();
        }?>
    </div>
          </div>
    </div>

    Then the printstylesheet didn’t work.

    I changed it to

          <div class="breadcrumb-bg">
               <div class="breadcrumbs" xmlns:v="http://rdf.data-vocabulary.org/#">
    ...

    and it works now with your code.

    #134817
    Tom
    Lead Developer
    Lead Developer

    Awesome, glad it’s working ๐Ÿ™‚

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.