Auto Load Plugin Hooks inside Must Use Plugin
With Multisite, you need to use add_site_option/get_site_option instead of add_option/get_option. https://codex.wordpress.org/Function_Reference/get_site_option
With Multisite, you need to use add_site_option/get_site_option instead of add_option/get_option. https://codex.wordpress.org/Function_Reference/get_site_option
You might check in General Settings: Home URL should be http://example.com Site URL should be http://example.com/wp When you open http://example.com, what URL does it show for …/twentythirteen/style.css? Do you see the “broken” URL http://example.com/wp/test-network-site/wp-content/themes/twentythirteen/style.css in the source? If so, it suggests WordPress might be using a wrong path (not necessarily nginx). I think that should … Read more
I created a plugin which does something similar (called Multisite Post Display https://wordpress.org/plugins/multisite-post-reader/ ) . It displays posts from all multisite sub-sites. The code in there might be helpful for what you are doing. You are welcome to dig into it and use the code to help with your project. (After all, I used other … Read more
Potential Issues Google’s Page Speed service does not work with “naked domains”. That is, it will not work with just “example.com”. The domain name must have a subdomain in front of it, such as “www.example.com”. This is due to a limitation on Google’s implementation of the Page Speed service, which requires you to set up … Read more
What @petermolnar suggested also redirects your users to the main site if they want to register (I’ve tested this but feel free to make use of it. It’s good practice). What you need is a registration/login/edit-profile plugin for the front end: http://www.cozmoslabs.com/1341-wordpress-profile-builder-a-front-end-user-registration-login-and-edit-profile-plugin/ It’s shortcode based so all you have to do is redirect your users … Read more
Here’s an example of a solution I configured, which leaves the site in the network, but establishes a domain map from any registered domain, to the network. It makes the network site appear to be a completely independent site, with all the functionality (log-in, etc.) intact. Goal: Map client’s registered domain, both www.foosite.com and foosite.com … Read more
You will not be able to enable the checkbox for non-super-admins as the code for it shows: <?php if ( is_multisite() && is_super_admin() ) { ?> <tr> <th scope=”row”><label for=”noconfirmation”><?php _e(‘Skip Confirmation Email’) ?></label></th> <td><label for=”noconfirmation”><input type=”checkbox” name=”noconfirmation” id=”noconfirmation” value=”1″ <?php checked( $new_user_ignore_pass ); ?> /> <?php _e( ‘Add the user without sending them a … Read more
Use get_current_blog_id() to check the current site. To run on site 2 only, use this: function new_meta_values($order_id) { if ( 2 !== get_current_blog_id() ) return; /* the rest of the function code */ }
Personally, I use none of them. And an NDB cluster instead. NDB is MySQL’s built-in master-master replication engine. The only limitation of NDB in practice is the lack of full text index. But you can always use yahoo or google’s API for searches within your site. I found it worth the extra redundancy, especially when … Read more
Don’t touch the load order, change the activation order instead. A working example can be found in this answer.