Skip to content

Latest commit

 

History

History
36 lines (25 loc) · 961 Bytes

option.md

File metadata and controls

36 lines (25 loc) · 961 Bytes

Option

The Option class helps you retrieve options/settings data.

Basic usage

The Option class has only one method. The get method helps you retrieve your option value.

Option::get($optionGroup, $name);
  • $optionGroup: string. The option group slug name.
  • $name: string. The setting name.

The option group value depends on how you save your settings with the Page class. If you use sections with tabs, the option group value is the section name slug. If you use sections without tabs, the option group value is the page name slug.

If no value/setting is found, the value returned is an empty string.

Next

Discover the other features of the framework: