This is a test to see if print-pro-matic can print an external URL:
There will be an issue with cross domain origin, however a url on the same domain can be printed:
This is a test to see how print-o-matic and print-pro-matic handle targeting a non-existing element:
[print-me target="#aintnosunshinewhenshesgone" /]
No element? no problem… do nothing.
Now what happens if we have one element that does not exist in a list of elements:
[print-me target="non_elem, #printbox" /]
As of print-o-matic version 2.0.1 the ability to use class to target a print element in external print triggers has been added. Basically it works the same as using the data-print_target attribute but instead uses a unique classname in the format of printtarget-<target_id>.
Create a target element. The element below is a div with an id of ‘my_print_target’:
<div id="my_print_target">This is the print target wrapped in a div with an element of 'my_print_target' as explained above</div>
Add an external trigger using the new class-trigger method. We’ll use a simple button like so:
<button id="my_print_button" class="printomatic printtarget-#my_print_target">Print Trigger</button>
Like in the original example, we need to add the hidden print trigger using a print-me shortcode with the same id as our external trigger and a printstyle=”external” attribute:
[print-me id="my_print_button" printstyle="external"/]