Question

I am using WPMU but there are some options that the administrator should set and should take affect for every user of the website. Does wordpress have a place to store these global options? Can anyone point me to sample code?

Thanks!

Was it helpful?

Solution

My first instinct would be to create my own table to store these options. Then you have complete control over when, where, and by whom the data is accessed ... globally across all of your MU blogs.

As far as sample code goes, I'd suggest starting in the codex or trying to walk through this tutorial.

OTHER TIPS

As of Wordpress 3.0 you can use add_site_option, update_site_option and get_site_option to get the option from a blog with a specific ID. So just store all admin options on one site, save that site's ID as a constant and then get all option from there.

http://codex.wordpress.org/WPMU_Functions/get_site_option

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top