Documentation

OptionSupport
in package

FinalYes

Thin wrapper over WordPress's option read API (`get_option`).

Isolates option reads behind a small seam so callers such as SettingsRegistrar and WpConfigResolver never touch the platform function directly, and stay unit-testable without a live wp_options table. Degrades to the supplied default when get_option is unavailable (WP-CLI / cron / boot before WordPress is loaded).

Public surface: consumers read their own plugin options through it, like the other public Support\* wrappers (MetaSupport, TransientSupport, CacheSupport).

Table of Contents

Methods

get()  : mixed
Read an option value, returning $default when WordPress is unavailable or the option is unset.

Methods

get()

Read an option value, returning $default when WordPress is unavailable or the option is unset.

public static get(string $name[, mixed $default = false ]) : mixed
Parameters
$name : string
$default : mixed = false
On this page

Search results