wpcf7_editor_panel_form()
Хуков нет.
Возвращает
null. Ничего (null).
Использование
wpcf7_editor_panel_form( $post );
- $post(обязательный)
- .
Код wpcf7_editor_panel_form() wpcf7 editor panel form CF7 6.1.5
function wpcf7_editor_panel_form( $post ) {
$description = sprintf(
/* translators: %s: URL to support page about the form template */
__( 'You can edit the form template here. For details, see <a href="%s">Editing form template</a>.', 'contact-form-7' ),
__( 'https://contactform7.com/editing-form-template/', 'contact-form-7' )
);
$formatter = new WPCF7_HTMLFormatter();
$formatter->append_start_tag( 'h2' );
$formatter->append_preformatted( esc_html( __( 'Form', 'contact-form-7' ) ) );
$formatter->end_tag( 'h2' );
$formatter->append_start_tag( 'fieldset' );
$formatter->append_start_tag( 'legend' );
$formatter->append_preformatted( $description );
$formatter->end_tag( 'legend' );
$formatter->call_user_func( static function () {
$tag_generator = WPCF7_TagGenerator::get_instance();
$tag_generator->print_buttons();
} );
$formatter->append_start_tag( 'textarea', array(
'id' => 'wpcf7-form',
'name' => 'wpcf7-form',
'cols' => 100,
'rows' => 24,
'class' => 'large-text code',
'data-config-field' => 'form.body',
) );
$formatter->append_preformatted( esc_textarea( $post->prop( 'form' ) ) );
$formatter->end_tag( 'textarea' );
$formatter->print();
}