sanitize_key [ WordPress Function ]
sanitize_key ( $key )
| Parameters: |
|
| Returns: |
|
| Defined at: |
|
Sanitize a string key.
Keys are used as internal identifiers. Lowercase alphanumeric characters, dashes and underscores are allowed.
Examples [ wp-snippets.com ]
Top Google zoekresultaten
- Function Reference/sanitize key « WordPress Codex
Description. Sanitize a string key. Keys are used as internal identifiers. Lowercase alphanumeric characters, dashes and underscores are allowed.
codex.wordpress.org - #14910 (Simplify sanitize_key() and use it in more places ...
sanitize_key() does some unnecessary work that can be eliminated. sanitize_user() is still being called in places where sanitize_key() should be used and can ...
core.trac.wordpress.org - Inconsistencies in sanitize_user and sanitize_key - WordPress Trac
It seems to me that sanitize_user can perform inconsistently by returning a different string compared to the input when passed a previously sanitized string.
core.trac.wordpress.org - #20202 (Filter pre_post_type with sanitize_key()) – WordPress Trac
Currently the post_type field is sanitized with sanitize_user(). It would make more sense to use sanitize_key() for this because. register_post_type() uses ...
core.trac.wordpress.org