CSS supports media queries since Level 2, Revision 1. That's from way back in 2011, so any modern web browser should support it.
If you're able to specify custom CSS, and apply custom CSS classes to your content, then you can define a CSS class such that the pictures and other ancilliary content is shown on screen, but only the actual recipe is printed on paper.
This way, you don't need to have a separate "printer friendly" page, because you're using CSS to define what "printer friendly" means for your particular content. Of course, it assumes that you have control over the CSS in the first place!
Specifically, as discussed on MDN, you can either target print
media, or a specific characteristic of a media (a feature). For the former, you'd add something like
@media print {
img.food-photo { display: none; }
body { color: black; }
}
to hide food-photo
class img
s and set the text color to black
. For the latter, you can target non-color by writing something like
@media not color /* untested, but looks like it should work */ {
body { color: black; }
}
to set the text color to black
where color is not supported.
I came across a Stack Overflow question at What does @media screen and (max-width: 1024px) mean in CSS? which has some more complex examples that you may find enlightening.