Opens in a new tab
A picture of Jeff Brigman
I CODE TODAY FOR
A BETTER TOMORROW

Glossary Term

sanitize_user_field()

3 tags 1 category

sanitize_user_field() — Sanitizes user field based on context. Possible context values are: ‘raw’, ‘edit’, ‘db’, ‘display’, ‘attribute’ and ‘js’. The ‘display’ context is used by default. ‘attribute’ and ‘js’ contexts are treated like ‘display’ when calling filters.

Inputs: $field (string): The user Object field name. $value (mixed): The user Object value. $user_id (int): User ID. $context (string): How to sanitize user fields. Looks for ‘raw’, ‘edit’, ‘db’, ‘display’, ‘attribute’ and ‘js’.

Returns mixed: Sanitized value.

Term Connections

Explore related terms connected by shared tags, shared categories, and relationship phrases. This map loads only when it comes into view.

Loading term connections…