Fires at the end of the widget control form.


do_action( 'in_widget_form', (array) $array ); 

Use this hook to add extra fields to the widget form. The hook is only fired if the value passed to the widget_form_callback hook is not false.

Note: If the widget has no form, the text echoed from the default form method can be hidden using CSS.

Parameters (1)

0. $array (array) => array( &$this, &$return, $instance )
The array.


To run the hook, copy the example below.
  1. // run the action 
  2. do_action( 'in_widget_form', $array ); 
The following example is for adding a hook callback.
  1. // define the in_widget_form callback 
  2. function action_in_widget_form( $array ) { 
  3. // make action magic happen here... 
  4. }; 
  6. // add the action 
  7. add_action( 'in_widget_form', 'action_in_widget_form', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the action 
  2. remove_action( 'in_widget_form', 'action_in_widget_form', 10, 1 ); 

Defined (1)

The action is defined in the following location(s).

  1. do_action_ref_array( 'in_widget_form', array( &$this, &$return, $instance ) );