: 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_RequestVar extends Tbp_Dynamic_Item {
function get_category() {
return array( 'text', 'textarea', 'wp_editor' );
return __( 'Request Variable', 'tbp' );
function get_value( $args = array() ) {
$args = wp_parse_args( $args, array(
if ( $args['method'] === 'get' && isset( $_GET[ $args['name'] ] ) ) {
$value = $_GET[ $args['name'] ];
} elseif ( $args['method'] === 'post' && isset( $_POST[ $args['name'] ] ) ) {
$value = $_POST[ $args['name'] ];
'label' => __( 'Method', 'tbp' ),
'get' => __( 'GET', 'tbp' ),
'post' => __( 'POST', 'tbp' ),
'label' => __( 'Name', 'tbp' ),