Site logo

Archived topic

Print css

3 replies · Started by Franz on March 21, 2021

Viewing posts 1–4 of 4

hello,

I want to customize the printout of my website (using generate press pro and the latest version of Wordpress). So I learned from Wordpress support, that a print.css file can be added to the theme folder(and linked to header.php) in order to specify the print out.

However, I am wondering, if that is the correct way, when learning that generate press is working with "Dynamic CSS Print Method. I made a search in your documentation with this term, did not find anything explaining this issue. I could find lots of blog discussions in the forum about this issue, but this gives me not an overall image, what is the Dynamic CSS Print Method.

So may question is: which way should I go? dynamic css, static print stylesheet or a plugin such as simple css? I have to emphasize, that I plan to optimize the print out quite havily ... And, if dynamic print css is your choice, do you have somewhere a comprehensive instruction about how it works?

Kind regards

Franz

Hi there,

If you plan to heavily customize the print stylesheet, your best bet is to do a custom print.css file as you've learned from WordPress support since dynamic values come from the customizer setting which you may find insufficient for very specific styling.

Note: Better do this on a child theme, like this - https://generatepress.com/forums/topic/how-to-enqueue-a-stand-alone-media-print-css-file/ - as changes done on the base theme files will be wiped if you update it.

Many thanks Elvin,

you recommand to use a child theme, but I will modify only the print.css and some few php code in the plugin snippets. So in Generate Press support, they say that it is not necessary to use a child theme in that case? So what?

And again, do you have a useful link to explain, what is the "Dynamic CSS Print Method"? Just to get in touch with new know-how......

Kind regards
Franz

Hi there,

It isn't necessary to use Child Theme... but when you're creating larger customizations then it is advisable.

The Dynamic CSS is related to the CSS generated by the Customizer Settings - it only applies here.

This archived topic is closed to new replies.