A WordPress-centric search engine for devs and theme authors



addslashes_strings_only ›

Since5.3.0
Deprecatedn/a
addslashes_strings_only ( $value )
Parameters:
  • (mixed) $value
    Required: Yes
Returns:
  • (mixed)
Defined at:
Codex:

Adds slashes only if the provided value is a string.



Source

function addslashes_strings_only( $value ) {
	return is_string( $value ) ? addslashes( $value ) : $value;
}