Jump to content
Sign in to follow this  
pintsize

add print page icon and function?

Recommended Posts

pintsize

Sorry to bother you again. Is there an easy way to add a page print function to the sidebar? Any tips for creating a print.css version for this template?

Share this post


Link to post
Share on other sites
Andrew

sure, just create a new file 'print.css' and include it in the header.php file (as a print css doc -- google search on this) Then in this file; you'll want to hide the sidebar; e.g. `#sidebar{display:none}` and make the content area fill the width of the page...

Share this post


Link to post
Share on other sites
meredithpintsizecom

I am finally trying to implement the print style sheet. Does this look correct? `` I'd like to add a little print icon at the bottom of each page, but not in the footer. Which template file should I edit to do this? Thanks for your help.

Share this post


Link to post
Share on other sites
cmunns

I would add it to footer.php if you want it on each page :) Yes, that looks correct (assuming that's how CSS_FOLDER is what is used in your theme )

Share this post


Link to post
Share on other sites
meredithpintsizecom

Hopefully this is my last question on the subject. I have a good looking print.css file but the client really wants me to add a print icon, either in the footer or up next to the search. I'm assuming I can use some javascript to trigger the print function, but I don't know how to add javascript within php. Any clues for this? Thanks for all your kind help.

Share this post


Link to post
Share on other sites
cmunns

You would do it the same way as you would with HTML where you close the PHP, write the JS, then open the PHP back up to continue on the rest of the page. Also, I don't know if it's too late to do this http://wordpress.org/extend/plugins/printfriendly/ Also, this resource is pretty thorough and the link for "print" is a simple link tag with javascript http://www.sohtanaka.com/web-design/print-css-javascript-icons/

Share this post


Link to post
Share on other sites
meredithpintsizecom

Thanks, I did try the printfriendly plugin but it has ads and I didn't care for the print version it created. I will check out the link you provided. Thanks again for your help.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

×