wp_slash_strings_only( mixed $value )
Adds slashes to only string values in an array of values.
Description Description
This should be used when preparing data for core APIs that expect slashed data. This should not be used to escape data going directly into an SQL query.
Parameters Parameters
- $value
-
(mixed) (Required) Scalar or array of scalars.
Return Return
(mixed) Slashes $value
Source Source
File: wp-includes/formatting.php
function wp_slash_strings_only( $value ) { return map_deep( $value, 'addslashes_strings_only' ); }
Expand full source code Collapse full source code View on Trac
Changelog Changelog
Version | Description |
---|---|
5.3.0 | Introduced. |