Nested folder paths for WordPress multisite
Nested folder paths for WordPress multisite
Nested folder paths for WordPress multisite
I have write : <?php $blog_id = get_current_blog_id(); ?> <?php if( 1 == $blog_id ); ?> <div id=””><script src=””></script><script src=”” ></script></div> <?php elseif( 2 == $blog_id ): ?> <div id=””><script src=””></script><script src=”” ></script></div> <?php else: ?> Default script <?php endif; ?> It correct !?
ajax returns -1 in multisite sub domain
Sending SMTP mail using a server with self-signed SSL
There is really no answer given the limited facts in the question. Are you requiring that users login to see pages/data? If not I don’t see why you would care to share user tables. There will be some things that multisite will handle better but there will be some things (handling certain plugins) that multisite … Read more
There are several options, you might want to combine them in some way. The list is in an increasing order of complexity and time that you will need to spend to implement it. Backup plugins. They usually do a full backup of the site and let you restore it into different domain. You can automate … Read more
I solved this and I only use: wp_login_form(); Since I don’t want users to get access to the wp-admin area at all I use the following code: // Restrict users from accessing the admin-area function restrict_admin() { if ( ! current_user_can( ‘manage_sites’ ) ) { wp_redirect( site_url() ); } } add_action( ‘admin_init’, ‘restrict_admin’, 1 ); … Read more
Your rule do not match the structure of the url you want. The rule basically handles urls with only a country. What is the right rule? you will need to look at the kind of rules the plugin produces and mimic them.
The typical answer to anything switch_to_blog() is — no it shouldn’t, yes it is a mess. Simply put WP architecture doesn’t posses the capability of making such clean switch from one blog to another in the runtime. It’s a bit of wishful thinking — some things work, some very much break. In your specific case … Read more
For those who stumble upon this in the future, this was actually answered by the CMB2 author himself, Michael Beckwith: $sites = wp_get_sites(); $current_site = get_current_blog_id(); foreach ($sites as $site) { $details = get_blog_details($site[‘blog_id’]); $zSite = $details->blog_id; $mycolor=””; $mclass=””; if( $current_site == $zSite ) { $mclass=”active”; } switch_to_blog( $site[ ‘blog_id’ ] ); $mycolor = get_option( … Read more