Viewing 11 replies - 1 through 11 (of 11 total)
  • Have you validated the stylesheet?

    Thread Starter Sherry

    (@dreamer0201)

    How do you do that? I’ve been doing WordPress for many years and have not heard this. hmmm

    You have never validated your markup or your stylesheets?! It’s nothing that is specific to WordPress. It’s just good development practice generally. See Validating_a_Website.

    Thread Starter Sherry

    (@dreamer0201)

    I used to when I did static sites, but since I moved to WP, no I have not. I will look into it and see if there is something that is stopping the print from working.

    Thread Starter Sherry

    (@dreamer0201)

    I did a few pages and it’s all checking valid now. There was a couple tag errors on the home page, but nothing that would stop the @media print from being recognized. Any other suggestions?

    What happens if you turn it into a standalone print.css file?

    Thread Starter Sherry

    (@dreamer0201)

    the pages are completely blank.

    Sorry? What pages?

    Thread Starter Sherry

    (@dreamer0201)

    When I modified the header.php to link to separate print.css stylesheet all the pages came out blank for printing. The website was fine, but there was zip nadda nothing on the pages that showed up. Now, when I did that, I did not go in and set all the styles up for content, I just used the media print that was in the style sheet.

    Since the code I have now is not being recognized in the style.css, setting up all the code for .entry-content and sidebars, etc. would have to be done if I used separate print.css. Is that right? I did not set those up, just what I wanted modified for print.

    I just don’t understand why I’m having to go backwards and do it the way we used to. Why won’t the @media print work in the one style.css?

    My client is insisting on having the print work. I just have not had to worry about printing a web page in a long time.

    Sherry

    I just don’t understand why I’m having to go backwards and do it the way we used to.

    The idea is to slowly isolate the problem – hence moving the print CSS into its own sheet for the purposes of troubleshooting. But you do actually need some CSS in the print stylesheet. Preferably everything you previously had under @media print.

    Incidentally, all @media print does is allow to you load print CSS without making another http call.

    Thread Starter Sherry

    (@dreamer0201)

    Good points. I will re-set up the separate print.css to see if I can isolate.

    Thank you!

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘@Media Print not recognized’ is closed to new replies.