Still not. maybe we also need to include the chart js on the page?
As of version 1.6.7c we introduced a new printstyle value ‘external’ for Print-O-Matic. Now it is possible to create an external button to trigger a print in a less-hacky way. Here is an example of this works: To print the following div with an id of ‘print_me_please’:
<div id="print_me_please">This is our target print element</div>
This is our target print element
First we create a kind of roll-your-own print trigger. The details that must be included are:
a unique id
a print-o-matic class such as printomatic or printomatictext
The final thing we need to do is include a hidden print trigger using a print-me shortcode with the same id as our external trigger and the new external printstyle attribute. This shortcode must be placed someplace on the same page, and will load in all the required scripts and settings to make the print trigger work correctly.
This will place the logo in the ::before pseudo class of the targeted print element. Let’s try it out:
Of course, with Print-Pro-Matic, if you want to add the logo to EVERY print page, you can simply use the Print Page Top HTML field to place any html, including images, in the upper part of the print page.
Keep in mind: When working with images that where not available on the display page (and therefore in the users cache) a bit of pause before print time will be needed to give the image time to load before triggering the print dialogue box.
This is a Dr. Frankenstein experiment with Contact Form 7’s Submit button and the Print-O-Matic Print button. In theory, when submitting this form, the form should also also force-launch the print dialogue. Years of working in UI tells us NOT do this, but hey, people still have music playing on page load, so what do we know.
[contact-form-7 id="1018" title="SubPrint"/]
To cross-breed the Submit button with the print-o-matic print trigger, use the roll-your-own method as follows:
create a cf7 submit/print button by assigning it a unique ID (in this case subprint) and a class of printomatic. [submit id:subprint class:printomatic]
manually insert a hidden input that has the ID of “target-” and a value of the target you wish to print. <input type="hidden" id="target-subprint" value=".wpcf7-form" />
be sure the ‘Shortcode Loads Scripts’ checkbox is NOT checked in the plugins options page.
It is a period of civil war. Rebel spaceships, striking from a hidden base, have won their first victory against the evil Galactic Empire. During the battle, Rebel spies managed to steal secret plans to the Empire’s ultimate weapon, the DEATH STAR, an armored space station with enough power to destroy an entire planet. Pursued by the Empire’s sinister agents, Princess Leia races home aboard her starship, custodian of the stolen plans that can save her people and restore freedom to the galaxy…