Completed
Branch 3.0 (1aee71)
by Stephanie
03:09
created

FrmFieldHTML::default_html()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
/**
4
 * @since 3.0
5
 */
6
class FrmFieldHTML extends FrmFieldType {
7
8
	/**
9
	 * @var string
10
	 * @since 3.0
11
	 */
12
	protected $type = 'html';
13
14
	/**
15
	 * @var bool
16
	 * @since 3.0
17
	 */
18
	protected $has_input = false;
19
20
	public function default_html() {
21
		return '<div id="frm_field_[id]_container" class="frm_form_field form-field">[description]</div>';
22
	}
23
24
	/**
25
	 * @since 3.0
26
	 */
27
	protected function after_replace_html_shortcodes( $args, $html ) {
28
		FrmFieldsHelper::run_wpautop( array( 'wpautop' => true ), $html );
29
30
		$html = apply_filters( 'frm_get_default_value', $html, (object) $this->field, false );
31
		return do_shortcode( $html );
32
	}
33
34
	public function get_container_class() {
35
		return ' frm_html_container';
36
	}
37
38
	protected function include_form_builder_file() {
39
		return FrmAppHelper::plugin_path() . '/classes/views/frm-fields/back-end/field-html.php';
40
	}
41
}
42