Wonky Submit & Print-O-Matic Button

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:

  1. 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]

  2. 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" />

  3. be sure the ‘Shortcode Loads Scripts’ checkbox is NOT checked in the plugins options page.

Update: This is no longer supported in the current version of print-o-matic. Here is how to implement this solution with print-pro-matic.

2 Replies to “Wonky Submit & Print-O-Matic Button”

  1. Hello,

    I have added your code but it doens’t work for me. When is press submit the printomatic page will be blank. I hope you find the solution for me.

    Thanks,

    Cees

Comments are closed.