Forums

Redirecting print stylesheet to WP-Print (5 posts)

  1. bobjones
    Member
    Posted 8 months ago #

    Lester, WP-Print works fine when visitors select the WP-Print link I've added to single.php.

    However, when they print or print-preview through the browser, the browser uses my existing print style sheet.

    Is there any way I can redirect my print style sheet to WP-Print as well?

    My print style sheet appears in header.php this way:

    <link rel="stylesheet" href="http://www.mysite.com/wp-content/themes/mytheme/print.css" type="text/css" media="print" />

    Thanks!

  2. GamerZ
    Member
    Posted 8 months ago #

    WP-Print print-css.css will definitely be not compatible with it (as in when user go Print Preview.

  3. bobjones
    Member
    Posted 8 months ago #

    I've pasted the contents of my own print stylesheet into print-css.css, and it works quite well. I have no compatibility issues there.

    Are you saying that there is no way to make WP-Print intercept the browser's print or print-preview functions? That's what I'm really looking for.

    Because otherwise, this creates confusion for the visitor. They're going to get two different print views, depending on which print method they select.

    In fact, WP-Print actually presents a print preview and does not send the page right to the printer. Visitors have to hunt for the Click here to print link down at the bottom of the page. I'm not sure that's the best view to present to visitors.

    I hope you'll just take these comments as helpful suggestions, intended to provide visitors the best experience possible. Your plugins are great!

  4. GamerZ
    Member
    Posted 8 months ago #

    yes there is no way. Also there is no way to immediately popup a print window on mac. For windows I can use windows.print() but Mac do not have this function, so in order to keep the experience the same, I did not include the auto print popup.

  5. bobjones
    Member
    Posted 8 months ago #

    I've edited the language in print-posts.php to make the print link appear more prominently. It now appears at both the top and bottom of the page and looks like this:

    <p style="text-align: <?php echo $text_align_opposite; ?>;" id="print-link"><?php _e('', 'wp-print'); ?> <a href="#Print" onclick="window.print(); return false;" title="<?php _e('Print now.', 'wp-print'); ?>"><?php _e('Print now', 'wp-print'); ?></a> <?php _e('', 'wp-print'); ?></p>

Reply

You must log in to post.

About this Topic

Tags