APIs on form output

API form output

Hook: ipt_fsqm_hook_form_before

Triggered right before the output of the actual form. This is triggered only if the form is submitable.

Hook Uses

Accepts one parameter, a reference to the IPT_FSQM_Form_Elements_Front object.

[php]
/**
* Hooks into fsqm form output (before all elements)
* And prints some custom HTML
*
* @param object $obj Reference to the IPT_FSQM_Form_Elements_Front object that has called hook
*/
function fsqm_form_before( $obj ) {
// Do something before all elements of the form
$obj->ui->heading( __( ‘Howdy’, ‘domain’ ), ‘h2’, ‘center’, ‘none’ );
}
add_action( ‘ipt_fsqm_hook_form_before’, ‘fsqm_form_before’, 10, 1 );
[/php]

Source

Located in classes/class-ipt-fsqm-form-elements-front.php.

Hook: ipt_fsqm_hook_form_after

Triggered right after the form output. Triggered only if the form is submitable.

Hook Uses

Accepts one parameter, a reference to the IPT_FSQM_Form_Elements_Front object.

[php]
/**
* Hooks into fsqm form output (after all elements)
* And prints some custom HTML
*
* @param object $obj Reference to the IPT_FSQM_Form_Elements_Front object that has called hook
*/
function fsqm_form_after( $obj ) {
// Do something after all elements of the form
$obj->ui->heading( __( ‘Buh Bye!!!’, ‘domain’ ), ‘h2’, ‘center’, ‘none’ );
}
add_action( ‘ipt_fsqm_hook_form_after’, ‘fsqm_form_after’, 10, 1 );
[/php]

Source

Located in classes/class-ipt-fsqm-form-elements-front.php.

Hook: ipt_fsqm_hook_form_fullview_before

Triggered before the full view of the form. Unlike ipt_fsqm_hook_form_before, it is always triggered (in trackback as well as form).

Hook Uses

Accepts one parameter, a reference to the IPT_FSQM_Form_Elements_Front object.

[php]
/**
* Hooks into fsqm form output (full view)
* And prints some custom HTML
*
* It gets triggered whenever the form is about to be shown
* No matter if it is for update, new submission or trackback
*
* @param object $obj Reference to the IPT_FSQM_Form_Elements_Front object that has called hook
*/
function fsqm_form_fullview( $obj ) {
// Do something after all elements of the form
$obj->ui->heading( __( ‘Check out the coolest form ever.’, ‘domain’ ), ‘h2’, ‘center’, ‘none’ );
}
add_action( ‘ipt_fsqm_hook_form_fullview_before’, ‘fsqm_form_fullview’, 10, 1 );
[/php]

Source

Located in classes/class-ipt-fsqm-form-elements-front.php.

Swashata has written 257 articles

Hi there, I am the Lead Developer at WPQuark.com. I love to create something beautiful for WordPress and here I write about how to use them. When I am not working, usually I am doing a number of other creative things ;).

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

This site uses Akismet to reduce spam. Learn how your comment data is processed.