最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

Wordpress multisite apply different options over each site from same plugin

programmeradmin2浏览0评论

I created a plugin for the bootstrap navbar. Then I created an option page for my plugin. In my options page, I have two types of navbar (Default navbar and Full-width navbar) you can only choose one of them. I want to use WordPress multisite and create two sites within it. Then in the first site show the Default navbar and, in the second site, show the full-width navbar. Can I can activate the same plugin in each site and use different options in each site? Or must I install WordPress two times then using the plugin in each WordPress installation folder?

I created a plugin for the bootstrap navbar. Then I created an option page for my plugin. In my options page, I have two types of navbar (Default navbar and Full-width navbar) you can only choose one of them. I want to use WordPress multisite and create two sites within it. Then in the first site show the Default navbar and, in the second site, show the full-width navbar. Can I can activate the same plugin in each site and use different options in each site? Or must I install WordPress two times then using the plugin in each WordPress installation folder?

Share Improve this question edited Jul 6, 2019 at 18:10 Matthew Brown aka Lord Matt 1,0683 gold badges13 silver badges34 bronze badges asked Jul 3, 2016 at 21:48 Shwan NamiqShwan Namiq 3351 gold badge3 silver badges12 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 3

Put the plugin in the wp-content/mu-plugins directory. Each site in your network has its own _options table in the database so as long as you are using built-in WP functions for handling your plugin's options, each site will have its own distinct set of options.

发布评论

评论列表(0)

  1. 暂无评论