The WP SSR framework provides a fluent PHP API for creating Advanced Custom Fields (ACF) options pages — persistent, site-wide settings stored inDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/Ahondev/portfolio-v2/llms.txt
Use this file to discover all available pages before exploring further.
wp_options and accessible anywhere in PHP via get_field('field_name', 'option'). Options pages are defined in configuration/pages.php and automatically loaded by the framework at boot time through Option::init().
The Option Class
Options pages are created and configured through the static Option::create() factory, which returns a chainable Option instance. Once all tabs and fields are defined, call ->make() to register the ACF field group bound to the options page.
Option::create()
Option instance for chaining.
The unique menu slug for the options page. Used as the ACF location identifier and as the URL segment in the admin (
/wp-admin/admin.php?page={slug}).The page title shown in the browser tab and at the top of the options page in WP Admin.
A Dashicons identifier without the
dashicons- prefix. The framework prepends dashicons- automatically.The numeric position in the WordPress admin sidebar menu. Lower numbers appear higher. Standard WordPress items occupy positions 2, 4, 5, 10, 20, 25, 60, 65, 70, 75, and 80 — choose a gap to avoid conflicts.
Option->Tab()
Tab() multiple times appends additional tabs.
The display label for the tab.
An array of Extended ACF field objects. Common field types available from the
Fields are constructed with
Extended\ACF\Fields namespace:| Class | Description |
|---|---|
Text | Single-line text input |
Textarea | Multi-line text |
Image | Media library image picker |
URL | URL input with validation |
Select | Dropdown selection |
Repeater | Repeatable group of sub-fields |
WYSIWYGEditor | Full TinyMCE rich-text editor |
FieldClass::make(string $label, string $name).Option->make()
register_extended_field_group() with the accumulated tabs and fields. The field group is scoped exclusively to the options page via an ACF location rule (options_page equals $slug). Always call this last in the chain.
Defining Options Pages
All options pages must be defined insideconfiguration/pages.php. The framework calls Option::init() at boot time, which auto-requires this file:
configuration/pages.php and use the fluent API:
wp_options and can be retrieved anywhere in PHP:
Multi-Tab Example
Build richer settings pages by chaining multipleTab() calls before calling make():
WordPress Admin Settings (WP_Options)
Beyond ACF options pages, the framework exposes WP_Options — a fluent helper for tweaking native WordPress admin behaviour. Its configuration lives in configuration/options.php, auto-loaded via WP_Options::register().
WP_Options methods are:
| Method | Signature | Description |
|---|---|---|
removeMenuPages | array $pages | Hides admin menu items by their menu slug |
hideAdminBar | bool $hide | Shows or hides the admin toolbar on the frontend |
showOnFront | string $type | Sets show_on_front (page or posts) |
pageOnFront | string $slug | Sets the static front page by its post title |
useClassicEditor | array $postTypes | Forces Classic Editor for the given post types (requires the Classic Editor plugin) |
maxPostPerPages | int $nbPost | Sets posts_per_page globally |
adminTheme | string $theme | Sets the admin colour scheme for the current user |
WP_Options methods are chainable — every method returns the WP_Options instance so you can pipe as many calls as needed before the statement ends.