0

Working on converting a custom plugin to run in multisite. I want the settings to apply globally, not per-site. I've converted all of the get_option calls to get_site_option and the equivalent for set_option.

But, how do you register a setting in the UX that saves globally to sitemeta instead of options?

1 Answer 1

0

It is quite similar to regular options pages, you just need to use network_admin_menu hook instead of admin_menu.

As for register_settings() function, as I know, there is no equivalent yet. So, we have to work with HTML when creating options pages.

You can check this tut https://rudrastyh.com/wordpress-multisite/options-pages.html

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.