How to create placeholder for iframe or when page is printed
-
For the first time, I’m paying proper attention to how my site appears when printed. The CSS tweaks turned out to be really easy. I have everything looking the way I’d like except for one thing: embeds. Authors on our site use a lot of video and audio embeds (YouTube, Vimeo, Soundcloud, etc.), and, just like embeds are supposed to, they by default don’t appear when the page is printed.
Typically that’s a nice way to save paper and hide something that, obviously, is of little use in hard copy. But it my case I work with a lot of people who need to cite a “complete” hard copy, one that makes it clear if something is missing, and they can’t do that if the printed version reads:
…as demonstrated in:
…Thus, this proves our argument.
So what I’m hoping to learn from you guys is whether there’s CSS or other method that says, “If this iframe or embed is being printed, replace it with x” — with “x” being some standard replacement text, image, or empty box. The important thing to keep in mind is I have hundreds of posts with embeds. Presumably I could go back and edit every single one (applying a CSS statement to <div id=”dont-print-video”><embed[…]/embed></div>), but that’s a) misery and b) practically speaking won’t get used going forward on a multi-author site such as mine.
I don’t need a fancy solution…just something that communicates “Yeah there’s something right here but you’ll need to go online to see it”. Just anything that keeps me from having to go back and add inline code to 400 past posts and every new one.
- The topic ‘How to create placeholder for iframe or when page is printed’ is closed to new replies.