Code Duplication    Length = 7-7 lines in 2 locations

classes/models/FrmEntryFormat.php 1 location

@@ 220-226 (lines=7) @@
217
	private static function maybe_strip_html( $plain_text, &$val ) {
218
		_deprecated_function( __FUNCTION__, '2.04', 'instance of FrmEntryValues or FrmProEntryValues' );
219
220
		if ( $plain_text && ! is_array( $val ) ) {
221
			if ( strpos( $val, '<img' ) !== false ) {
222
				$val = str_replace( array( '<img', 'src=', '/>', '"' ), '', $val );
223
				$val = trim( $val );
224
			}
225
			$val = strip_tags( $val );
226
		}
227
	}
228
229
	/**

classes/models/FrmEntryFormatter.php 1 location

@@ 638-644 (lines=7) @@
635
				foreach ( $value as $key => $single_value ) {
636
					$value[ $key ] = $this->strip_html( $single_value );
637
				}
638
			} else if ( $this->is_plain_text && ! is_array( $value ) ) {
639
				if ( strpos( $value, '<img' ) !== false ) {
640
					$value = str_replace( array( '<img', 'src=', '/>', '"' ), '', $value );
641
					$value = trim( $value );
642
				}
643
				$value = strip_tags( $value );
644
			}
645
		}
646
647
		return $value;