bbp_sanitize_val( string $request = '', string $input_type = 'text' )

Echo sanitized $_REQUEST value.

Description

Use the $input_type parameter to properly process the value. This ensures correct sanitization of the value for the receiving input.

Parameters

$request

(string) (Optional) Name of $_REQUEST to look for

Default value: ''

$input_type

(string) (Optional) Type of input. Default: text. Accepts: textarea|password|select|radio|checkbox

Default value: 'text'

Source

File: bp-forums/common/template.php

function bbp_sanitize_val( $request = '', $input_type = 'text' ) {
	echo bbp_get_sanitize_val( $request, $input_type );
}

Changelog

Changelog
Version Description
bbPress (r2815) Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.