: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
* @package Themify Builder Pro
* @link https://themify.me/
class Tbp_Dynamic_Item_FileContent extends Tbp_Dynamic_Item {
function get_category() {
return array( 'textarea', 'wp_editor' );
return __( 'File Content', 'tbp' );
function get_value( $args = array() ) {
if ( ! empty( $args['path'] ) ) {
$file = trailingslashit( ABSPATH ) . $args['path'];
if ( $wp_filesystem->is_file( $file ) ) {
$value = $wp_filesystem->get_contents( $file );
'label' => __( 'File Path', 'tbp' ),
'help' => sprintf( __( 'Path is started from: %s', 'tbp' ), trailingslashit( ABSPATH ) ),