options - centralized alternative for get_option: get_site_option, get_network_option or get_site_meta?

admin2025-06-03  3

When storing option for current-site (sub-site), we use get_option, however, when we want to have one centralized option (which should apply to all sub-sites, including the primary sub-site), which one is better to be used:

  • {get/update}_site_option
  • {get/update}_network_option
  • {get/set}_site_meta

so, in case the host is not Multi_Site, the function should automatically fallback to current site's option (as get_options does).

转载请注明原文地址:http://conceptsofalgorithm.com/Algorithm/1748943201a315029.html

最新回复(0)